Microsoft KB Archive/160476

= %OS and %OS_VERSION Reported Incorrectly =

Article ID: 160476

Article Last Modified on 2/27/2007

-

APPLIES TO


 * Microsoft Windows 2000 Server
 * Microsoft Windows 2000 Advanced Server
 * Microsoft Windows 2000 Professional Edition
 * Microsoft Windows NT Workstation 4.0 Developer Edition
 * Microsoft Windows NT Server 4.0 Standard Edition

-



This article was previously published under Q160476





SYMPTOMS
When you run your Novell NetWare login script from Client Services for NetWare (CSNW) or Gateway Services for NetWare (GSNW), the %OS_VERSION variable is set to MS-DOS V5.00.



CAUSE
The use of environment variables in NetWare login scripts (like Windows NT Login Scripts) permits the substitution for fixed values such as Username, MS-DOS version, or Date and Time.

One of these identifier variables is %OS_VERSION. Under MS-DOS, this variable translates to the version of MS-DOS being used on the computer that is logging on to the NetWare server.

For example, the line in the login script

  MAP S2:=SYS:PUBLIC\%OS_VERSION

is converted to a drive mapping of

  S2:=Y:\ [SYS:PUBLIC\V6.22]

on a computer running MS-DOS 6.22.

When Windows NT Workstation or Server runs the NetWare login script, MS-DOS version 5.00 (V5.00) is substituted for Windows NT version 4.0 (the command line environment in Windows NT is based on MS-DOS v. 5.0).

Therefore, in Windows NT, the previous example would translate from

  MAP S2:=SYS:PUBLIC\%OS_VERSION

and is converted to a drive mapping of

  S2:=Y:\ [SYS:PUBLIC\V5.00]



STATUS
Microsoft has confirmed this to be a problem in Windows NT version 4.0. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

Additional query words: 5.0 logon script

Keywords: kbbug kbnetwork KB160476

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.