转载:http://blog.chinaunix.net/uid-7713641-id-5748056.html

我习惯于在shell里面init 0了,不过今天碰到这个怪事,init 0以后,电脑屏幕显示,a stop job is running for session [sessionid] of user,倒计时过了1分30秒电脑才关机。
搜索了半天都说是systemd 的bug. 
各种解决方案我也来罗列一下:
1. ubuntu/debian  最简单

点击(此处)折叠或打开

  • apt-get install watchdog
  • systemctl enable watchdog
  • systemctl start watchdog
  • 2. Fedora
    在systemd-timesyncd.service 规则里面添加一条规则。

    点击(此处)折叠或打开

  • systemctl edit systemd-timesyncd.service
  • #加入下面的规则
  • [Service]
  • TimeoutStopSec=1s
  • #验证规则
  • systemctl cat systemd-timesyncd.service
  • systemctl show systemd-timesyncd.service
  • 我发现我只是安装了watchdog ,然后就再没有出现这个提示,但是watchdog 到底是什么呢?
    找到了介绍watchdog的网站是比较详细的。

    相关文章: