Introducing the Microsoft SBS 2011 Essentials Answer File Tool!!

sbse-conI have never been able to understand coding. It has always been a bit of a mystery, or black art to me, left for the likes of Slytherin house to enter their Parseltounge into Visual Studio or your developer tool of choice.

I mean, it literally makes no sense at all does it. Read more of this post

Installing SBS Essentials using an Answer File

sbsessA question came up on the SBS Essentials forum about how to install SBS Essentials with a domain name that ended in a suffix other than .local

The answer to that question was yes you can, but you need to use an Answer File.

Another question popped up about the layout of your disks, and the way SBS Essentials works with disks during installation.

As you may know SBS Essentials has a minimum requirement of a single 160gb hard disk for installation. If your system does not meet this requirement the install will fail.

The default install process will create a 60gb partition for Windows, and use the rest of your drive for a D drive (data). I think 60gb is woefully small, and i think most IT Pro’s would agree, however you do not have to stick with this, you can make use of an entire disk for C:, by using an Answer file.

There is an online resource here that explains the different values you can use with your Answer File.

Firstly, to build your answer file, you need to open Notepad, and save a text file as ‘cfg.ini’ You may need to save it with the file name in quotes, and with ‘all files’ selected.

1

Once you have this we can start to populate the file. But let’s review some of the things we can set through the answer file.

[WinPE]
Drivers
InstallDisk
WindowsPartitionId
PID
ConfigDisk
WindowsPartitionSize

Drivers

Here we can set a path to a folder that contains the drivers for the server. This is an option setting and should be self explanatory, you can only use the setting once to point the install to a driver folder, you can either use a known path to a drive letter, or a wild card.

[WinPE]
Drivers=x:\serverdrivers

[WinPE]
Drivers=_:\serverdrivers   (_:\ denotes a wildcard)

InstallDisk

Another optional setting. This setting relates to the Physical Disk ID of the drive on which you wish to install Windows. It might prove difficult to actually identify the drive ID you want to use, especially with a RAID configuration, however it should follow some logic somewhere, so if you have multiple disks, it would be OK to assume that the disk on Channel 0 – will be found by the install as Disk0 etc. For Raid Arrays the same would apply, Array0 would become Disk0.

This is based on my assumptions – for example you may not have a disk connected to channel 0, in that event the disk on the lowest numbered channel would become disk 0.

Just remember that the installation of SBS Essentials will WIPE ALL disks, so please do test this before you begin, and don’t come crying to me if it wipes something important!

[WinPE]
Drivers=x:\serverdrivers
InstallDisk=0

WindowsPartitionId

Another option setting for disk management. This can be used in conjunction with the InstallDisk parameter and specifies which partition to install Windows to, on the disk specified. There are considerations to make here depending on whether you are using an MBR based system, or a UEFI based system. I think mainly this parameter is used when you have a preconfigured disk – i have not used this setting in my testing so i don’t have any experience with it. I cant really see a situation where i would use it myself as i imagine i would be formatting an entire disk in most cases. You can get more information from the Online Help (which is where i am getting my information) This setting is also related to the ConfigDisk parameter.

[WinPE]
Drivers=x:\serverdrivers
InstallDisk=0
WindowsPartitionId=2

PID

This parameter is where you would enter your servers License Key if you have one, and if you want to. I have personally stopped entering License keys during setup, i prefer to wait until my server is up and running and configured, then take a backup prior to Activation. With a ‘trial’ period available it seems to make sense to save your activation until you are happy that the server is going into production and will not be re-installed.

(Note this PID is invalid and your install will fail if you try to use it)

[WinPE]
Drivers=x:\serverdrivers
InstallDisk=0
WindowsPartitionId=2
PID=1234-5678-9101-1121-3141

ConfigDisk

Optional parameter. This can be either a 0 or a 1. The online help explains this quite clearly. If it is missing, then all disks and partitions are deleted, and new partitions are created.

If it is set to 1, then all disks and partitions are deleted, and new partitions are created.

If we set to 0, then nothing is done to the disks, and the WindowsPartitionId parameter is used to determine where Windows will be installed on the available disks.

If you set this to 0 and omit the WindowsPartitionId parameter, then setup will ignore your answer file.

[WinPE]
Drivers=x:\serverdrivers
InstallDisk=0
WindowsPartitionId=2
PID=1234-5678-9101-1121-3141
ConfigDisk=0

WindowsPartitionSize

The last parameter used in the WinPE section. As the name suggests, here we set the value for the size of the Windows Partition. The value here is in MB. NOT GB. The valid range here is 20480 – 102400. You can also specify a value of MAX which will format the entire disk as the Windows Partition. If you don’t specify this parameter, then the default value of 61440 is used.

So with the above configured, we would have SBS Essentials installed to disk 0, Partition 2. With a 100GB partition for Windows. The WindowsPartitionID parameter is ignored as the ConfigDisk parameter is set to 0 – there fore the disk would have to be preconfigured.

[WinPE]
Drivers=x:\serverdrivers
InstallDisk=0
WindowsPartitionId=2
PID=1234-5678-9101-1121-3141
ConfigDisk=0
WindowsPartitionSize=102400

In order to get the answer file to format a drive, and configure a partition size of our choosing we must change the parameters.

[WinPE]
Drivers=x:\serverdrivers
InstallDisk=0
WindowsPartitionId=2
PID=1234-5678-9101-1121-3141
ConfigDisk=1
WindowsPartitionSize=102400

With this configuration the Answer File will install SBS Essentials to disk 0, but it will ignore the WindowsPartitionId parameter. ConfigDisk has been set to a value of 1, meaning it will format Disk 0 and create a partition of 100gb.

Example of an SBS Essentials Answer File

The last parameter you may see, is Processed. This parameter is added to the answer file after the disk configuration has been completed. This stops the server being stuck in an endless install loop of formatting the disks, and i guess it also allows the Installer to skip ahead to the next part of setup.

The only value that the installer will enter is True. Any other value will most likely be ignored, and function as though it does not say True. Since that results in the same behaviour, i.e. False.

If a value of True is detected and you boot into Setup, then the Answer file is ignored and you are presented with the options you would get if you were not using an Answer File.

3

If you have anything wrong in your answer file you will receive an error, and a log is create that will show you what has gone wrong.

4

You can click on the hyperlink ‘Installation Error Logs’ to view the setup log file and try to identify what is wrong with your answer file.

5

As you can see from the above, it has detected an invalid PID and the installation has failed.

In the second part of the answer file, we look at the Initial Configuration of the server. This includes the Locale to install to and the regional settings, the name of the company, server, and the domain name you want to use, and you also set the name of an administrator account, the password and that of a standard user account.

Again the information is available at the online help page.

[InitialConfiguration]
AcceptEula
AcceptOEMEula
CompanyName
Country
ServerName
DNSName
NetbiosName
Language
Locale
Keyboard
Settings
UserName
PlanTextPassword
StdUserName
StdUserPlainTextPassword

AcceptEula

Easy – do you, or do you not accept the end user license agreement. Let’s see how far you get if you set this to false!

Valid settings here are true or false.

[InitialConfiguration]
AcceptEula=True

AcceptOEMEula

This is another optional parameter, and one only used by OEM’s, same deal as above, True or False, with True being the only setting that will allow the install to continue. This is a separate License Agreement specific to your OEM hardware provider.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True

CompanyName

An easy one this – What is your company name? Up to 254 Characters.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True

CompanyName=CompuGlobalHyperMegaNet

Country

Your country abbreviated into a string. The only example given is for the USA, which surprisingly enough is US.

There doesn’t appear to be any additional help available for Country Codes.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB

ServerName

What do you want your server name to be? From the Online Help

The server name uniquely identifies the server on the network. Your server name must meet the following criteria:

  • Can be up to 15 characters long
  • Can contain letters, numbers and hyphens (-)
  • Must not start with a hyphen
  • Must not contain any spaces
  • Must not contain only numbers Example: ContosoServer

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer

DNSName

