Morning all.
Small reporting inconsistency in Reports > Directory Membership (FOG 1.6.0.158 stable, agent 0.1.28, AD join). Cosmetic, nothing breaks.
The “Join” column comes from hdJoinAt. In Directory_Membership::join() an empty hdJoinAt with no error is shown as empty, and the code comment says “Never attempted: the host is already joined, or it has never reported, or nothing has needed doing. Not a problem.”
But a host that was reimaged and joined through the rejoin protocol (the result carries an attempt_id, so DirectoryJoin::report() hands it to DirectoryRejoin::report()) never gets hdJoinAt written. On top of that, TaskQueue::checkout() calls DirectoryJoin::forgetAttempt() when a Deploy completes, which sets hdJoinAt back to NULL. So after every reinstall the host ends up like this:
hdJoined=1, hdDomain correct, Drift “ok”, hdRejoinState phase verified hdJoinAt NULL, hdJoinError empty, so “Join” is blankIn our case two test VMs that we reinstall many times show a blank “Join” even though they joined correctly and automatically, while hosts joined with the older path (or by hand before) show “ok”. Looking at the report you can’t tell the two cases apart, and a blank reads as “never joined”.
I checked the unpatched DirectoryRejoin.php (before our local #2122 patch) and it has no joinAt either, so it is not caused by that.
Thanks for the help.