The deployment and configuration of software can be a real nightmare to standardize; each administrator has his or her own ideas of best practice, even with checklists (or cheat sheets). In this series of articles, Rob Hawthorne will discuss the unattended installation of SQL Server and then drill down to writing your own scripts to install SQL Server, which ensures a standard and consistent deployment every time!
Hands-Off Deployment of SQL Server
This article is really the cornerstone of this series of articles. The script we develop here will be used again and again, with some slight modifications, to manage the execution process of any other scripts within our scripted installation and configuration process for SQL Server.
Now that we have completed our first script that installs SQL Server (in the second article of this series), we need to write our outer (or container) script that wraps up our subscripts and initializes the variables required for those subscripts. This outer (or main) script will systematically call any lower-level scripts (one after another), meaning that a script that has been called is allowed to completely finish before moving on, and notify the user of any possible return values that might not be error-free (that is, not equal to 0).
In this article, we will only call our first script "InstallSQLServer.bat" because this is the only script we have so far! Later on, we will revisit our main script and modify it to call and manage errors from other scripts.