473,386 Members | 1,706 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,386 software developers and data experts.

problem with timeouts

I've had my SQL server database running for two years now without a
problem.

However, just today one of the main tables started returning an error.

The table is contained within a database called engineering. I back
it up once a week and the file size is up to about 40 MB.

The error returned when trying to return data from one table
(DbLucent) is:
"[Microsoft][ODBC SQL Server Driver]Timeout expired"

I can open/query any of the other tables in the database. I can open
design table for this table. But it won't return any query.

I'm debating whether to restore the database from the last backup.

Any suggestions would be appreciated. Being located reomotely, I
rather not fly back to the city where the server is and work on it
there either.

-David
Jul 20 '05 #1
6 3035
Hi

If you have checked that it is not being locked then it sounds like you may
need some form of maintainance plan for defragging the indexes?
John

"wireless" <wi*********@yahoo.com> wrote in message
news:90**************************@posting.google.c om...
I've had my SQL server database running for two years now without a
problem.

However, just today one of the main tables started returning an error.

The table is contained within a database called engineering. I back
it up once a week and the file size is up to about 40 MB.

The error returned when trying to return data from one table
(DbLucent) is:
"[Microsoft][ODBC SQL Server Driver]Timeout expired"

I can open/query any of the other tables in the database. I can open
design table for this table. But it won't return any query.

I'm debating whether to restore the database from the last backup.

Any suggestions would be appreciated. Being located reomotely, I
rather not fly back to the city where the server is and work on it
there either.

-David

Jul 20 '05 #2
wireless (wi*********@yahoo.com) writes:
I've had my SQL server database running for two years now without a
problem.

However, just today one of the main tables started returning an error.

The table is contained within a database called engineering. I back
it up once a week and the file size is up to about 40 MB.

The error returned when trying to return data from one table
(DbLucent) is:
"[Microsoft][ODBC SQL Server Driver]Timeout expired"

I can open/query any of the other tables in the database. I can open
design table for this table. But it won't return any query.

I'm debating whether to restore the database from the last backup.

Any suggestions would be appreciated. Being located reomotely, I
rather not fly back to the city where the server is and work on it
there either.


The table is not returning any timeout. The client is. And the timeout
is settable for most clients. From your talking of opening the table,
I assume that you are using Enterprise Manager to look at the table. EM
does not seem to always care about the timeout you can set.

In any case, you can try a SELECT * from the table in Query Analyzer. Since
QA by default does not have a timeout, you will not get an error. Then
again, if John's suspicion is right that there is blocking, then you can
wait forever. Nevertheless, do run that query, and pay attention to the
spid which you find in the status bar of QA, in parentheses after the
server name. Then open a second query window, and run sp_who. Find your
spid, and check the Blk column. If that column has a non-zero value,
the value in spid is the blocking process. Use KILL to terminate that
process, and you will get data back in the first query window.

If there is no blocking, I would suspect that the query is in fact a
view, and complex enough to not be computed within the 30 seconds that
is the default timeout. But for small 40 MB database it has to be
quite a wild view to get there.

--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #3
"John Bell" <jb************@hotmail.com> wrote in message news:<41***********************@news.easynet.co.uk >...
If you have checked that it is not being locked then it sounds like you may
need some form of maintainance plan for defragging the indexes?

Okay I figured out what it was, sort of.

The weekly backup and optimization runs every weekend.

I noticed the optimization job was still running this afternoon after
it had begun at 1 am. Normally the opto takes just a few minutes.

I tried to stop the job but it wouldn't so I stopped and restarted the
database and that ended the job.

Next, I expanded the size of the database and reran the jobs.
Everything seemed to work okay after that.

After getting everything running again, the database backup was about
25% larger than before.

Last week I gave a guy rights to create views on the database. He
created about 4 or 5.

All I can guess it that those views took up space and when the opto
started their wasn't enough space to run everything and it hung.

regards,
-David
Jul 20 '05 #4
wireless (wi*********@yahoo.com) writes:
Last week I gave a guy rights to create views on the database. He
created about 4 or 5.

All I can guess it that those views took up space and when the opto
started their wasn't enough space to run everything and it hung.


