To stop having a service automatically start after bootup in a Linux system with systemctl use the following to stop and then disable the service:
1 2 |
sudo systemctl stop service_name sudo systemctl disable service_name |
Trying to start the docker service after some upgrades fails with the following message:
1 |
Failed to start docker.service: Unit is masked. |
It turns out that after upgrading or more specifically removing and then upgrading the docker installation in ubuntu (in this particular case in raspberry 4 with Ubuntu 20.04 installed), results in this error.
A search brings up the following:
https://forums.docker.com/t/failed-to-start-docker-service-unit-is-masked/67413
and from that the following bug post:
https://bugs.launchpad.net/ubuntu/+source/docker.io/+bug/1844894
So the solution is to run the following to be able to start the docker service (described in the first link above):
1 2 |
sudo systemctl unmask docker sudo systemctl start docker |
To be able to get a more detailed information about your current linux distribution, including the code names use the following:
1 2 3 4 5 6 7 8 9 10 11 12 13 |
kosmas:$ cat /etc/os-release NAME="Ubuntu" VERSION="18.04.5 LTS (Bionic Beaver)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 18.04.5 LTS" VERSION_ID="18.04" HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" VERSION_CODENAME=bionic UBUNTU_CODENAME=bionic |
Trying to configure and use an nginx server that uses intermediate certifcates, you get the error about values mismatch and nginx does not start
1 |
2020/09/23 09:49:38 [emerg] 20958#20958: SSL_CTX_use_PrivateKey("/etc/ssl/private/cakey.pem") failed (SSL: error:0B080074:x509 certificate routines:X509_check_private_key:key values mismatch) |
It seems that this is a common mistake and it is mentioned here: https://nginx.org/en/docs/http/configuring_https_servers.html. In order to fix this you will need to change/reverse the original order that you have concatenated the chain, as in:
1 |
cat certs/cacert.pem intermediate/certs/intermediate.cacert.pem > intermediate/certs/ca-chain-bundle.cert_new.pem |
Problem
You want to use the pgp encryption when using Terraform to create an AWS IAM user, and you have the secret access token returned as an output but encoded.
Solution
Use the following to get the actual secret key decoded (after copying your encoded key to a file encrypted_key.txt:
1 |
$ cat encrypted_key.txt | base64 --decode | gpg -d |
To install megtools (command line utilities for Mega.nz), in your raspberry with ubuntu installed follow the steps below (thanks to the instructions from here: https://www.instructables.com/id/Descarga-archivos-de-Mega-con-Raspberry-Pi/)
1 |
sudo apt-get -y install build-essential libglib2.0-dev libssl-dev libcurl4-openssl-dev libgirepository1.0-dev |
You may also need to add some additional packages if there is an error about the documentation.
1 |
wget https://megatools.megous.com/builds/megatools-1.10.3.tar.gz |
1 2 3 4 5 6 |
tar xvfz megatools-1.10.3.tar.gz cd megatools-1.10.3 ./configure make sudo make install sudo ldconfig |
1 2 3 |
[Login] Username = my_mega@email Password = mypassword |
After installing an image of the Ubuntu server on the Raspberry 4, the wifi is not automatically configured after the initial book.
In order to be able to use the WiFi follow the steps described below for setting up your wifi in your SD card, and then reboot your raspberry (make sure that the indentation in the yaml file is correct, and also your WiFi access point is enclosed in quotes):
https://ubuntu.com/tutorials/how-to-install-ubuntu-on-your-raspberry-pi#3-wifi-or-ethernet