Your internal DNS domain name. When installing using the GUI, SBS Essentials will use a .local extension. The gui will base the prefix on your company name to start with, so if your company is SBS, then your domain name, prefix, would be SBS. This prefix can be changed in the GUI, however you cannot change the suffix (.local) If you want to install using a domain name other then you need to use the answer file, and this is the parameter to change. The same limitations are placed on domain names as in a standard Active Directory domain (AD) (More Here) and you should also consider the NetBIOS name limits as well (More Here). Another consideration is, how often will i have to type this? So keep it short if you can. I usually recommend using SBS, but in my example below i am using a different company name for a change.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com

NetbiosName

We are still using NetBIOS names, despite it’s demise being heralded at each new dawn… ok that’s a little dramatic and it, seemingly, does still have a place in modern networks. Keep this under 15 characters are your good.

Match it with your domain prefix to keep things simple.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com
NetbiosName=COMPUGL

Language

A straight forward setting, you would think. What language do you want to install in? Well, let me tell you, unless you set this to EN-US you wont get very far. I am in the process of investigating this with Microsoft, but don’t worry, it does seem to ignore this setting in favour of one of the other Regional settings. But i don’t know which one. I tried setting this to match many different language codes, found here, but each time i hit this error:

IMG_0956

If setup detects any errors in the [InitialConfiguration] part of your Answer File you will see the above. It is actually really useful, it doesn’t just error out, it actually gives you the chance to fix your Answer File and then retry. You can see above, one of my many attempts to get it to recognise the UK variant of English, that being, English.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com
NetbiosName=COMPUGL
Language=en-US

Locale

Again, another regional setting. Default, and only published option is en-US, However i set mine to en-GB and it passed.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com
NetbiosName=COMPUGL
Language=en-US
Locale=en-GB

If you do decide to use an Answer File to install, please check your time zone is correct when installation is complete.

Keyboard

Self explanatory, keyboard layout. We do have some published parameters here, and setting mine to English_United_Kingdom which is, 00000809 works.

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com
NetbiosName=COMPUGL
Language=en-US
Locale=en-GB
Keyboard=00000809

As i have explained i did have some issues with the Regional Settings of the Answer File, however i found that once i had installed with the above Regional Settings i got the result i wanted. I would assume then, that one of these settings takes precedence, over the Language setting.

CaptureCapture2

Settings

From the Online Help.. This parameter relates to your Automatic Updates setting.

  • All equals “Use recommended settings”
  • Updates equals “Install important updates only”
  • None equals “Do not check for updates”

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com
NetbiosName=COMPUGL
Language=en-US
Locale=en-GB
Keyboard=00000809
Settings=ALL

The last 4 parameters are straight forward. With the GUI Installation of SBS Essentials, you are prompted to create both an Administrator account, and also a Standard user account. The Password you enter here, is, clearly, in plain text. So please do make sure your answer file is kept secure, or that you use a default password for installation, and then change it when the installation is completed.

UserName

PlanTextPassword

StdUserName

StdUserPlainTextPassword

[InitialConfiguration]
AcceptEula=True
AcceptOEMEula=True
CompanyName=CompuGlobalHyperMegaNet
Country=GB
ServerName=CompuServer
DNSName=COMPUGL.com
NetbiosName=COMPUGL
Language=en-US
Locale=en-GB
Keyboard=00000809
Settings=ALL
UserName=HSimpson
PlainTextPassword=P@55word
StdUserName=SHomer
StdUserPlainTextPassword=MyP@ssw0rd

26

Information on using an Answer File was published to this page http://onlinehelp.microsoft.com/en-us/sbs2011essentials/answer-file-install-1.aspx and that has been the basis of where i got the information for this post. I found that the documentation did leave me with some questions which is why i wrote this post. Hopefully used in conjunction they will serve as a good reference for anyone wanting to use an Answer File to install SBS 2011 Essentials.

EDIT : 20/09/2011 Those clever chaps over at UsingWindowsHomeServer.com Managed to find a workaround to the issue of using an install disk smaller than 160gb, Despite my being told it was not possible in the RTM Build of SBS Essentials by Microsoft.. (I am not bitter or anything)  If you are in need of using a smaller install disk check out this link.