Views don't take up space (save for the source text), unless they are
indexed.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #5
Erland Sommarskog <es****@sommarskog.se> wrote in message news:<Xn**********************@127.0.0.1>...
In any case, you can try a SELECT * from the table in Query Analyzer. Since
QA by default does not have a timeout, you will not get an error. Then
again, if John's suspicion is right that there is blocking, then you can
wait forever. Nevertheless, do run that query, and pay attention to the
spid which you find in the status bar of QA, in parentheses after the
server name. Then open a second query window, and run sp_who. Find your
spid, and check the Blk column. If that column has a non-zero value,
the value in spid is the blocking process. Use KILL to terminate that
process, and you will get data back in the first query window.


Erland, as always, thanks for the tutorial.

I found out what was causing the problem or at least the process that
was.

Every Sunday morning three jobs run - backup, opto, and error
checking.

For some reason the opto job was not able to finish - or stop. This
was preventing any querying of the table. Other tables could be
queried.

I tried stopping the job but was unsucessful so I stopped and
restarted the database. This stopped the job.

I increased the percentage of free space that is left after opto and
reran successfully.

The table was accessible after that.

All I've come up with is a few days ago I gave a dba at our company
rights to create a view (but nothing else). He created 4 views. He
said he tried to create a 5th the day before this problem occurred but
said it would never complete and I think he said he killed it. He's
an oracle dba so maybe it didn't work the way he thought.

I'm not sure if doing this used up all the room before the database
automatically increased the size and then the opto didn't have enough
room to run and hung. That's all I've been able to come up with.

Now that I think about it, maybe his create view process was still
running and therefore opto was waiting on it to complete which it
never did.

regards,
-David
Jul 20 '05 #6
wireless (wi*********@yahoo.com) writes:
All I've come up with is a few days ago I gave a dba at our company
rights to create a view (but nothing else). He created 4 views. He
said he tried to create a 5th the day before this problem occurred but
said it would never complete and I think he said he killed it. He's
an oracle dba so maybe it didn't work the way he thought.


Creating a view takes no time at all. And neither does views take up
space. Unless, as I think I pointed out in a previous post, they are
indexed.

It seems there is a whole lot of information of what happened, to tell
anything for sure.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #7

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

Similar topics

2
by: p2esp | last post by:
Hello, I'm using the xmlrpclib module to contact an XMLRPC server that takes a long time to send results back. My client timeouts. The question is whether there is a way to have an xmlrpclib...
4
by: Laphan | last post by:
Hi Guys I've been using text files for Tab-Delimited/ADO/ASP sites so that users can update and display their products lists through my system with relative ease. Only problem is that for the...
4
by: zmcelrath87 | last post by:
I am having a problem involving the scope of timeouts and intervals. Since timeouts and intervals execute in the global scope, dynamically generated local interval/timeout declarations do not work,...
2
by: mircu | last post by:
Hi, I need a quick solution to make my application behave correctly when one of these timeouts occurs. I have some logic in session_start but when the authentication cookie timeouts the user is...
3
by: George Homorozeanu | last post by:
I have an ASP.Net application that works with MS SQL Server in background to show some infomartions to the users. I also have build the functionality for downloading this information in a...
2
by: Wolter Kamphuis | last post by:
Hi all, I've got a question, not really about PHP but this is the best audience. Is anybody aware of problems with Internet Explorer not sending any get/post/cookie data? I'm the webmaster of...
1
by: =?Utf-8?B?VCBSYXkgSHVtcGhyZXk=?= | last post by:
I have an ASP.NET 2.0 web app using forms authentication and an ASP.NET Membership database. Internal users access the app from the intranet, but they are authenticated by the membership module....
5
by: buggex | last post by:
Hey! I have runned into a strange problem, when trying to setup a serial port. The code I use to open the port: // Opening the Port "COM1" hComm = CreateFile( "COM1", GENERIC_READ | GENERIC_WRITE,...
10
by: Zytan | last post by:
I have a TcpClient. I set the read/write timeouts at 1 minute (in milliseconds). I get a NetworkStream from it and confirm the timeouts still exist. I do a NetworkStream.Write() and then a...
1
by: lakshmiRam | last post by:
hi i have written the following code to receive data from mobile using bluetooth through serial communication. but it is not working <code> #include <stdio.h> #include <conio.h> #include...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
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.