个人工具
登录
查看“UbuntuHelp:RootSudoTimeout”的源代码 - Ubuntu中文
UbuntuHelp
讨论
查看源代码
历史
搜索
导航
首页
最近更改
随机页面
页面分类
帮助
编辑
编辑指南
沙盒
新闻动态
字词处理
工具
链入页面
相关更改
特殊页面
页面信息
查看“UbuntuHelp:RootSudoTimeout”的源代码
来自Ubuntu中文
←
UbuntuHelp:RootSudoTimeout
跳转至:
导航
,
搜索
因为以下原因,你没有权限编辑本页:
您所请求的操作仅限于该用户组的用户使用:
用户
您可以查看与复制此页面的源代码。
{{From|https://help.ubuntu.com/community/RootSudoTimeout}} {{Languages|UbuntuHelp:RootSudoTimeout}} By default sudo remembers your password for 15 minutes. If you want to change that you can do so by <pre><nowiki> sudo visudo </nowiki></pre> This opens an editor and points it to the sudoers file -- Ubuntu defaults to nano, other systems use Vi. You're now a super user editing one of the most important files on your system. No stress! (Vi specific instructions noted with (vi!). Ignore these if you're using nano) * Use the arrow keys to move to the end of the Defaults line. * (vi!) press the '''A''' (capital "a") key to move at the end of the current line and enter editing mode (append after the last character on the line). * Now type <pre><nowiki> ,timestamp_timeout=X </nowiki></pre> where X is the timeout expiration '''in minutes'''. If you specify 0 you will always be asked the password. If you specify a negative value, the timeout will never expire. E.g. Defaults env_reset,timestamp_timeout=5 * (vi!) hit '''Escape''' to return to command mode. Now, if you're happy with your editing, type in ''':w''' <'''ENTER'''> to write the file and ''':q''' <'''ENTER'''> to exit vi. If you made a mistake, perhaps the easiest way is to redo from start, to exit without saving (hit '''Escape''' to enter the command mode) and then type ''':q!''' <'''ENTER'''>. * hit '''CTRL + X''', then '''Y''', then <'''ENTER'''> to save your file and exit nano. You might want to read the sudoers and vi manual pages for additional information. <pre><nowiki> man sudoers </nowiki></pre> <pre><nowiki> man vi </nowiki></pre> [[category:UbuntuHelp]]
该页面使用的模板:
模板:From
(
查看源代码
)
模板:Languages
(
查看源代码
)(受保护)
模板:Languages/Lang
(
查看源代码
)(受保护)
返回至
UbuntuHelp:RootSudoTimeout
。