473,405 Members | 2,287 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

I have a database on a network drive that I use for archiving purposes, but when the server is rebooted the database becomes suspect.

I created the db with the attached script and I am able to access it
until I reboot the server. I've tried enabling flag 1807 via the SQL
server service and the startup parameters of the instance. In all
cases the database always come up suspect after a reboot. There was
one instance where I was able to recover, but I am not sure how that
happened.

Does anyone have an idea of how I can reboot the server without the
database becomming suspect?

USE MASTER
GO
DBCC TRACEON(1807)
GO
--DBCC TRACEOFF(1807)
--DBCC TRACESTATUS(1807)
GO
CREATE DATABASE ReadyNAS ON
( NAME = ReadyNAS_Data,
FILENAME = '\\NAS1\NASDisk\SQL Server\ReadyNAS\ReadyNAS_Data.mdf',
SIZE = 100MB,
MAXSIZE = 20GB,
FILEGROWTH = 20MB)
LOG ON ( NAME = ReadyNAS_Log,
FILENAME = '\\NAS1\NASDisk\SQL Server\ReadyNAS\ReadyNAS_Log.ldf',
SIZE = 20MB,
MAXSIZE = 100MB,
FILEGROWTH = 10MB)

Mar 30 '07 #1
5 2320
On Mar 30, 10:08 am, war_whee...@yahoo.com wrote:
I created the db with the attached script and I am able to access it
until I reboot the server. I've tried enabling flag 1807 via the SQL
server service and the startup parameters of the instance. In all
cases the database always come up suspect after a reboot. There was
one instance where I was able to recover, but I am not sure how that
happened.

Does anyone have an idea of how I can reboot the server without the
database becomming suspect?

USE MASTER
GO
DBCC TRACEON(1807)
GO
--DBCC TRACEOFF(1807)
--DBCC TRACESTATUS(1807)
GO
CREATE DATABASE ReadyNAS ON
( NAME = ReadyNAS_Data,
FILENAME = '\\NAS1\NASDisk\SQL Server\ReadyNAS\ReadyNAS_Data.mdf',
SIZE = 100MB,
MAXSIZE = 20GB,
FILEGROWTH = 20MB)
LOG ON ( NAME = ReadyNAS_Log,
FILENAME = '\\NAS1\NASDisk\SQL Server\ReadyNAS\ReadyNAS_Log.ldf',
SIZE = 20MB,
MAXSIZE = 100MB,
FILEGROWTH = 10MB)

I've figure out how to reboot the server and make the networked
database accessible again. After the reboot, I need to manually
restart the SQL Server service.

Does anyone have an idea why I need to restart the service when I is
configured to start automatically? Also is there a way to have this
happen automatically via a script of something?

Mar 31 '07 #2
(wa*********@yahoo.com) writes:
I've figure out how to reboot the server and make the networked
database accessible again. After the reboot, I need to manually
restart the SQL Server service.

Does anyone have an idea why I need to restart the service when I is
configured to start automatically? Also is there a way to have this
happen automatically via a script of something?
I would guess what happens is that the SQL Server service starts up
before the network connection has been established. Since the database
is not found at the point, it's marked suspect.

One thing you could try is to set the database to autoclose. I'm not sure
that it will actually work; maybe SQL Server still tries to access the
database on startup.

I don't know if it's possible to delay SQL Server starting up by making
it depending on the network service that makes network shares available.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pro...ads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinf...ons/books.mspx
Mar 31 '07 #3
<wa*********@yahoo.comwrote in message
news:11**********************@b75g2000hsg.googlegr oups.com...
I've figure out how to reboot the server and make the networked
database accessible again. After the reboot, I need to manually
restart the SQL Server service.

