Skip navigation

JSI Tip 0677 - How can I build a file of member computer names in my domain?

The NETDOM utility from Supplement Two of the Resource kit can list members with the NETDOM member command. You can use this feature with the following member.bat file placed in your path:

@echo off
if "%1"

"" goto badp
If exist %1 del /f /q %1
for /f "Skip=5 Tokens=1* Delims=\" %%i in ('netdom member') do if not .%%j.

.. echo %%j >>%1
exit
:badp
@echo Syntax: member "<Drive:>\<Path>\Filename.ext"

To generate a file of member computer names, type:

member "<Drive:>\<Path>\Filename.ext"

Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish