How to change the number of minutes that the sudo password is cached

When you run any command as root, using sudo, the password is remembered for 15 minutes by default.
If you want to change the time that the password is cached, open the terminal (as root) and run:

[precode]nano /etc/sudoers [/precode]

Search for this line:

[precode]defaults env_reset[/precode]

And change it into:

[precode]defaults env_reset , timestamp_timeout=x[/precode]

where “x” is the time in minutes that the password will be cached.

Save and exit and work is done!

 

3 comments for “How to change the number of minutes that the sudo password is cached

  1. April 9, 2013 at 07:29

    My partner and I stumbled over here different web page and thought I might as well check things out.
    I like what I see so i am just following you. Look forward to going over your web page
    repeatedly.

    • April 10, 2013 at 06:50

      Welcome aboard. Hope you find the posts here of use, make sure you tell your friends about this place 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.