Tâche #28939
Scénario #28762: Générer une nouvelle image 2.7.1 incluant le support du raid logiciel
La formula SaltStack a toujours des erreurs sur les machines déjà intégrées au domaine avant l’installation du minion
Description
Lors d’une mise à niveau d’un Scribe AD 2.6.2 vers 2.7.1, les machines déjà intégrées génères des erreurs sur certains états de la formula :
PC-272684.dompedago.etb1.lan:
file_|-Set a lock when computer is joined_|-C:\salt\var\ad-domain-joined.sem_|-managed:
__run_num__: 3
__sls__: eole-workstation.ad.join
changes: {}
comment: 'One or more requisite failed: eole-workstation.ad.join.Has JoinDomain
registry, eole-workstation.ad.join.Has AvoidSpnSet registry'
duration: 0.0
result: false
start_time: '14:38:29.878670'
module_|-Has AvoidSpnSet registry_|-reg.key_exists_|-run:
__id__: Has AvoidSpnSet registry
__run_num__: 2
__sls__: eole-workstation.ad.join
changes:
ret: false
comment: Module function reg.key_exists executed
duration: 156.078
name: reg.key_exists
result: false
start_time: '14:38:29.722592'
module_|-Has JoinDomain registry_|-reg.key_exists_|-run:
__id__: Has JoinDomain registry
__run_num__: 1
__sls__: eole-workstation.ad.join
changes:
ret: false
comment: Module function reg.key_exists executed
duration: 15656.456
name: reg.key_exists
result: false
start_time: '14:38:14.066136'
system_|-Reboot after joining the domain_|-Reboot after joining the domain_|-reboot:
__run_num__: 4
__sls__: eole-workstation.ad.join
changes: {}
comment: 'One or more requisite failed: eole-workstation.ad.join.Has JoinDomain
registry, eole-workstation.ad.join.Has AvoidSpnSet registry'
duration: 0.0
result: false
start_time: '14:38:29.878670'
La création du verrou ne doit pas dépendre de la détection de jonction au domaine AD par la formula mais par un état distinct de suis-je joint à un domaine ?
Pour valider¶
- Déployer un
etb1.amon 2.7.1
- Dépolyer un
etb1.scribe 2.7.1
- Dépolyer un
etb1.pcprofs-10
- Intégrer manuellement le poste prof au domaine Active Directory
Après le redémarrage :
- le minion SaltStack doit être installé automatiquement par la GPO (inchangé par rapport à avant)
- une fois la clef publique du minion acceptée sur le scribe, le poste client ne doit pas redémarrer (inchangé par rapport à avant)
- vérifiez l’application de la formula de jonction au domaine avec la commande suivante a exécuter depuis le Scribe :
salt '*' state.apply eole-workstation.ad.join
Vous devez obtenir le résultat Succeeded: 7 (changed=1)
Révisions associées
AD join: Avoid failing states when the computer is already joined
When a computer is joined to the domain before the SaltStack minion is
installed, then the “Has JoinDomain registry” and “Has AvoidSpnSet
registry” are failing because the joined lock file is not created and
will never be created.
The solution proposed by this commit will create the lock on first run
and then everything will be OK.
- eole-workstation/ad/join.sls: make the difference between “the system
is joined by the formula” and “the system is already joined”.
The lock depends on “Is system joined to domain” to catch the
“already joined” case.
Historique
#1 Mis à jour par Daniel Dehennin il y a plus de 4 ans
- Statut changé de Nouveau à En cours
- Assigné à mis à Daniel Dehennin
#2 Mis à jour par Daniel Dehennin il y a plus de 4 ans
- Description mis à jour (diff)
#3 Mis à jour par Daniel Dehennin il y a plus de 4 ans
- Statut changé de En cours à Résolu
- % réalisé changé de 0 à 100
- Restant à faire (heures) changé de 2.0 à 0.5
#4 Mis à jour par Fabrice Barconnière il y a plus de 4 ans
- Description mis à jour (diff)
- Restant à faire (heures) changé de 0.5 à 0.0
#5 Mis à jour par Fabrice Barconnière il y a plus de 4 ans
- Statut changé de Résolu à En cours
- % réalisé changé de 100 à 90
root@scribe:~# salt-key --list-all Accepted Keys: pc10-1.dompedago.etb1.lan Denied Keys: Unaccepted Keys: Rejected Keys:
root@scribe:~# salt '*' state.apply eole-workstation.ad.join pc10-1.dompedago.etb1.lan: Data failed to compile: ---------- The function "state.highstate" is running as PID 2808 and was started at with jid req ERROR: Minions returned with non-zero exit code
#6 Mis à jour par Fabrice Barconnière il y a plus de 4 ans
- Statut changé de En cours à Résolu
- % réalisé changé de 90 à 100
Il suffit d'être patient :
Summary for pc10-1.dompedago.etb1.lan
------------
Succeeded: 7 (changed=1)
Failed: 0
------------
Total states run: 7
Total run time: 16.110 s
#7 Mis à jour par Fabrice Barconnière il y a plus de 4 ans
- Statut changé de Résolu à Fermé