Archive

Posts Tagged ‘timeout’

increase sudo timeout

February 12, 2017 Leave a comment

Problem
You want to increase the sudo password remember timeout.

Solution
Run “sudo visudo“, then add this line to the end:

Defaults    timestamp_timeout=60

Where 60 means 60 minutes. If you specify -1, then the password is never forgotten (which is not a good idea IMO).

Tip from here.

Categories: bash, linux Tags: ,

Grub timeout doesn’t work sometimes

Problem
In the Grub menu you can use a countdown mechanism. However, sometimes it doesn’t work and you have to press Enter manually.

I figured out that this happens when my machine was not shut down normally. Sometimes my machine doesn’t halt and I need to press the power button manually. At the next boot the timeout is gone in my grub menu.

Solution
When the machine was stopped abnormally, a “recordfail timeout” will be used. So simply add the following line to “/etc/default/grub“:

GRUB_RECORDFAIL_TIMEOUT=7

My “grub” file looks like this:

GRUB_DEFAULT=0
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=7
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="acpi=noirq splash"
GRUB_CMDLINE_LINUX=""

GRUB_RECORDFAIL_TIMEOUT=7

After editing don’t forget to run “update-grub“.

Tip from here.

Categories: ubuntu Tags: , , ,