Ubuntu关机等待时间解决方案
关于GDM问题(a stop job is running for session c1 of user root 1 min 30 s)
注意了,这个不是系统的问题,是配置的问题。鼓捣了老久才找出来这个问题的解决方案。
因为每次关机都要经历这个,而且恰好到90s才开始关机,就觉得肯定是配置的问题了。
hcking@kali:~$ sudo vim /etc/systemd/system.conf
[sudo] hcking 的密码:
终端命令如上,使用VIM打开配置文件。在最后新增一行,将以下内容复制下去,重启后配置即可生效。
DefaultTimeoutStartSec=10s
DefaultTimeoutStopSec=10s
有一点要注意,请检查自己的配置文件是否所有配置前都有"#"号,如果有,按刚才的操作,如果没有,Kali2017.3 Rolling版本找到DefaultTimeoutStartSec= 和DefaultTimeOutStopSec,如果前面没有"#",将后面的数值全部改为10s即可,如果有该符号,去掉该符号后修改为10s即可。
附上我的整个配置文件:
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See systemd-system.conf(5) for details.
[Manager]
#LogLevel=info
#LogTarget=journal-or-kmsg
#LogColor=yes
#LogLocation=no
#DumpCore=yes
#ShowStatus=yes
#CrashChangeVT=no
#CrashShell=no
#CrashReboot=no
#CtrlAltDelBurstAction=reboot-force
#CPUAffinity=1 2
#JoinControllers=cpu,cpuacct net_cls,net_prio
#RuntimeWatchdogSec=0
#ShutdownWatchdogSec=10min
#CapabilityBoundingSet=
#SystemCallArchitectures=
#TimerSlackNSec=
#DefaultTimerAccuracySec=1min
#DefaultStandardOutput=journal
#DefaultStandardError=inherit
#DefaultTimeoutStartSec=90s
#DefaultTimeoutStopSec=90s
DefaultTimeoutStartSec=10s
DefaultTimeoutStopSec=10s
#DefaultRestartSec=100ms
#DefaultStartLimitIntervalSec=10s
#DefaultStartLimitBurst=5
#DefaultEnvironment=
#DefaultCPUAccounting=no
#DefaultIOAccounting=no
#DefaultIPAccounting=no
#DefaultBlockIOAccounting=no
#DefaultMemoryAccounting=no
#DefaultTasksAccounting=yes
#DefaultTasksMax=
#DefaultLimitCPU=
#DefaultLimitFSIZE=
#DefaultLimitDATA=
#DefaultLimitSTACK=
#DefaultLimitCORE=
#DefaultLimitRSS=
#DefaultLimitNOFILE=
#DefaultLimitAS=
#DefaultLimitNPROC=
#DefaultLimitMEMLOCK=
#DefaultLimitLOCKS=
#DefaultLimitSIGPENDING=
#DefaultLimitMSGQUEUE=
#DefaultLimitNICE=
#DefaultLimitRTPRIO=
#DefaultLimitRTTIME=
#IPAddressAllow=
#IPAddressDeny=
————————————————
版权声明:本文为CSDN博主「竹寒 天竺」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/m0_37217636/article/details/78935941
Ubuntu关机等待时间解决方案的更多相关文章
- Ubuntu关机时间过长,总是停在logo界面
有时候我们总能遇到ubuntu关机的时候卡住,无法关机,一查看发现是" a stop job is running..." 然后后面接着一串等待时间. 这时候我们需要修改一下sys ...
- 程序缩小到托盘后系统就无法关机(解决方案)——处理WM_QUERYENDSESSION消息,并把它标识为处理过了
程序缩小到托盘后系统就无法关机(解决方案) 老帅 程序最小化到托盘后,会出现系统无法关闭的问题,常见于WinXP系统中,这里提供一个解决方案!一.解决 ...
- ubuntu 关机命令
ubuntu 关机命令 关机命令 shutdown ubuntu的终端中默认的是当前用户的命令,只是普通用户,因此在终端器中可以使用sudo -sh 转换到管理员root用户下执行命令. 1)shut ...
- ubuntu 关机,重启,注销命令
1关机命令 shutdown 好像ubuntu的终端中默认的是当前用户的命令,只是普通用户,因此在终端器中可以使用sudo -sh 转换到管理员root用户下执行命令. 1)shutdown –hel ...
- 转摘:常用ubuntu 关机,重启,注销命令
1.关机命令 shutdown 好像ubuntu的终端中默认的是当前用户的命令,只是普通用户,因此在终端器中可以使用sudo -sh 转换到管理员root用户下执行命令. 1).shutdown –h ...
- Ubuntu关机重启后 NVIDIA-SMI 命令不能使用
问题: 电脑安装好Ubuntu系统后,后续安装了显卡驱动.CUDA.cuDNN等软件,后续一直没有关机.中间系统曾经有过升级,这也是问题所在.系统升级导致内核改变,并可能导致它与显卡驱动不再匹配,所以 ...
- 初用Ubuntu常见问题及解决方案之一
1.我的Vaio Fit15e的无线网卡是BCM43142,装了Ubuntu后为了装驱动折腾了好久,因为这款网卡在Broadcom官网都找不到驱动,google了一大圈,一个最简单的命令可以解决这个问 ...
- Ubuntu 当黑屏解决方案安装
前几天我就已经安装Red hat 企业版,只是可惜它并没有提供数据源.我能够安装自己的软件,但我不能完全靠解决,因此,我们决定改变系统,最后我选择ubuntu.随时下载系统.然后用u盘制作启动盘,全部 ...
- ubuntu关机重启命令
重启命令 : 1.reboot 2.shutdown -r now 立刻重启 3.shutdown -r 10 过10分钟自动重启 4.shutdown -r 20:35 ...
随机推荐
- poj 2376 Cleaning Shifts 贪心 区间问题
<pre name="code" class="html"> Cleaning Shifts Time Limit: 1000MS Memory ...
- 遍历 ArrayList与Map集合
import java.util.ArrayList; import java.util.Iterator; import java.util.List; /** * 遍历 ArrayList * @ ...
- Spring常用的jar+普通构造注入
常用工具 jar 说明 提供AOP(面向切面编程)实现:spring -aop spring提供对AspectJ框架的整合:spring-aspects 提供 IoC(控制反转)的基础实现:sprin ...
- git commit 合并到指定分支
1. 将指定的commit合并到当前分支 git cherry-pick commit_id 2. 合并多个连续 commit 到指定分支 假设需要合并 devlop 上从 fb407a3f 到 9 ...
- mysql统计前24小时数据没有补0
SELECT t1. HOUR HOUR, COUNT(t2. HOUR) count FROM ( SELECT DATE_FORMAT( HOUR), '%y-%m-%d %H' ) HOUR F ...
- layui按回车键实现表单提交
layui中标准用法如下: <form class="layui-form"> <input type="button" id="q ...
- java 百度地图判断两点距离2
package baiduApi; public class BaiDuMap { static double DEF_PI = 3.14159265359; // PI static double ...
- FScapture录屏后导致麦克风无声问题
- C# 中使用RegisterShellHookWindow Hook窗体创建
前言:最近在写一个桌面程序时需要全局HOOK 窗体的创建,但是在.net中SetWindowsHookEx()只可实现键盘鼠标的全局钩子,其余的全局钩子都需要使用DLL.难道就没有解决办法了么?经过长 ...
- Node fs 创建多层文件夹
一.dirname()方法 1. 获得路径当中最后一段文件或文件夹所在的路径.多次调用path.dirname将会逐层返回上级目录 var path=require("path") ...