Posted on 08-08-2011 02:36 PM
Hey folks,
Trying to see if there is a way to determine a Mac's directory bindings remotely? I can touch each Mac remotely or physically visit each Mac, but there should be a good way of determining if a Mac's bindings are working correctly.
Any thoughts on this?
Mick
Posted on 08-08-2011 02:42 PM
There is an active directory status field in the operating system section of the inventory record of a Mac which tells you if it's bound and to what domain. However, if you're trying to figure out if that binding is red ball or green ball currently, that I'm not too certain about.
Craig E
Posted on 08-08-2011 02:48 PM
if they're working or if they're present?
and are you looking for AD, OD, other, or all?
this will show you any OD bindings: dscl localhost -list /LDAPv3
to test, add a user or some other object in the directory and perform a lookup. if the machine is properly bound, the lookup will succeed. if not, it may need to be reconfigured.
likewise, dsconfigad -show will show you AD bind details.
Posted on 08-08-2011 02:51 PM
Edit the below to do an AD lookup:
set ADGroups to do shell script "dscl /Active Directory/All Domains -read /Users/" & loggedInUser & " | awk '/^dsAttrTypeNative:memberOf:/,/^dsAttrTypeNative:msExchHomeServerName:/'"
Regards,
Ben.
Posted on 08-08-2011 07:41 PM
You may want to try dsstatus, which is a command line version of the "Network Accounts Available" indicator.
On Aug 8, 2011, at 5:36 PM, Michael D Conners wrote:
https://github.com/jatoben/dsstatus
-- Ben