Software & AppsOperating SystemLinux

How To Login to Ubuntu Core

Ubuntu 20

Ubuntu Core, a minimal version of Ubuntu, is designed for IoT devices and large container deployments. Unlike other versions of Ubuntu, Core does not come with a default username and password. Instead, it uses SSH keys for authentication, which are linked to your Ubuntu SSO (Single Sign-On) account. This article will guide you through the process of logging into Ubuntu Core.

Quick Answer

To login to Ubuntu Core, you need to create an Ubuntu SSO account, generate SSH keys, add the public key to your Ubuntu SSO account, and then use an SSH client to log into your Ubuntu Core device using the private key and your Ubuntu SSO username and the device’s IP address.

Creating an Ubuntu SSO Account

To get started, you’ll need an Ubuntu SSO account. If you don’t have one, you can create one on the Ubuntu SSO website. This account will be used to manage your SSH keys and access your Ubuntu Core devices.

Generating SSH Keys

SSH keys are a pair of cryptographic keys that provide a secure way of logging into your device without needing a password. The pair consists of a private key, which is kept secret, and a public key, which is shared with the Ubuntu SSO.

To generate a new SSH key pair, open your terminal and enter the following command:

ssh-keygen -t rsa -C example -b 2048

In this command:

  • -t rsa specifies the type of key to create. In this case, we’re creating an RSA key.
  • -C example adds a comment to the key. This is typically used to identify the key. You can replace example with any comment you like.
  • -b 2048 specifies the number of bits in the key. A higher number is more secure, but also slower. 2048 is a good balance between security and speed.

This command will create a new SSH key pair in the default location, which is usually ~/.ssh/id_rsa for the private key and ~/.ssh/ for the public key.

Adding the SSH Key to Ubuntu SSO

Once you’ve generated your SSH key pair, you need to add the public key to your Ubuntu SSO account. To do this, open the .pub file with a text editor, copy its contents, and then paste it into the SSH Keys section of your Ubuntu SSO account.

Logging into Ubuntu Core

With your SSH keys set up, you can now log into your Ubuntu Core device. To do this, you’ll need an SSH client. Most Unix-like systems, including Linux and macOS, come with an SSH client preinstalled. For Windows, you can use a program like PuTTY.

The command to log into your Ubuntu Core device is:

ssh -i id_rsa username@xx.xx.xx.xx

In this command:

  • -i id_rsa specifies the private key to use for authentication. Replace id_rsa with the path to your private key file if you didn’t use the default location.
  • username@xx.xx.xx.xx is the username and IP address of your Ubuntu Core device. Replace username with your Ubuntu SSO username, and xx.xx.xx.xx with the IP address of your Ubuntu Core device.

If everything is set up correctly, you should be logged into your Ubuntu Core device without being prompted for a password.


Logging into Ubuntu Core might seem a bit complicated due to the use of SSH keys, but it’s a much more secure method than using passwords. Once you’ve set up your SSH keys and Ubuntu SSO account, logging in is as simple as running a single command. If you encounter any issues, the Ubuntu documentation is a great resource.

Can I use any SSH client to log into Ubuntu Core?

Yes, you can use any SSH client to log into Ubuntu Core. Most Unix-like systems come with an SSH client preinstalled, and for Windows, you can use programs like PuTTY.

Can I use the same SSH key pair for multiple Ubuntu Core devices?

Yes, you can use the same SSH key pair for multiple Ubuntu Core devices. Simply add the public key to each device’s Ubuntu SSO account.

Can I change my SSH key pair after it has been added to Ubuntu SSO?

Yes, you can change your SSH key pair after it has been added to Ubuntu SSO. Simply generate a new key pair and replace the old public key with the new one in your Ubuntu SSO account.

What should I do if I forget my Ubuntu SSO account password?

If you forget your Ubuntu SSO account password, you can reset it by visiting the Ubuntu SSO website and following the password reset instructions.

Can I log into Ubuntu Core with a password instead of SSH keys?

No, Ubuntu Core does not support logging in with a password. SSH keys are the only authentication method available for Ubuntu Core devices.

Can I access and manage my Ubuntu Core devices remotely?

Yes, you can access and manage your Ubuntu Core devices remotely using SSH. As long as you have the SSH key pair and the IP address of the device, you can log in from anywhere with an internet connection.

How can I secure my SSH keys?

To secure your SSH keys, make sure to keep your private key secret and avoid sharing it with anyone. Store it in a secure location and consider using a passphrase to encrypt it for added security.

Leave a Comment

Your email address will not be published. Required fields are marked *