The %logonserver% variable isn’t available after I log on. What should I do?
John Savill
May 27, 2000
1 Min Read
A. When you log on, the logon process creates several volatile environment variables. These variables remove after the logon process completes, as the user’s environment unloads.
One of these variables is %logonserver%, which shows the domain controller (DC) that validated the user logon. This variable is useful in logon scripts and for other tasks after logon. In Windows NT 4.0, the %logonserver% variable removes after logon. To view this variable, use the following command.
echo %logonserver%
\TITANIC
If you want to use the %logonserver% variable after logon, you can use the Microsoft Windows NT Resource Kit’s Setx utility to manually set the variable into another environment variable. Enter the following command.
setx MyLogonServer %logonserver%
About the Author
Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.
You May Also Like