Does anyone have an idea why I need to restart the service when I is
configured to start automatically? Also is there a way to have this
happen automatically via a script of something?
Yes, my guess is that SQL Server is starting BEFORE the workstation service
(I believe that's the one required) so that UNC shares are not available
until AFTER SQL Server starts.

Restarting SQL Server works because the drives are available at that point.

You can go into the properties of the SQL Server service and play around
with dependencies and that should allow you to fix it.

--
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html
Apr 1 '07 #4
On Apr 1, 10:01 am, "Greg D. Moore \(Strider\)"
<mooregr_deletet...@greenms.comwrote:
<war_whee...@yahoo.comwrote in message

news:11**********************@b75g2000hsg.googlegr oups.com...
I've figure out how to reboot the server and make the networked
database accessible again. After the reboot, I need to manually
restart the SQL Server service.
Does anyone have an idea why I need to restart the service when I is
configured to start automatically? Also is there a way to have this
happen automatically via a script of something?

Yes, my guess is that SQL Server is starting BEFORE the workstation service
(I believe that's the one required) so that UNC shares are not available
until AFTER SQL Server starts.

Restarting SQL Server works because the drives are available at that point.

You can go into the properties of the SQL Server service and play around
with dependencies and that should allow you to fix it.

--
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html

I tried setting the database to auto_close and also tried read_only
which didn't correct the problem. What I mean is I still had to
restart the service when the database was set to read_only, but I was
able to access it. I also found that accessing the tables from the
read_only database was quicker. On the other hand, when I set the
database to auto_close I couldn't access it after a reboot even when
restarting the service. The only was that I was able to access the
database was to remove the auto_close options.

Apr 18 '07 #5


<wa*********@yahoo.comwrote in message
news:11**********************@y80g2000hsf.googlegr oups.com...
On Apr 1, 10:01 am, "Greg D. Moore \(Strider\)"
<mooregr_deletet...@greenms.comwrote:
><war_whee...@yahoo.comwrote in message

news:11**********************@b75g2000hsg.googleg roups.com...
I've figure out how to reboot the server and make the networked
database accessible again. After the reboot, I need to manually
restart the SQL Server service.
Does anyone have an idea why I need to restart the service when I is
configured to start automatically? Also is there a way to have this
happen automatically via a script of something?

Yes, my guess is that SQL Server is starting BEFORE the workstation
service
(I believe that's the one required) so that UNC shares are not available
until AFTER SQL Server starts.

Restarting SQL Server works because the drives are available at that
point.

You can go into the properties of the SQL Server service and play around
with dependencies and that should allow you to fix it.

--
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com
http://www.greenms.com/sqlserver.html


I tried setting the database to auto_close and also tried read_only
which didn't correct the problem.
Ok, not really sure why you took this approach. Did you try my advice?
What I mean is I still had to
restart the service when the database was set to read_only, but I was
able to access it. I also found that accessing the tables from the
read_only database was quicker. On the other hand, when I set the
database to auto_close I couldn't access it after a reboot even when
restarting the service. The only was that I was able to access the
database was to remove the auto_close options.
--
Greg Moore
SQL Server DBA Consulting Remote and Onsite available!
Email: sql (at) greenms.com http://www.greenms.com/sqlserver.html
Apr 18 '07 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: MHenry | last post by:
Hi, We were going merrily along for 6 years using this database to record all client checks that came into our office, including information about what the checks were for. Suddenly, network...
1
by: Tardus Merula | last post by:
We have just put a new samba server on the lab premises and upgradede all workstations to 100 MB/s, in order to avoid using 10-mile radio link, hoping that this would enable us to operae our...
5
by: premmehrotra | last post by:
I currently have a multi-user access database which is put on a shared drive L: on a Windows Servers. Entire database is one file premdb.mdb. Users access this database from their laptops....
2
by: Michal Valent | last post by:
Hello, if I try to read a file on the mapped network drive, this error apears: Logon failure: unknown user name or bad password. How to set up permissions for IUSR_MACHINENAME on the mapped...
4
by: Scott Nicholson | last post by:
I've got a site set up that uses a network share as it's home directory. Simple stuff is working fine. When I try to put a database in there, though, I run into problems. I'm using: dim...
3
by: blantz | last post by:
I am trying to connect to an Access database on a network drive and the web server is on the same network, i.e. G:\sample\test.mdb and everytime I try to connect to it I get an error saying......
2
by: Tom Wells | last post by:
I have a little file upload page that I have been able to use to successfully upload files to the C: drive of LocalHost (my machine). I need to be able to upload to a network drive from the intranet...
14
by: frostalicious | last post by:
Used VB.NET (on my client PC) to convert VB6 executable to .NET executable. Placed the .exe file on a network drive on my server. From client, ran .NET Wizards "Trust an Assembly" to make the...
2
by: jannordgreen | last post by:
I try to run http://localhost/scroller/scrollertest.asp in my IE 6 browser. The asp program tries to connect to a MS Access 97 database. The program works when the database is sitting on any...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.