What is the one and most accurate why to determine the Operating System of a remote M$Windows based server. The reason is; I will be removing or adding Permissions to shared drives resident on remote servers. Depending on the type of OS will determine whether or not to invoke a folder/sub folder recursion routine. Therefore I need to absolutely make sure the type of the OS.
Commands that approximate the OS will not help me -like referring to all Windows flavours as mswin32 – I need to know explicitly and exactly if its Windows NT 4, where Win32::Perms->Recurs(1) will not work then folder/sub folder recursion is required, or if its a Windows2000 based then Win32::Perms will do the recursion for me. I have tried printing $^O and %ENV on my local Windows XP machine, the values MSWin32 and Windows_NT inaccurately were returned respectively