解决AppArmor启动失败.

原本apparmor已经启动运行着,执行restart的时候却失败。

使用systemctl status apparmor.service查看,显示如下内容:

*● apparmor.service - LSB: AppArmor initialization
   Loaded: loaded (/etc/init.d/apparmor; bad; vendor preset: enabled)
   Active: failed (Result: exit-code) since Wed 2018-10-10 01:54:02 PDT; 6min ago
     Docs: man:systemd-sysv-generator(8)
  Process: 68919 ExecStop=/etc/init.d/apparmor stop (code=exited, status=0/SUCCESS)
  Process: 68934 ExecStart=/etc/init.d/apparmor start (code=exited, status=123)
Oct 10 01:53:59 ubuntu apparmor[68934]: Skipping profile in /etc/apparmor.d/disable: usr.bin.firefox
Oct 10 01:54:01 ubuntu apparmor[68934]: Skipping profile in /etc/apparmor.d/disable: usr.sbin.rsyslogd
Oct 10 01:54:02 ubuntu apparmor[68934]: [109B blob data]
Oct 10 01:54:02 ubuntu apparmor[68934]: Skipping profile in /etc/apparmor.d/disable: usr.bin.firefox
Oct 10 01:54:02 ubuntu apparmor[68934]: Skipping profile in /etc/apparmor.d/disable: usr.sbin.rsyslogd
Oct 10 01:54:02 ubuntu apparmor[68934]:    ...fail!
Oct 10 01:54:02 ubuntu systemd[1]: apparmor.service: Control process exited, code=exited status=123
Oct 10 01:54:02 ubuntu systemd[1]: Failed to start LSB: AppArmor initialization.
Oct 10 01:54:02 ubuntu systemd[1]: apparmor.service: Unit entered failed state.
Oct 10 01:54:02 ubuntu systemd[1]: apparmor.service: Failed with result 'exit-code'.*

看不出问题在哪里,然后看/etc/apparmor.d/里的内容,发现之前把/bin/su文件拷贝到/etc/apparmor.d/下了,于是
sudo rm /etc/apparmor.d/su
再重启apparmor,成功。
这报的什么错误,真是卵子用都没有,还好我眼尖…

你可能感兴趣的:(解决AppArmor启动失败.)