Installing Ubuntu 20.04 via a serial console
Normally, an operating system is installed with a connected monitor, keyboard and optional mouse. This is not possible on systems without graphics output. In this example, we show how to install Ubuntu via the serial console on a machine without a graphics chip and video output. A network connection to mirror servers to reload program packages is desirable.
Downloading the ISO image
Download the Net Boot environment (in this example here the small mini.iso image of Ubuntu 20.04; approx. 80 MB).
Preparing the boot stick
Now prepare the boot stick for the installation of the Ubuntu LTS 20.04 server environment via serial console.
$ sudo dd if=mini.iso of=/dev/[Gerätebez.usbstick] bs=1M status=progress $ sync
Booting from the USB stick
Now boot from the USB stick and prepare it for an output on the serial console. To do this, you can already connect to the machine up to the installation screen with a TTY tool such as Putty or the tool screen under Linux:
For example: $ sudo screen /dev/ttyUSB0 115200
If the normal installation would be executed now, there would be no further screen output.
It is necessary to adjust the boot options.
Preparing the boot options
Now the boot entry is adapted by means of the key "e" (for edit) temporarily the boot options. Now delete the entry quiet to read the log outputs.
Then enter console=tty0 console=ttyS0,115200n8 and finally boot the system entry with Ctrl -X.
Booting the system - Install script via serial console
After setting the boot options with CTRL-X and starting via the menu item, the installation can now be done completely in serial mode.
Author: Wilfried Seifert Wilfried Seifert, working in the Systems Engineering department at Thomas-Krenn, is responsible for system/prototype development in his work area. LPIC 3 certified, deals with construction / programming of embedded / GPIO systems; in his spare time he likes to repair old home computers, attends Linux conferences or is on the road with his bike (MTB) for sporting compensation.
|