Project

General

Profile

Tâche #21270

Scénario #21165: Traitement express MEN (37-39)

Scribe 2.5 suite migration Erreur logon

Added by Christelle Blasco over 5 years ago. Updated over 5 years ago.

Status:
Fermé
Priority:
Normal
Assigned To:
Start date:
09/08/2017
Due date:
% Done:

100%

Estimated time:
3.00 h
Spent time:
Remaining (hours):
0.0

Description

Nous avons avons des Scribes 2.5.2 qui suite à des migrations de fin d'année présentent le symptôme :
---------
Machine à l’ouverture de session tombe systématique dans le groupe esu :
grp_eole

Le Nom Machine n'est pas remontée dans le main.log

Le test_port test_port_user" self.logon : Passage 0 => timed out
-------
erreur dans /var/log/samba/log.smbd

Traceback (most recent call last):
File "/usr/share/eole/fichier/dyn-logon.py", line 70, in main
logon(user, ostype, machine, adresse_ip, pid)
File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 124, in logon
gen_ftpdir(uid, homedir, shares)
File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 217, in gen_ftpdir
create_ftpsymlink()
File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 211, in create_ftpsymlink
symlink(share['path'], join(ftpdir, share['name']))
OSError: [Errno 17] File exists
-----
fichier cores dans /var/log/samba/
Script utilisateur dans /home/netlogon @vide pour 2 scribes.

cliscribe.log View (86.5 KB) Christelle Blasco, 09/08/2017 11:07 AM

cliscribe_logon.log View (1.27 MB) Christelle Blasco, 09/08/2017 11:07 AM

main.log View (628 KB) Christelle Blasco, 09/08/2017 11:07 AM

Associated revisions

Revision db02a6ec (diff)
Added by Emmanuel GARETTE over 5 years ago

gérer les liens symboliques cassés dans le répertoire .ftp (ref #21270)

Revision 48a4e525 (diff)
Added by Emmanuel GARETTE over 5 years ago

ajout d'un test pour les liens cassés (ref #21270)

Revision 363c8e76 (diff)
Added by Emmanuel GARETTE over 5 years ago

gérer le cas ou le fichier .distribues est autre chose qu'un fichier (ref #21270)

Revision d167a910 (diff)
Added by Emmanuel GARETTE over 5 years ago

modification des tests pour refleter les nouveaux comportements (ref #21270)

Revision 28a57469 (diff)
Added by Emmanuel GARETTE over 5 years ago

Gestion des liens symboliques brisés dans les répertoires ".ftp" et ".distribues"

Ref: #21270 (cherry-pick from 2.5.2 commits)

Revision 74adf32b (diff)
Added by Emmanuel GARETTE over 5 years ago

Gestion des liens symboliques brisés dans les répertoires ".ftp" et ".distribues"

Ref: #21270 (cherry-picked from 2.5.2 commits)

History

#1 Updated by Emmanuel GARETTE over 5 years ago

  • Tracker changed from Demande to Tâche
  • Status changed from Nouveau to En cours
  • Assigned To set to Emmanuel GARETTE
  • Estimated time set to 3.00 h
  • Parent task set to #21165
  • Remaining (hours) set to 3.0

Pour reproduire :

root@scribe:~# rm /home/p/prenom.eleve112/.ftp/c31
rm : supprimer lien symbolique '/home/p/prenom.eleve112/.ftp/c31' ? y
root@scribe:~# ln -s /pouet /home/p/prenom.eleve112/.ftp/c31
root@scribe:~# /usr/share/eole/fichier/dyn-logon.py -u prenom.eleve112 -o vista -m pouet -i 1.1.1.1 -p 10
Traceback (most recent call last):
  File "/usr/share/eole/fichier/dyn-logon.py", line 70, in main
    logon(user, ostype, machine, adresse_ip, pid)
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 124, in logon
    gen_ftpdir(uid, homedir, shares)
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 217, in gen_ftpdir
    create_ftpsymlink()
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 211, in create_ftpsymlink
    symlink(share['path'], join(ftpdir, share['name']))
OSError: [Errno 17] File exists
None
[Errno 17] File exists
root@scribe:~# 

#2 Updated by Emmanuel GARETTE over 5 years ago

Pour aller plus loin, le lien ne devrait pas être créé si le répertoire de destination n'existe pas :

root@scribe:~# rm -rf /home/workgroups/c31
root@scribe:~# /usr/share/eole/fichier/dyn-logon.py -u prenom.eleve112 -o vista -m pouet -i 1.1.1.1 -p 10
root@scribe:~# ls -ald /home/p/prenom.eleve112/.ftp/c31
lrwxrwxrwx 1 root root 20 sept.  8 14:49 /home/p/prenom.eleve112/.ftp/c31 -> /home/workgroups/c31

#3 Updated by Emmanuel GARETTE over 5 years ago

  • % Done changed from 0 to 100
  • Remaining (hours) changed from 3.0 to 0.25

Les 2 cas sont traités.

#4 Updated by Emmanuel GARETTE over 5 years ago

  • % Done changed from 100 to 90
  • Remaining (hours) changed from 0.25 to 1.0

Commit fait dans un branche à partir de 2.5.2.

Voir sur quelle version on backport.

#5 Updated by Emmanuel GARETTE over 5 years ago

Backport fait en 2.5.2, a faire en 2.6.0 et 2.6.1.

#6 Updated by Emmanuel GARETTE over 5 years ago

Autre problème constaté :

  File "/usr/share/eole/fichier/dyn-logon.py", line 77, in main
    logon(user, ostype, machine, adresse_ip, pid)
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 128, in logon
    gen_devdir(user, uid, homedir, userclass)
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 191, in gen_devdir
    symlink(dev_dist_dir, link)
OSError: [Errno 17] File exists

#7 Updated by Emmanuel GARETTE over 5 years ago

J'ai eu du mal a reproduire ...

Il faut que .distribues soit un répertoire et non un fichier :

# rm -f /home/p/prof.6a/devoirs/.distribues
# mkdir /home/p/prof.6a/devoirs/.distribues
# /usr/share/eole/fichier/dyn-logon.py -u prof.6a -o vista -m pouet -i 1.1.1.1 -p 10
Traceback (most recent call last):
  File "/usr/share/eole/fichier/dyn-logon.py", line 70, in main
    logon(user, ostype, machine, adresse_ip, pid)
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 128, in logon
    gen_devdir(user, uid, homedir, userclass)
  File "/usr/lib/python2.7/dist-packages/scribe/login.py", line 194, in gen_devdir
    symlink(dev_dist_dir, link)
OSError: [Errno 17] File exists

#8 Updated by Emmanuel GARETTE over 5 years ago

Correction fait pour ce nouveau cas, reste à voir le backport

#10 Updated by Scrum Master over 5 years ago

  • Status changed from En cours to Résolu

#11 Updated by Joël Cuissinat over 5 years ago

  • Status changed from Résolu to Fermé
  • Remaining (hours) changed from 0.25 to 0.0

Also available in: Atom PDF