If after installing the SNAPD on Ubuntu, Kali, or other Linux you will get an error:
solve error: cannot communicate with server: Post "http://localhost/v2/snaps/": dial unix /run/snapd.socket: connect: no such file or directory
Then this is because, after installation, the Daemon of SNAP is have not started yet and needs to start and enable manually by the user.
Therefore to resolve such an issue perform the below steps after installing snapd.
First, check the status of SNAPD service
systemctl status snapd.service
If you get the following output then the service is not yet started.
● snapd.service - Snap Daemon
Loaded: loaded (/lib/systemd/system/snapd.service; disabled; vendor p>
Active: inactive (dead)
TriggeredBy: ● snapd.socket
Start SNAPD service
systemctl start snapd
systemctl status snapd
Output ● snapd.service - Snap Daemon Loaded: loaded (/lib/systemd/system/snapd.service; disabled; vendor p> Active: active (running) since Thu 2020-11-26 06:33:26 EST; 1s ago TriggeredBy: ● snapd.socket Main PID: 2338 (snapd) Tasks: 8 (limit: 4623) Memory: 22.8M CGroup: /system.slice/snapd.service └─2338 /usr/lib/snapd/snapd
In case still the error hasn’t solved yet, then run the below command. However, it will remove any existing installed application via snap.
sudo apt purge snapd sudo apt install snapd
Fantastic! Thank you!
Bruh, Im so new To linux
Genial, funciona de conya, gràcies! \ Yeah, work fine, thanks!
System has not been booted with systemd as init system (PID 1). Can’t operate.
Failed to connect to bus: Host is down
Snap will not work on WSL running Ubuntu or in some container
I am using manjaro plasma and the output i got after completing the process,
systemctl status snapd ✔ 4s
○ snapd.service – Snap Daemon
Loaded: loaded (/usr/lib/systemd/system/snapd.service; disabled; vendor preset: disabled)
Active: inactive (dead) since Tue 2022-03-01 13:51:07 IST; 19s ago
TriggeredBy: ● snapd.socket
Process: 1802 ExecStart=/usr/lib/snapd/snapd (code=exited, status=42)
Main PID: 1802 (code=exited, status=42)
CPU: 520ms
Mar 01 13:51:00 Veldora systemd[1]: Starting Snap Daemon…
Mar 01 13:51:01 Veldora snapd[1802]: AppArmor status: apparmor not enabled
Mar 01 13:51:01 Veldora snapd[1802]: daemon.go:246: started snapd/2.54.3-1-dirty (series 16; classic; devmode) manj>
Mar 01 13:51:01 Veldora snapd[1802]: daemon.go:339: adjusting startup timeout by 30s (pessimistic estimate of 30s p>
Mar 01 13:51:01 Veldora snapd[1802]: helpers.go:137: error trying to compare the snap system key: system-key missin>
Mar 01 13:51:02 Veldora systemd[1]: Started Snap Daemon.
Mar 01 13:51:07 Veldora snapd[1802]: daemon.go:509: gracefully waiting for running hooks
Mar 01 13:51:07 Veldora snapd[1802]: daemon.go:511: done waiting for running hooks
Mar 01 13:51:07 Veldora snapd[1802]: daemon stop requested to wait for socket activation
Mar 01 13:51:07 Veldora systemd[1]: snapd.service: Deactivated successfully.
now it is working fine .
Thank You