为什么我在 Ubuntu 登录之前会看到“正在启动 snappy 守护程序 [ok]”

为什么我在 Ubuntu 登录之前会看到“正在启动 snappy 守护程序 [ok]”

在我启动计算机之后,登录加载之前,我开始看到文本“正在启动 snappy 守护进程 [ok]”。

该文本并不总是显示。

另外,我运行了命令“sudo systemctl status snap*”,虽然我没有安装任何与 snappy 相关的东西,但输出是:

    ● snapd.refresh.timer - Timer to automatically refresh installed snaps
   Loaded: loaded (/lib/systemd/system/snapd.refresh.timer; enabled; vendor pres
   Active: active (waiting) since Tue 2017-10-03 05:16:34 PDT; 7min ago

Oct 03 05:16:34 hpe systemd[1]: Started Timer to automatically refresh installed

● snapd.socket - Socket activation for snappy daemon
   Loaded: loaded (/lib/systemd/system/snapd.socket; enabled; vendor preset: ena
   Active: active (running) since Tue 2017-10-03 05:16:34 PDT; 7min ago
   Listen: /run/snapd.socket (Stream)
           /run/snapd-snap.socket (Stream)

Oct 03 05:16:34 hpe systemd[1]: Starting Socket activation for snappy daemon.
Oct 03 05:16:34 hpe systemd[1]: Listening on Socket activation for snappy daemon

● snap-repair.timer - Timer to automatically fetch and run repair assertions
   Loaded: loaded (/lib/systemd/system/snap-repair.timer; enabled; vendor preset
   Active: active (waiting) since Tue 2017-10-03 05:16:34 PDT; 7min ago

Oct 03 05:16:34 hpe systemd[1]: Started Timer to automatically fetch and run rep

● snapd.service - Snappy daemon
   Loaded: loaded (/lib/systemd/system/snapd.service; enabled; vendor preset: en
lines 1-23...skipping...
● snapd.refresh.timer - Timer to automatically refresh installed snaps
   Loaded: loaded (/lib/systemd/system/snapd.refresh.timer; enabled; vendor preset: enabled)
   Active: active (waiting) since Tue 2017-10-03 05:16:34 PDT; 7min ago

Oct 03 05:16:34 hpe systemd[1]: Started Timer to automatically refresh installed snaps.

● snapd.socket - Socket activation for snappy daemon
   Loaded: loaded (/lib/systemd/system/snapd.socket; enabled; vendor preset: enabled)
   Active: active (running) since Tue 2017-10-03 05:16:34 PDT; 7min ago
   Listen: /run/snapd.socket (Stream)
           /run/snapd-snap.socket (Stream)

Oct 03 05:16:34 hpe systemd[1]: Starting Socket activation for snappy daemon.
Oct 03 05:16:34 hpe systemd[1]: Listening on Socket activation for snappy daemon.

● snap-repair.timer - Timer to automatically fetch and run repair assertions
   Loaded: loaded (/lib/systemd/system/snap-repair.timer; enabled; vendor preset: enabled)
   Active: active (waiting) since Tue 2017-10-03 05:16:34 PDT; 7min ago

Oct 03 05:16:34 hpe systemd[1]: Started Timer to automatically fetch and run repair assertions.

● snapd.service - Snappy daemon
   Loaded: loaded (/lib/systemd/system/snapd.service; enabled; vendor preset: enabled)
   Active: active (running) since Tue 2017-10-03 05:16:39 PDT; 7min ago
 Main PID: 1160 (snapd)
   CGroup: /system.slice/snapd.service
           └─1160 /usr/lib/snapd/snapd

Oct 03 05:16:34 hpe systemd[1]: Starting Snappy daemon...
Oct 03 05:16:38 hpe snapd[1160]: 2017/10/03 05:16:38.072701 daemon.go:252: started snapd/2.27.5 (seri
    Oct 03 0

5:16:39 hpe systemd[1]: Started Snappy daemon.

答案1

请注意,如果没有使用 snap,snapd 就不应该一直运行,它是通过套接字激活的...打印“启动 snappy 守护进程 [ok]”的 systemd 单元只设置了在您使用 snap 命令后通过其启动 snapd 的套接字。

答案2

在 16.04 及更新版本中,该snapd包默认安装。因此,它也会默认启动并运行。

如果您没有使用任何 snap 安装的包,那么snapd从系统中删除该包是完全没有问题的。

相关内容