Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
How I can make sudo session an hour and not few minutes in Ubuntu 10.04?

Ubuntu 10.10 asks password everytime I try to do some administrative task. How can I avoid it ? Uhat I can save password for a session?

share|improve this question

marked as duplicate by Bobby, 8088, Sathya May 11 '11 at 8:56

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

It's a (security) feature, not a bug!

sudo won't ask you for a time, about 15 minutes should be standard. You can adjust that to a longer value using visudo:

Defaults      env_resets,timestamp_timeout=-1

timestamp_timeout: Number of minutes that can elapse before sudo will ask for a passwd again. The default is 15. Set this to 0 to always prompt for a password. If set to a value less than 0 the user’s timestamp will never expire. This can be used to allow users to create or delete their own timestamps via sudo -v and sudo -k respectively.

If you really don't like it: log in as root (probably by setting a password first and enabling log on to X11)

share|improve this answer
Please don't...if you want to, make the sudo session last longer, I'm fine with that, but don't work as root by default and especially not with an X-Session on top of's a very effective way to nuke your system in so many different ways you can't even imagine. There's a reason why it is always frowned upon in the Unix/Linux world...hell, even Microsoft realized this (a decade too late, but hey, at least they're learning). – Bobby May 11 '11 at 9:00
@Bobby: absolutely, just as I said: it's a feature ;-) – mbx May 11 '11 at 9:05

Not the answer you're looking for? Browse other questions tagged or ask your own question.