个人工具
登录
查看“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 the vi editor (by default) and points it to the sudoers file. You're now a super user editing one of the most important files on your system. No stress! Vi instructions: Vi is modeful editor and a bit klunky to use. Use the arrow keys to move to the end of the Defaults line. Then press they '''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). In Ubuntu, visudo opens nano. 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 Then 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'''>. 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
。