SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 Data Corruption Issues
 Script causes SQL2005 to crash
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

rockmoose
SQL Natt Alfen

Sweden
3279 Posts

Posted - 07/03/2006 :  09:56:28  Show Profile  Reply with Quote
I am not sure if this is the right forum,
but a sql crash might cause data corruption ?!

Anyway I have tried this on 2 different sql2005 sp1 installations.
(Developer Edition)
And in both cases the last piece of code causes the sql server to stop cold (crash).

script originally posted here(afaik):
### link removed ###


####################
I removed the script
Didn't seem like a good idea to make this kind of thing public
####################



rockmoose

Edited by - rockmoose on 07/03/2006 10:36:43

nr
SQLTeam MVY

United Kingdom
12543 Posts

Posted - 07/03/2006 :  10:12:09  Show Profile  Visit nr's Homepage  Reply with Quote
My first reaction is that it looks pretty simple but I'm not going to try it.
What happens if you remove the fmtonly?
What happens if you don't call StrConcatBack

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.

Edited by - nr on 07/03/2006 10:12:22
Go to Top of Page

rockmoose
SQL Natt Alfen

Sweden
3279 Posts

Posted - 07/03/2006 :  10:17:07  Show Profile  Reply with Quote
If you remove the FMT ONLY it doesn't crash.

I haven't investigated further to see what the exact combination of commands that causes the crash is.


rockmoose

Edited by - rockmoose on 07/03/2006 10:18:28
Go to Top of Page

mr_mist
Grunnio

United Kingdom
1870 Posts

Posted - 07/03/2006 :  10:26:25  Show Profile  Visit mr_mist's Homepage  Reply with Quote
It happily crashes my dev edition sp1 too.

-------
Moo. :)
Go to Top of Page

rockmoose
SQL Natt Alfen

Sweden
3279 Posts

Posted - 07/03/2006 :  10:46:06  Show Profile  Reply with Quote
Can a forum moderator chip in and say it is ok to put the code back / or not.

rockmoose
Go to Top of Page

spirit1
Cybernetic Yak Master

Slovenia
11751 Posts

Posted - 07/03/2006 :  11:00:00  Show Profile  Visit spirit1's Homepage  Reply with Quote
hey i'd like to see that too


Go with the flow & have fun! Else fight the flow
Go to Top of Page

nr
SQLTeam MVY

United Kingdom
12543 Posts

Posted - 07/03/2006 :  11:38:04  Show Profile  Visit nr's Homepage  Reply with Quote
Could email it to paulrandal.
If you send it to me I'll get someone from microsoft to look at it next time I'm home (probably tomorrow evening).

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.

Edited by - nr on 07/03/2006 11:39:32
Go to Top of Page

Kristen
Test

United Kingdom
22415 Posts

Posted - 07/03/2006 :  13:17:05  Show Profile  Reply with Quote
"If you send it to me I'll get someone from microsoft to look at it next time I'm home"

Home = Microsoft? !!
Go to Top of Page

nr
SQLTeam MVY

United Kingdom
12543 Posts

Posted - 07/03/2006 :  13:31:08  Show Profile  Visit nr's Homepage  Reply with Quote
quote:
Originally posted by Kristen

"If you send it to me I'll get someone from microsoft to look at it next time I'm home"

Home = Microsoft? !!



Nope - where I am at the moment I can't log in using passport so can't access any microsoft stuff.

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

jen
Flowing Fount of Yak Knowledge

Sweden
4110 Posts

Posted - 07/04/2006 :  04:10:00  Show Profile  Send jen a Yahoo! Message  Reply with Quote
i wanna see the script too... pretty please

--------------------
keeping it simple...
Go to Top of Page

paulrandal
Yak with Vast SQL Skills

USA
899 Posts

Posted - 07/05/2006 :  18:11:43  Show Profile  Visit paulrandal's Homepage  Reply with Quote
Just back from vacation - please email me the script - thanks

Paul Randal
Lead Program Manager, Microsoft SQL Server Storage Engine + SQL Express
(Legalese: This posting is provided "AS IS" with no warranties, and confers no rights.)
Go to Top of Page

rockmoose
SQL Natt Alfen

Sweden
3279 Posts

Posted - 07/05/2006 :  18:41:28  Show Profile  Reply with Quote
I have posted the script to PR

rockmoose
Go to Top of Page

nr
SQLTeam MVY

United Kingdom
12543 Posts

Posted - 07/05/2006 :  19:07:54  Show Profile  Visit nr's Homepage  Reply with Quote
Bob Ward (Microsoft) is also looking at it.


==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

