Tuesday, March 27, 2012

Error installing SQL Server 2005 Express with command prompt

I just started using SQL 2005 and having a bit of struggle.

I'm having difficulty trying to use the .ini file to install sql express. This is the command I use in Command Prompt:

start /wait express\setup.exe /settings setup.ini /qn
echo %errorlevel%

Then I get an error level of ‘-204’, which I couldn’t find the meaning on the internet or anywhere else.

But when I move the parameters from the .ini file to the batch file and the process worked. SQL started installing, until it comes to the SQL Server Database Services component. Then I get the following error message:

SQL Server Setup could not validate the service accounts. Either the service accounts have not been provided for all of the services being installed, or the specified username or password is incorrect. For each service, specify a valid username, password, and domain, or specify a built-in system account.

Here is how my batch file looks with parameters:

start /wait express\setup.exe /qb

INSTANCENAME=”EXAMPLE”

ADDLOCAL=All SAPWD="difficult"

INSTALLSQLDIR="C:\Program Files\MS\"

INSTALLSQLDATADIR="C:\Program Files\MS\Data"

SECURITYMODE="SQL" SQLACCOUNT="user"

SQLPASSWORD="password"

AGTACCOUNT="user"

AGTPASSWORD="password"

SQLBROWSERACCOUNT="user"

SQLBROWSERPASSWORD="password"

Please, can anyone help? I don't know what to do anymore.

Thanks.

Regards,

Akwest

Take a look at the template.ini file that is included with the setup media. For these *ACCOUNT parameters, you need to supply a domain/system account. Here is the info:

;--
; The services for SQL Server and Analysis Server are set auto start. To use the *ACCOUNT settings
; make sure to specify the DOMAIN, e.g. SQLACCOUNT=DOMAINNAME\ACCOUNT
; NOTE: When installing SQL_Engine 3 accounts are REQUIRED: SQLACCOUNT, AGTACCOUNT and SQLBROWSERACCOUNT.

; SQLACCOUNT Examples:
; SQLACCOUNT=<domain\user>
; SQLACCOUNT="NT AUTHORITY\SYSTEM"
; SQLACCOUNT="NT AUTHORITY\NETWORK SERVICE"
; SQLACCOUNT="NT AUTHORITY\LOCAL SERVICE"


; Note: To install localized versions of SQL Server, refer to the Localized Service Names table in the SQL Server Books Online topic "Setting Up Windows Service Accounts"


; Note that if SQLBrowser is already installed, SQLBROWSERACCOUNT and SQLBROWSERPASSWORD are ignored.

SQLBROWSERACCOUNT=
SQLBROWSERPASSWORD=

SQLACCOUNT=
SQLPASSWORD=

AGTACCOUNT=
AGTPASSWORD=

ASACCOUNT=
ASPASSWORD=

RSACCOUNT=
RSPASSWORD=

|||Thanks.

that did it...

No comments:

Post a Comment