Solved

Can't find xp_cmdshell

Posted on 2006-06-19
6
1,005 Views
Last Modified: 2012-08-14
I am missing xp_cmdshell from our master database, how can I restore it?  Thank you.
0
Comment
Question by:nkuo
  • 3
  • 3
6 Comments
 
LVL 13

Accepted Solution

by:
MikeWalsh earned 250 total points
Comment Utility
the dll is called xplog70.dll

search your machine for that to make sure it exists and exists in your sqlserver binn directory (should be where all of hte other dlls are.. if it is in the wrong path, the below won't work and you will have to put it in the right path.. by default they all go to: C:\Program Files\Microsoft SQL Server\Mssql\Binn )


sp_addextendedproc 'xp_cmdshell', 'xplog70.dll'


A word here first.. are you sure it is missing? do you have SA level access, have you looked for it under extended stored procedures in master, or are you just receiving an error when running it?
0
 

Author Comment

by:nkuo
Comment Utility
I looked everywhere.  It is also a webserver so it may have be disabled on purpose.  I need it back to run some export jobs.  And yes, I did connect as SA as well.  
0
 
LVL 13

Expert Comment

by:MikeWalsh
Comment Utility
ok. then do what I suggested.

But be careful because it may have been removed for security concerns, and it does open up security problems. Sounds like you are aware of that and will take steps to rectify that..

just follow my process to add it above after verifying the .dll exist.s

If the .dll is missing, you may have to get it off of an installation cd.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Author Comment

by:nkuo
Comment Utility
Thank you very much.  
0
 
LVL 13

Expert Comment

by:MikeWalsh
Comment Utility
no problem. did it work for you?
0
 

Author Comment

by:nkuo
Comment Utility
Hi Mike, haven't tried it yet but thought about what you said, since I have to put the data in a temp table anyway, I'm going to DTS the data to another server (xp_cmdshell still there) and run the sp from there.  Thanks again for the info, you definitely get the points for sp_addextendedproc.  Thanks again.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Join & Write a Comment

Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now