I enter my first sudo
command. I enter my password. For в while, I wont have to enter my password for subsequent вспотел commands.
Now the question. I am someone who opens в lot of terminals. It would be very convenient if I don't have to enter passwords when I использовал sudo
in the terminals I open after my first вспотел, for the short украдите when I wont have to enter password for я отдаю in the терминал from which I have used вспотел for the first украдите. (Sorry for the long sentence!)
Is it possible? If not, why? If yes, how?
Уверенный это. Выполненный sudo visudo
и добавляют эту строку к Вашему sudoers
файл:
Defaults !tty_tickets
, Как объяснено в man sudoers
:
tty_tickets If set, users must authenticate on a per-tty basis.
With this flag enabled, sudo will use a separate record
in the time stamp file for each tty. If disabled, a
single record is used for all login sessions. This
flag is on by default.
установка tty_tickets
By к прочь (это - что !
средства), Вы позволяете единственной аутентификации быть совместно использованной несколькими сессиями.
Итак, вот что вы хотите сделать, чтобы sudo запрашивал ваш пароль только один раз при загрузке:
/etc/sudoers.d/00_prompt_once:
## Only ask for the password once for all TTYs per reboot.
## See https://askubuntu.com/a/1278937/367284 and
## https://github.com/hopeseekr/BashScripts/
Defaults !tty_tickets
Defaults timestamp_timeout = -1