0
votes

What are the actual OSes that are considered a "Windows Server" by IsServer of NSIS LogicLib WinVer?

Wikipedia lists the following as belonging to the Microsoft Server family:

  • Windows Server 2003
  • Windows Server 2008
  • Windows Server 2012
  • Windows Server Essentials

But not:

  • Windows Home Server
  • Windows MultiPoint Server

Does IsServer share the same opinion?

The IsServer documentation also includes NT as a "server", contrary to the Wikipedia article.

1
Why do you care? Are you going to do something Active Directory related or some other operation that only works on a server? - Anders
@Anders Yes the software should only install on servers, 2003 and up. - Obay

1 Answers

0
votes

IsServer is true if OSVERSIONINFOEX.wProductType from GetVersionEx is not VER_NT_WORKSTATION.

NT4 and 2000 had both client and server versions of the OS.

This page claims you can detect home server by checking for the VER_SUITE_WH_SERVER bit but since the test for 2003 (GetSystemMetrics(SM_SERVERR2) == 0) is clearly wrong I don't know how much you could trust this information. (Checking for 2003 correctly means checking that the version is 5.2, not VER_NT_WORKSTATION (XP64) and only if you need to tell 2003R2 apart from 2003 would SM_SERVERR2 come into the picture)