Click here to Skip to main content
11,705,451 members (59,895 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: SQL-server-2005 ASP.NET SQL , +
Hi All,

How to know whether xp_cmdshell in sql server 2008 crashes or not,
i used this xp_cmdShell in multiple procedures but some times it is crashes and not working , for that i need to send an email when the xp_cmdshell is crashed, can any body help me how can i know the crashes of xp_cmdShell

Thanks & Regards
Posted 18-Mar-13 20:06pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

What do you mean by "crashes"?? xp_cmdshell doesn't crash, so your statement doesn't make any sense.

It does, however, return a 0 or 1 depending on if the command was successfully launched. It does NOT tell you if the command it launched was executed successfully or not.

OH, and for future reference, you might want to read these[^].
Sudheer Nimmagadda at 20-Mar-13 0:47am
Hi Dave Kreskowiak,

thanks for your reply, but xp_cmdshell is return 0 or 1 based on result its ok,
But my problem is every day at the same time we have to run multiple procedures,
these procedures are using xp_cmdshell and if it is bulk usage on that time it is crashes and not working, please give me how can i know whether the xp_cmdshell is working or not
Dave Kreskowiak at 20-Mar-13 7:44am
Again, what do you mean by "crashes"? That isn't an acurate description of exactly what happens.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 500
1 OriginalGriff 269
2 CPallini 82
3 ppolymorphe 68
4 Inimicos 60
0 OriginalGriff 9,053
1 Sergey Alexandrovich Kryukov 8,347
2 CPallini 5,189
3 Maciej Los 4,726
4 Mika Wendelius 3,626

Advertise | Privacy | Mobile
Web03 | 2.8.150819.1 | Last Updated 19 Mar 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100