No (publicly known) password for the default user
There is no (publicly known) password for the default user in Ubuntu based flavours and distros. When asked for a password, for example to run sudo, you simply press the Enter key. But ssh wants a password, so it does not work to log in remotely via ssh into a persistent live drive.
Create a second user with a password
I found a way to connect to a persistent live Ubuntu based distro via ssh. I tested with a recent iso file of Lubuntu Eoan (to be released as 19.10), but I think the method is general and should work for many versions, flavours and re-spins based on Ubuntu including Linux Mint.
- Create a persistent live drive with mkusb from your iso file.
- Boot into your persistent live system
Install tools
sudo apt update
Get packages (unless you have them already)
sudo apt install gnome-system-tools
in order to get users-admin and of course
sudo apt install openssh-server
The default live user needs no password to run sudo, just press the Enter key, when it asks for password.
Create a second user
users-admin
and follow the instructions in the graphical user interface. Select a good password with at least 8 characters.
Now you have an ssh server and a user with a password, and you can log in remotely to your persistent live system :-)
Connect to your network and identify your IP address
ip a
I found the following address: 192.168.1.10
Demo input and output
sudodus@m4800:~$ ssh [email protected]
[email protected]'s password:
Welcome to Ubuntu Eoan Ermine (development branch) (GNU/Linux 5.2.0-15-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
Last login: Thu Sep 19 07:39:18 2019 from 192.168.1.2
tester@lubuntu:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu Eoan Ermine (development branch)
Release: 19.10
Codename: eoan
tester@lubuntu:~$ su - lubuntu
Password:
lubuntu@lubuntu:~$ sudo df -h
Filesystem Size Used Avail Use% Mounted on
udev 1.9G 0 1.9G 0% /dev
tmpfs 383M 1.4M 382M 1% /run
/dev/sdb4 1.7G 1.7G 0 100% /cdrom
/dev/loop0 1.6G 1.6G 0 100% /rofs
/cow 9.6G 362M 8.7G 4% /
tmpfs 1.9G 7.4M 1.9G 1% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
tmpfs 1.9G 0 1.9G 0% /tmp
tmpfs 383M 8.0K 383M 1% /run/user/999
/dev/sdb5 9.6G 362M 8.7G 4% /media/lubuntu/casper-rw
/dev/sdb1 3.3G 18M 3.3G 1% /media/lubuntu/usbdata
tmpfs 383M 4.0K 383M 1% /run/user/1000
lubuntu@lubuntu:~$
You can see that the root file system / has the same properties as the casper-rw partition. It indicates that it is a persistent live system. You can also see that it is possible to switch user to the default user (here 'lubuntu').