[sc] openservice failed5 : access is denied on win 7 machine

Answered [sc] openservice failed5 : access is denied on win 7 machine

  • Wednesday, May 30, 2012 9:40 AM
     
     

    hiii

    i just run the command SC delete filename to delete that file but i am geting access denied message

    along with [sc] openservice failed 5 error.

    my os is windows 7.

    can any help me to run this command successfully.

    thanx

    sanjay


All Replies

  • Wednesday, May 30, 2012 11:54 AM
     
     Answered

    How do you start the command? Are you sure that you start it with administrative rights? (E.g. from a CMD window that you started with administrative rights)

    With kind regards,

    Konrad

  • Thursday, May 31, 2012 5:33 AM
     
     

    Hi Sanjay,

    As this is related to command, I will move it to the Windows 7 Forum for better support.

    Best Regards,


    Bob Wu [MSFT]
    MSDN Community Support | Feedback to us

  • Thursday, May 31, 2012 8:49 AM
    Moderator
     
     
    You did not have permission to delete the file, or you need prompt the permission when run the commandl line. Konrad Neitzel is right.

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. ”

  • Sunday, February 03, 2013 7:32 PM
     
     

    You're right. Same problem that sanjay and solution is run CMD as administrator and only. 

    Works like a charm.

    ty