Raspbian error: “The following signatures couldn’t be verified because the public key is not available”

I couldn’t do a ‘sudo apt-get update’ on my Pi 3 running Raspbian as I got this error:

Fetched 74.9 kB in 31s (2,381 B/s)                            Reading package lists... Done
W: GPG error: http://security.debian.org jessie/updates InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 9D6D8F6BC857C906 NO_PUBKEY AA8E81B4331F7F50

To import the missing keys:

sudo apt-key adv –keyserver keyserver.ubuntu.com –recv-key AA8E81B4331F7F50

sudo apt-key adv –keyserver keyserver.ubuntu.com –recv-key 9D6D8F6BC857C906

Tips from here.

Raspbian Jessie apt-get error: “Is the package apt-transport-https installed?”

Trying to do a ‘sudo apt-get update’ on my Raspberry Pi running Jessie I got this error:

$ sudo apt-get update
E: The method driver /usr/lib/apt/methods/https could not be found.
N: Is the package apt-transport-https installed?

Seeing posts online with similar errors about the sources configured in /etc/apt/sources.list, I looked in my file and I had this line:

deb http://mirrordirector.raspbian.org/raspbian/ jessie main contrib non-free rpi

I haven’t used or tried to update this Pi for a while so I can’t remember if this line was how it was originally configured or if I changed it.

Replacing this first line with what I think is more typical:

deb http://raspbian.raspberrypi.org jessie main contrib non-free rpi

and then doing a ‘sudo apt-get update’, it updates sources and now I can upgrade and install other packages again as expected.

systemd quick reference

sudo systemctl start|stop|restart|status servicename

sudo systemctl enable servicename : configures service to start at boot

If changing service config files in /etc/systemd/system/servicename.conf, rerun systemctl daemon-reload after changes and restart changed services