修复 Ubuntu Desktop 18.04 启动缓慢的问题

修复 Ubuntu Desktop 18.04 启动缓慢的问题

自从我第一次安装 Ubuntu 以来已经过去了几天,启动时间相当慢。我阅读了很多关于它的帖子,并尝试了不同的方法来解决这个问题,但都没有奏效,我只将启动时间提高了几秒钟。

我已经减少了时间配置/etc/systemd/system.conf并卸载了所有我不使用的应用程序,但什么都没有改变。

这就是我得到的systemd-analyze

Startup finished in 7.504s (kernel) + 1min 5.807s (userspace) = 1min 13.312s graphical.target reached after 1min 5.083s in userspace

然后,systemd-analyze blame

     31.467s plymouth-quit-wait.service
     22.757s dev-sda1.device
     16.636s snapd.service
     15.032s networkd-dispatcher.service
     12.792s apparmor.service
     12.510s NetworkManager-wait-online.service
     10.454s dev-loop1.device
     10.395s systemd-journal-flush.service
     10.330s dev-loop6.device
     10.271s dev-loop2.device
     10.262s dev-loop4.device
      9.820s dev-loop7.device
      9.571s NetworkManager.service
      9.335s dev-loop0.device
      9.247s dev-loop5.device
      8.671s dev-loop3.device
      8.161s accounts-daemon.service
      7.885s ModemManager.service
      7.416s grub-common.service
      5.546s udisks2.service
      4.756s systemd-logind.service
      4.715s pppd-dns.service
      3.504s thermald.service

最后,systemd-analyze critical-chain

The time after the unit is active or started is printed after the "@" character. The time the unit takes to start is printed after the "+" character. graphical.target @1min 5.083s └─multi-user.target @1min 5.082s └─kerneloops.service @46.043s +107ms └─network-online.target @46.030s └─NetworkManager-wait-online.service @33.511s +12.510s └─NetworkManager.service @23.911s +9.571s └─dbus.service @19.906s └─basic.target @19.810s └─sockets.target @19.809s └─snapd.socket @19.707s +101ms └─sysinit.target @19.691s └─apparmor.service @6.897s +12.792s └─local-fs.target @6.785s └─run-user-121.mount @40.677s └─local-fs-pre.target @6.241s └─keyboard-setup.service @4.392s +1.848s └─systemd-journald.socket @4.231s └─system.slice @4.227s └─-.slice @4.177s

我可以禁用以下任何服务吗?或者这样做会不会太危险?: plymouth-quit-wait.service dev-sda1.device snapd.service networkd-dispatcher.service

相关内容