Script to make automated documentation of Windows servers

oddmundk

Distinguished
Feb 7, 2008
2
0
18,510
Hi,

I've been playing with this script to automate the most of my documentation process when installing windows servers.

Please check it out and come with feedback!


cd\
echo off
echo http://www.techotopia.com/index.php/Window...mand-line_Tools
echo ########################################
echo -

echo Hostname
echo Display the computer name.
hostname
echo ########################################
echo -

echo Date
date /t
echo ########################################
echo -

echo Ver
echo "displays Windows version"
ver
echo ########################################
echo -

echo Nbtstat
echo Display status of NetBIOS.
Nbtstat -n
echo ########################################
echo -

echo ipconfig /all
echo print outs the tcp/ip settings
ipconfig /all
echo ########################################
echo -

echo getmac
echo prints mac adress
getmac
echo ########################################
echo -

echo Systeminfo
echo Display machine properties and configuration.
Systeminfo
echo ########################################
echo -

echo Tasklist
echo Display currently running tasks and services.
Tasklist
echo ########################################
echo -

echo WMI
echo Display WMI information.
echo must have wmi command installed (maybe resource disk?)
echo ########################################
echo -

echo Set
echo Display or modify Windows environment variables. Also used to evaluate numeric expressions at the command line
Set
echo ########################################
echo -

echo Route print
echo Manage network routing tables.
route print
echo ########################################
echo -

echo net view
echo shares on this computer
net view
echo ########################################
echo -


echo Net Localgroup
echo Display or manage local group accounts.
net localgroup
echo ########################################
echo -



echo Net Accounts
echo Manage user account and password policies.
Net Accounts
echo ########################################
echo

echo Net user
echo Local user(s)
Net user
echo ########################################
echo -


echo Net Config Server
echo Display or modify configuration of Server service.
Net Config Server
echo ########################################
echo -

echo Net Config Workstation
echo Display or modify configuration of Workstation service.
Net Config Workstation
echo ########################################
echo -


echo Gpresult /R
echo Displays RSoP summary data.
Gpresult /R
echo ########################################
echo -

echo Driverquery
echo Display the current device driver properties and status.
Driverquery
echo ########################################
echo -

echo Chkntfs
echo Display the status of volumes. Set or exclude volumes from automatic system checking during system boot.
Chkntfs C:
echo ########################################
echo -

echo Chcp
echo Display or set the active code page number.
Chcp
echo ########################################
echo -

echo serverManagerCmd.exe -query
echo list all server roles (only on Windows 2008 SERVER)
echo the version of serverManagerCmd.exe
serverManagerCmd.exe -v
serverManagerCmd.exe -query
echo ########################################
echo -


echo sc query type= service state= all
echo lister alle tjenster som er installert, både aktive og passive.
sc query type= service state= all
echo ########################################
echo -

echo bootcfg /query
echo queries computers Boot.ini file settings.
bootcfg /query
echo ########################################
echo -

echo Vol
echo displays label and serial no. of c: drive
vol
echo ########################################
echo -

echo tree c:\ /f
echo "lists the three-structure of the c: drive"
tree c:\ /f

echo ###########EOF - END OF FILE###################
 

hgsimp

Commendable
Feb 12, 2016
1
0
1,510
This is a bit of an old post but, just in case anyone else finds it on Google (as I did), I thought I'd point out that our company has created a tool which automatically documents Windows servers and workstations. It includes most of the information in the script above and more.

I hope it's ok to share a link to it here: Server Inventory Tool