paulrandal
Yak with Vast SQL Skills

USA
899 Posts

Posted - 07/05/2006 :  19:42:44  Show Profile  Visit paulrandal's Homepage  Reply with Quote
Very interesting. This certainly could have nasty side-effects if it happened at the wrong time. I'll make sure its fixed for SP2.

Does anyone know if the customer who hit this has opened a case with Product Support?

[Edit] I've hooked up with Bob Ward too.

Paul Randal
Lead Program Manager, Microsoft SQL Server Storage Engine + SQL Express
(Legalese: This posting is provided "AS IS" with no warranties, and confers no rights.)

Edited by - paulrandal on 07/05/2006 19:43:55
Go to Top of Page

spirit1
Cybernetic Yak Master

Slovenia
11751 Posts

Posted - 07/06/2006 :  10:29:55  Show Profile  Visit spirit1's Homepage  Reply with Quote
After running the script sql service was still shown as running in Services but i couldn't connect to the server.
Stoping/Starting the service didn't help.
i had to restart the virtual machine i have SQL2005 SP1 on...


Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

rockmoose
SQL Natt Alfen

Sweden
3279 Posts

Posted - 07/06/2006 :  14:18:23  Show Profile  Reply with Quote
Not the same behavior I got, it stopped in Services as well.
And there was no problem starting it again.

from sql log:
Date		2006-07-06 20:13:46
Log		SQL Server (Archive #1 - 2006-07-06 20:13:00)

Source		spid58

Message
SQL Server is terminating because of fatal exception c0000005. This error may be caused by an unhandled Win32 or C++ exception, or by an access violation encountered during exception handling. Check the SQL error log for any related stack dumps or messages. This exception forces SQL Server to shutdown. To recover from this error, restart the server (unless SQLAgent is configured to auto restart).


rockmoose
Go to Top of Page

jen
Flowing Fount of Yak Knowledge

Sweden
4110 Posts

Posted - 07/06/2006 :  22:21:00  Show Profile  Send jen a Yahoo! Message  Reply with Quote
i downloaded the sp1 from the microsoft site but before installation can begin, it says hotfix.exe is not a valid win32 application

do i need to upgrade anything else before i can patch up?


--------------------
keeping it simple...
Go to Top of Page

jen
Flowing Fount of Yak Knowledge

Sweden
4110 Posts

Posted - 07/10/2006 :  04:01:48  Show Profile  Send jen a Yahoo! Message  Reply with Quote
ok, here's what i gathered:

1. applied sp1, but error during patching encountered:

Product: Client Components
Client Components (RTM 1399 ENU) - Failure
Details: Unable to install Windows Installer MSP file

2. After reboot, all services are up

3. I issue THE SCRIPT, and encountered this error:

Msg 109, Level 20, State 0, Line 0
A transport-level error has occurred when receiving results from the server. (provider: Shared Memory Provider, error: 0 - The pipe has been ended.)

--> the sql services shut down

4. looking at event viewer, here's the error message:

SQL Server is terminating because of fatal exception c0000005. This error may be caused by an unhandled Win32 or C++ exception, or by an access violation encountered during exception handling. Check the SQL error log for any related stack dumps or messages. This exception forces SQL Server to shutdown. To recover from this error, restart the server (unless SQLAgent is configured to auto restart).

5. I started the services and sql server is running again


any updates from MS?


--------------------
keeping it simple...
Go to Top of Page

rockmoose
SQL Natt Alfen

Sweden
3279 Posts

Posted - 07/10/2006 :  05:14:59  Show Profile  Reply with Quote
That looks what I got Jen.

This may be totally unrelated, but:
My Sql Server Agent is marked as "Auto Restart if stopped unexpectedly". (So is my Sql Server)
However, the Auto Restart never happens. I have to manually restart any services after unexpected shutdown.
Go to Top of Page

spirit1
Cybernetic Yak Master

Slovenia
11751 Posts

Posted - 07/10/2006 :  05:37:30  Show Profile  Visit spirit1's Homepage  Reply with Quote
Same here.

Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

jen
Flowing Fount of Yak Knowledge

Sweden
4110 Posts

Posted - 07/10/2006 :  11:03:25  Show Profile  Send jen a Yahoo! Message  Reply with Quote
same here...

there are 3 tries for the services to try to startup... but based on the event log, it only tried once and didn't seem to persevere

when you ran the script, did you receive the error message or it never came to that point and totally crashed? quite interesting...

I can just hear the clatterings all the way at MS, engineers working double time to release sp2



--------------------
keeping it simple...
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.17 seconds. Powered By: Snitz Forums 2000