SQL Server MVP
Quote:> I'm trying to restore the master db, but I'm getting a
> promt to use "single user mode". Does any one know how I
> can open SQL 7.0 under single user mode?
starting the server,Quote:>-----Original Message-----
>You have to actually start the sqlserver executable with
a special flag,
>from the comand prompt.
>In the Books Online, look for "command prompt utilities",
and under that,
>There are actually lots of flags you can pass when
>SQL Server MVP
>> I'm trying to restore the master db, but I'm getting a
>> promt to use "single user mode". Does any one know how
>> can open SQL 7.0 under single user mode?
Have a process that restores the transaction logs from one SQL Server onto
another every half hour. It first attempts to set the target database into
single user mode and continues with this until successful. Once in single
user mode, it commences the backup using the Restore command.
Sometimes this Restore command fails with the error message "Database in
use. The system administrator must have exclusive use of the database to run
the restore operation".
After some investigation have observed that when a database is in Single
user mode with a connection already present, the 2nd attempt to connect to
it (2nd connection) will timeout after the specified timeout interval. If
additional connections are attempted simulteneousely (any more than 2) these
fail immediately. Whilst the 2nd connection is waiting to timeout, there are
actually 2 connections to the database in single user mode, which causes the
Restore to fail.
Any ideas about why this happens and how it can be avoided/fixed. This is on
SQL Server 7 SP4.
13. Single User Mode