ubuntu 16.04 启动缓慢 cgroup:新的挂载选项与现有的超级块不匹配,

ubuntu 16.04 启动缓慢 cgroup:新的挂载选项与现有的超级块不匹配,

我按照这里的步骤进行操作Lubuntu 16.04 启动缓慢(cgroup:新的挂载选项与现有的超级块不匹配,将被忽略)@atomSmasher 回答。但我不知道如何应用修复。

当我跑步时sudo blkid

我得到:/dev/sda1: UUID="cf1434da-f40c-44a7-a91f-1eed360eac29" TYPE="ext4" PARTUUID="000844fb-01"

然后当我跑cat /etc/fstab

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda1 during installation
UUID=cf1434da-f40c-44a7-a91f-1eed360eac29 /               ext4         errors=remount-ro 0       1
# swap was on /dev/sda5 during installation
UUID=12d3baaf-f6d2-455e-ad35-c7278c0a5729 none            swap    sw 

我该怎么办?他提到:
fix mismatches if they exist
sudo emacs /etc/fstab
then reboot

但我该如何弥补FIX这种不匹配呢?

更新;当我运行时,dmesg你可以看到时间差距:

[    7.763395] cfg80211:   (5490000 KHz - 5730000 KHz @ 160000 KHz), (N/A, 2000 mBm), (0 s)
[    7.763397] cfg80211:   (5735000 KHz - 5835000 KHz @ 80000 KHz), (N/A, 2000 mBm), (N/A)
[    7.763399] cfg80211:   (57240000 KHz - 63720000 KHz @ 2160000 KHz), (N/A, 0 mBm), (N/A)
[   97.165431] cgroup: new mount options do not match the existing superblock, will be ignored
[   97.278868] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[   97.278871] Bluetooth: BNEP filters: protocol multicast
[   97.278876] Bluetooth: BNEP socket layer initialized
[   97.504574] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   97.515666] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   97.582966] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready

结果lbsk

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 238.5G  0 disk 
└─sda1   8:1    0 238.5G  0 part /

在此处输入图片描述

答案1

由于sudo blkid仅显示一个分区,因此问题可能是由于 /etc/fstab 中没有列出的交换分区所导致的。

尝试注释掉你的交换:

  1. sudo gedit /etc/fstab
  2. 在第二个 UUID 行前面添加“#”,使其看起来像这样:# UUID=12d3baaf-f6d2-455e-ad35-c7278c0a5729 none
  3. 节省

此时,您将不再遇到错误,但您没有交换分区或交换文件。根据您在计算机上执行的操作,您可能需要添加交换文件。

正如https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/5/html/Deployment_Guide/s2-swap-creating-file.html

  1. 使用以下命令成为 root 用户sudo -s
  2. 确定交换文件的大小。如果您使用休眠模式,则将交换文件的大小至少设置为与内存大小相同。如果您运行大量内存密集型应用程序(如视频编辑软件),则将交换文件设置为 2GB-8GB。如果您只运行轻量级网页浏览,则 512MB-1GB 就足够了,但未使用的交换空间除了占用更多磁盘空间外不会造成任何损害。
  3. 打开计算器,计算 1024*[所需交换大小(以 GB 为单位)]
  4. 回到终端,dd if=/dev/zero of=/swapfile bs=1048576 count=y其中 y 是计算器中的数字
  5. 更改交换文件的权限:chmod 0600 /swapfile
  6. 设置交换文件:mkswap /swapfile
  7. 将交换文件条目添加到 /etc/fstabsudo gedit /etc/fstab
  8. 添加行/swapfile swap swap defaults 0 0
  9. 保存然后重启

答案2

我在 Ubuntu 16.10 中看到了相同的消息和症状。

问题原来是将交换分区分配给了不存在的磁盘分区。

我注释掉了 /etc/fstab 中的交换分区,启动时间就下降到了正常时间。

我不需要分配交换分区,我有 16GB 的 RAM。

相关内容