SQL 2005 client to SQL 2000 server... cmdshell problems...

  • Hi

    One of our QA'ists is using SQL 2005 client to connect to a SQL 2000 server... calling a proc on the server that uses xp_cmdshell. His client returns

    Msg 229, Level 14, State 5, Procedure xp_cmdshell, Line 30

    EXECUTE permission denied on object 'xp_cmdshell', database 'master', owner 'dbo'.

    Now as its client I cant then enable xp_cmdshell as far as I can see

    Msg 15123, Level 16, State 1, Procedure sp_configure, Line 79

    The configuration option 'xp_cmdshell' does not exist, or it may be an advanced option.

    As its trying to run that on the 2000 box.

    Is there anyway to sort this ? and Id also like to understand why its happening ... its only teh client so why does it care so to speak as its only a front end to the 2005 box ??

    thanks simon

  • First of all, let me strongly prevent you to grant execute permissions to that to anyone without explicit need to run it. Reasons? To mention just one, the user must be a member of sysadmin as well as administrator of the server. This is powerful enough not to grant execute to anyone other that a sysadmin account. I have done it in the past for someone who need to check a process, but always in the development environment, never in production. After the test is completed I revoke those permissions. Remember "the less the better" when it comes to permissions

    The processes running xp_cmdshell usually are system processes run by the service account to create something the user might need and is pretty powerful. Let's say you need to create a few files and send them to a different location (I don't see why developers don't use DTS or SSIS to run this kind of jobs, but anyhow they do) When that is run, the service account execute the command shell procedure for them.

    Why they need to run xp_cmdshell? What process? Can this be created in a different way? Good luck!! There quite a few articles regarding this matter in BOL, here in SQLCentral, and you can google them up to read a little more about that. Hope this give you some light :w00t:

  • I'm completely with Fernando on this xp_cmdshell attitude !

    Johan

    Learn to play, play to learn !

    Dont drive faster than your guardian angel can fly ...
    but keeping both feet on the ground wont get you anywhere :w00t:

    - How to post Performance Problems
    - How to post data/code to get the best help[/url]

    - How to prevent a sore throat after hours of presenting ppt

    press F1 for solution, press shift+F1 for urgent solution 😀

    Need a bit of Powershell? How about this

    Who am I ? Sometimes this is me but most of the time this is me

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply