我的Ubuntu 16.04挂起在关机/重新启动,需要我按住电源键以关闭计算机。信息?任何帮助将不胜感激!
我的Ubuntu 16.04挂起在关机/重新启动,需要我按住电源键以关闭计算机。信息?任何帮助将不胜感激!
Answers:
我也有这个问题。它似乎是多个发行版中的错误。
我的简单解决方法是编辑/etc/default/grub
行:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
至
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi=force"
运行update-grub
。
现在每次都可以使用。我使用联想G50笔记本电脑。我很确定我也用这台笔记本电脑上的先前(其他)Linux发行版在Grub中更改了此行。
update-grub
,但没有成功。然后,将其更改为GRUB_CMDLINE_LINUX_DEFAULT =“ acpi = force”,这解决了我的问题。
dist-upgrade
吗?
完成工作并完成关闭所有应用程序以关闭或重新启动操作系统后,请按照以下步骤操作以减轻沮丧感。
sudo swapoff -a && systemctl poweroff
现在尝试作为解决方法。/usr/share/doc/systemd/README.Debian.gz
,检查关闭时是否有任何挂起的作业。您将需要在每次关闭或重新启动之前启动调试外壳,方法是输入:在救援外壳中systemctl start debug-shell
捕获屏幕journalctl -b
快照ctl+alt+F9
可能很有启发性。另外的输出systemctl list-jobs
和systemctl --failed
另外一个屏幕截图,你可以转储这些命令的输出,并追加到每一个在同一个“filename.text” /
加根>>filename.text
在命令结束,例如journalctl -b >>filename.text
journalctl -xe >>filename.text
systemctl list-jobs >>filename.text
systemctl --failed >>filename.text
lsblk >>filename.text
所有这些将在附加到一起的同一个文件以便您在下次启动时进行分析,如果您提交了错误报告,将文件附加到错误报告中可能会有所帮助。更新资料
我已经挂了好一阵子了,但最终还是得知我的硬盘开始出现扇区故障等。因此,该重新安装新硬盘了。根据Ubuntu的建议,我将操作系统重新安装在具有Swap作为第一分区,Root作为第二分区以及Home作为第三逻辑分区的单引导HDD上。从技术上讲,sda1是Grub,sda2是Extended,sda5,sda6,sda7分别是swap,root和home。sda3和sda4不存在。从那时起,大约9个多月以来,HDD上新安装的OS上一直没有出现此问题。我目前正在运行16.04.02 LTS,而没有在重新启动或关闭时挂起。以前的操作系统是双重安装Win7 / Ubuntu,而Swap分区位于HDD的末尾。
我并不是在说这个问题与双引导系统,故障的HDD或我放置分区的顺序有关,但就我而言,存在一个,两个或所有这些因素。现在,我不再遭受“达到目标关闭”挂起的困扰。
reached target shutdown
它一直抽不出来revalidation failed
我在关机时挂了一个问题,这是我所做的:
开放式终端
sudo -H gedit /etc/default/grub
更改行:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
至
GRUB_CMDLINE_LINUX_DEFAULT="acpi=force"
通过在关闭过程中删除quiet
并splash
允许显示文本,有助于查看挂起的位置。
GRUB_CMDLINE_LINUX_DEFAULT =“ quiet splash”此处删除“ quiet”将在启动期间显示文本输出,而删除“ splash”将显示黑屏而不是启动图像。
保存并关闭Gedit
然后在终端中更新Grub:
sudo update-grub
额外:
我注意到我也正在运行“ STOP JOB”,因此我减少了超时时间/etc/systemd/system.conf
:
sudo -H gedit /etc/systemd/system.conf
删除#
并更改以下几行中的时间:
DefaultTimeoutStartSec=5s
DefaultTimeoutStopSec=5s
然后运行:
sudo systemctl daemon-reload
这对我有用。
特纳姆。我有同样的情况。我刚刚使用将系统从14.04更新到16.04 do-release-upgrade -d
。
如果您没有直接访问系统的权限,并且确实需要重新引导,则可以尝试硬重置作为一种解决方法(如此处所述:https : //major.io/2009/01/29/linux-emergency-重启-或关断与-魔命令/)
echo 1 > /proc/sys/kernel/sysrq
echo b > /proc/sysrq-trigger
绝招。可能您应该sync
在第二个命令之前运行。
reboot -f
可能有帮助,但我没有尝试过,因为如果服务器再次挂起,我将无法访问服务器。
您可以检查/ var / log / syslog文件。找到打开计算机的位置,然后检查计算机。您可以将其粘贴在此处。
我的系统日志:
Apr 29 11:21:48 bow NetworkManager[875]: <warn> [1461907308.0752] dhcp4 (em0): request timed out
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.0753] dhcp4 (em0): state changed unknown -> timeout
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.0918] dhcp4 (em0): canceled DHCP transaction, DHCP client pid 2437
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.0918] dhcp4 (em0): state changed timeout -> done
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.0929] device (em0): state change: ip-config -> failed (reason 'ip-config-unavailable') [70 120 5]
Apr 29 11:21:48 bow NetworkManager[875]: <warn> [1461907308.0943] device (em0): Activation: failed for connection 'Wired connection 1'
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.0970] device (em0): state change: failed -> disconnected (reason 'none') [120 30 0]
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1062] policy: auto-activating connection 'Wired connection 1'
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1101] device (em0): Activation: starting connection 'Wired connection 1' (df58434d-16fc-4036-b1d2-2cae515dbf19)
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1108] device (em0): state change: disconnected -> prepare (reason 'none') [30 40 0]
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1133] device (em0): state change: prepare -> config (reason 'none') [40 50 0]
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1152] device (em0): state change: config -> ip-config (reason 'none') [50 70 0]
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1167] dhcp4 (em0): activation: beginning transaction (timeout in 45 seconds)
Apr 29 11:21:48 bow NetworkManager[875]: <info> [1461907308.1221] dhcp4 (em0): dhclient started with pid 2444
Apr 29 11:21:48 bow dhclient[2444]: DHCPDISCOVER on em0 to 255.255.255.255 port 67 interval 3 (xid=0x6cc9f4a)
Apr 29 11:21:51 bow dhclient[2444]: DHCPDISCOVER on em0 to 255.255.255.255 port 67 interval 4 (xid=0x6cc9f4a)
Apr 29 11:21:55 bow dhclient[2444]: DHCPDISCOVER on em0 to 255.255.255.255 port 67 interval 11 (xid=0x6cc9f4a)
Apr 29 11:22:01 bow CRON[2453]: (root) CMD (/usr/local/lib/wifictl)
Apr 29 11:22:01 bow CRON[2450]: (CRON) info (No MTA installed, discarding output)
Apr 29 11:22:06 bow dhclient[2444]: DHCPDISCOVER on em0 to 255.255.255.255 port 67 interval 20 (xid=0x6cc9f4a)
.................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................
Apr 29 11:23:34 bow rsyslogd: [origin software="rsyslogd" swVersion="8.16.0" x-pid="860" x-info="http://www.rsyslog.com"] start
Apr 29 11:23:34 bow rsyslogd-2222: command 'KLogPermitNonKernelFacility' is currently not permitted - did you already set it via a RainerScript command (v6+ config)? [v8.16.0 try http://www.rsyslog.com/e/2222 ]
Apr 29 11:23:34 bow rsyslogd: rsyslogd's groupid changed to 104
Apr 29 11:23:34 bow rsyslogd: rsyslogd's userid changed to 101
Apr 29 11:23:34 bow kernel: [ 0.000000] Initializing cgroup subsys cpuset
Apr 29 11:23:34 bow kernel: [ 0.000000] Initializing cgroup subsys cpu
Apr 29 11:23:34 bow kernel: [ 0.000000] Initializing cgroup subsys cpuacct
Apr 29 11:23:34 bow kernel: [ 0.000000] Linux version 4.4.0-21-generic (buildd@lgw01-21) (gcc version 5.3.1 20160413 (Ubuntu 5.3.1-14ubuntu2) ) #37-Ubuntu SMP Mon Apr 18 18:33:37 UTC 2016 (Ubuntu 4.4.0-21.37-generic 4.4.6)
似乎即使请求重新启动,dhclient也会尝试获取IP地址。
如果这是与硬件相关的问题,我会粘贴的输出lspci
,以帮助进行故障排除。
00:00.0 Host bridge: Intel Corporation Atom Processor D2xxx/N2xxx DRAM Controller (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Atom Processor D2xxx/N2xxx Integrated Graphics Controller (rev 09)
00:1c.0 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 1 (rev 02)
00:1c.1 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 2 (rev 02)
00:1d.0 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #1 (rev 02)
00:1d.1 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #2 (rev 02)
00:1d.2 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #3 (rev 02)
00:1d.3 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #4 (rev 02)
00:1d.7 USB controller: Intel Corporation NM10/ICH7 Family USB2 EHCI Controller (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e2)
00:1f.0 ISA bridge: Intel Corporation NM10 Family LPC Controller (rev 02)
00:1f.2 SATA controller: Intel Corporation NM10/ICH7 Family SATA Controller [AHCI mode] (rev 02)
00:1f.3 SMBus: Intel Corporation NM10/ICH7 Family SMBus Controller (rev 02)
01:00.0 Ethernet controller: Intel Corporation 82574L Gigabit Network Connection
02:00.0 Ethernet controller: Intel Corporation 82574L Gigabit Network Connection
03:00.0 Network controller: Qualcomm Atheros AR9227 Wireless Network Adapter (rev 01)
我尝试了几种方法,包括:编辑/etc/default/grub
,sudo swapoff -a
在关机前运行等。但是这些方法都不适合我。
USB 3.0 legacy mode
在BIOS中关闭对我有用。
我只是遇到了一些相同的问题,重新启动会使我进入黑屏,或者有时黑屏会闪烁的光标,而且永远无法实现,我必须指出,关机没有问题。
所以我要做的是,打开驱动器管理器,为CPU安装了Intel-Microcode固件,关闭了计算机,然后又厌倦了重新启动OS的工作,终于可以了。
我在基于Ubuntu Xenial Xerus 16.04 LTS的Linux Mint Cinnamon 18.3上。
在答案中添加用户ssasa的评论,因为它可以帮助其他人,并且可能会被“不再需要”标志清除:
在这里尝试了每个答案,没有帮助。但这是最接近的。从开源驱动程序nouveau更改为Nvidia专有驱动程序对我而言很有帮助。