Solved

How to detect the Workstation domain remotely

Posted on 2004-08-19
4
331 Views
Last Modified: 2010-04-14
We are in the process of migrating all of our users and computers from the old NT4 domain structures. I am in the process of writing a program to check for fallout. My program accepts a list of computer names as input, then remotely connects to each computer usisg RegConnectRegistry, and then I query different values to determine the success/failure of the migration of that particular machine, writing the results out to a log file.

I am having a tough time figuring out how to determine the Workstation domain (not the logon domain) remotely. Is there any identifier in the registry that I may have missed, or perhaps a command line utility? I have found that if I  run 'net.exe' with 'config workstation' I receive the info I need, but cannot run it against remote computers.

If anyone has any ideas I would greatly appreciate them. And, fwiw, we have a mix of Windows OS's, but I am primarily concerned with NT4, 2K, and XP.

Thanks,
Jeff
0
Comment
Question by:jpetter
  • 2
  • 2
4 Comments
 
LVL 15

Accepted Solution

by:
scampgb earned 500 total points
ID: 11840709
Hi jpetter,

I think that the registry key you're looking for is MachineDomain in HKLM\SOFTWARE\Microsoft\MSMQ\Parameters\Setup

You can find out more at http://www.microsoft.com/windows2000/techinfo/reskit/en-us/default.asp?url=/windows2000/techinfo/reskit/en-us/regentry/91598.asp - but is sounds exactly like what you're looking for.

I hope that this helps.
0
 

Author Comment

by:jpetter
ID: 11841572
scampgb,

That's the key I had been checking, but I thought I read an article stating it wasn't present on all builds. I've dug through my history files and naturally I cannot find it. Also, that key isn't present on NT4 systems, but I think I can use HKLM\System|CurrentControlSet\Services\Private\NetLogon and read the 'NetbiosDomainName' value name.

Thanks,
Jeff
0
 
LVL 15

Expert Comment

by:scampgb
ID: 11842437
Hi.  Thanks for the "A".  Glad I could help.
I looked at it on a WinXP box, but I don't have an NT one to play with at present!
0
 

Author Comment

by:jpetter
ID: 11843160
No problem. Interestingly enough, or should I say frustratingly enough, I have found Win2K machines that do not have that key. It looks like I may have two choices.
1. HKLM\Software\Microsoft\Windows NT\CurrentVersion and grab the CachePrimaryDomain value, though I don't know how reliable that is.
2. Resort to WMI...which I don't really want to do.

Jeff
0

Featured Post

[Webinar] Disaster Recovery and Cloud Management

Learn from Unigma and CloudBerry industry veterans which providers are best for certain use cases and how to lower cloud costs, how to grow your Managed Services practice in IaaS clouds, and how to utilize public cloud for Disaster Recovery

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

NTFS file system has been developed by Microsoft that is widely used by Windows NT operating system and its advanced versions. It is the mostly used over FAT file system as it provides superior features like reliability, security, storage, efficienc…
Knowledge base software has turned out to be a quite reliable method for storing information, promoting collaborative work and for sharing valuable input and solutions.However, some organizations are trying to develop a knowledge base that works wit…
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now