Results 1 to 7 of 7

Thread: help with visudo

  1. #1
    Join Date
    Nov 2009
    Location
    India
    Posts
    52

    Default help with visudo

    I was trying to make shutdown without root user using visudo

    I tried the following still it did not work for me

    hawk ALL=NOPASSWD:/sbin/shutdown -h now
    Manu Gupta
    Manipal Institute Of Technology
    Manipal, Karnataka - 576104
    India

  2. #2
    Join Date
    Aug 2008
    Location
    Seattle, WA
    Posts
    1,376

    Default Re: help with visudo

    It may require a reboot for this to apply. Have you already done this?

  3. #3
    Join Date
    Nov 2009
    Location
    India
    Posts
    52

    Default Re: help with visudo

    yes

    I also tried hawk ALL = NOPASSWD: /sbin/shutdown
    Manu Gupta
    Manipal Institute Of Technology
    Manipal, Karnataka - 576104
    India

  4. #4
    Join Date
    Nov 2009
    Location
    India
    Posts
    52

    Default Re: help with visudo

    also it still asks for root password
    Manu Gupta
    Manipal Institute Of Technology
    Manipal, Karnataka - 576104
    India

  5. #5
    Join Date
    Aug 2008
    Location
    Seattle, WA
    Posts
    1,376

    Default Re: help with visudo

    Are you including 'sudo' when you type the command?

    sudo /sbin/shutdown -h now

  6. #6

    Default Re: help with visudo

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1

    This is an example that should work:

    hawk ALL=(ALL) NOPASSWD: /sbin/shutdown

    Also sudoers file changes apply immediately (no reboot/login/loout required).

    Good luck.





    On 06/13/2010 02:46 PM, chief sealth wrote:
    >
    > Are you including 'sudo' when you type the command?
    >
    > -sudo /sbin/shutdown -h now-
    >
    >

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v2.0.12 (GNU/Linux)
    Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

    iQIcBAEBAgAGBQJMFVimAAoJEF+XTK08PnB53FcP/033peiDHlGj4eugMGwKRbDY
    UPkXJ/h9S8sfKlzS2ZgvVoX3YixGE9BFQkIFNGhLDqE7U+ZRK1fbzA+bE3tk5/i7
    wwpoD1wbAUFi5s60HvQKQWPLKzVhll4WqnufEC+btKNRFpDf2ZCB7EFTZ9NHLmgS
    VVx6C7aOOmt21vZ9ICesSDkBcz9b0oCXQ7aGwYxdOaA4U5TcEVWJFKlGW1O3zTUT
    RHT3RKB62faEvdNx2FPZw/JX3/kpxRB66LSvIymeIcaSFk+fHwQe7ZXDqkGYgGfh
    d5al2C5+74D+fEuesu3RnPWE0/TeJSOmWmkV7ky94PTlThWheD96mB1JqRHlQVpB
    V2JOWDqm5P0H25pDgI712RrReT52D6x5oAIV8fAtEP+xTEX6417VJ7IptYteyVCo
    S9jihyXa765vFrqmIiCO1lcnhyopS3FcwMt4vw0fweu5FWBbabz2J/AV/MlNJ2Lk
    JkMRbR1ccFcOUeTVGT6XHNmETUs8BrmRhFnijoBAMIUFMIXXDnzVty4QjQ8Rcig+
    wJG1EJ/JelMR960iVB0yG7quUY0cgkhau0jXo/g3xwMZo9ZP/tQfx83WSGJW2vp8
    oyrYqjZLHbb6uAvukhZ/HbeRHhg7nMZj3GVR7okmAXf0/276IQvuG23j3p21O3DI
    MafqWarNvOThZTPkxTqj
    =su49
    -----END PGP SIGNATURE-----

  7. #7
    Join Date
    Nov 2009
    Location
    India
    Posts
    52

    Default Re: help with visudo

    Quote Originally Posted by chief_sealth View Post
    Are you including 'sudo' when you type the command?

    sudo /sbin/shutdown -h now
    Yes this worked I missed it thanks a lot chief
    Manu Gupta
    Manipal Institute Of Technology
    Manipal, Karnataka - 576104
    India

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •