By default Lync installs SQL Express and the local databases onto the system drive during a Lync install. This is typically ok if only one drive exists on the server however, what if you have another drive which is dedicated to applications, a non-system drive. Lync will automatically move the Lync local databases to a non-system drive but SQL Express itself stays on the system drive. If there are three or more drives installed there is a way to control even further where the Lync local databases are stored.
Jens has a nice write up on installing the local databases to a separate drive that you can read here.
This still doesn’t solve the problem of installing SQL Express to a non-system drive. If you try to install SQL Express manually there is no guarantee that the install willpass the pre-requisite checks. After much trial and error along with a gentle parsing of the log files I was able to extrapolate the following command to install SQL Express to a non-system drive. Modify the following parameters to fit your build.
- /INSTANCENAME=<RTCLOCAL, LYNCLOCAL or RTC>
- /INSTALLSHAREDDIR=”C:\Program Files\Microsoft SQL Server”
- /INSTALLSHAREDWOWDIR=”C:\Program Files (x86)\Microsoft SQL Server”
- /QUIET (Delete if you want to click through the installation wizard)
SQLEXPR_x64.exe /QUIET /IACCEPTSQLSERVERLICENSETERMS /HIDECONSOLE /ACTION=Install /FEATURES=SQLEngine,Tools /INSTANCENAME=RTCLOCAL /TCPENABLED=1 /SQLSVCACCOUNT="NT AUTHORITY\NetworkService" /SQLSYSADMINACCOUNTS="Builtin\Administrators" /BROWSERSVCSTARTUPTYPE="Automatic" /AGTSVCACCOUNT="NT AUTHORITY\NetworkService" /SQLSVCSTARTUPTYPE=Automatic /INSTANCEDIR="C:\CSDATA" /INSTALLSHAREDDIR="C:\Program Files\Microsoft SQL Server" /INSTALLSHAREDWOWDIR="C:\Program Files (x86)\Microsoft SQL Server"
Reference: Installing SQL Express from the command line725 views