Installing ubuntu without graphics terminal(gfxterm)

I am trying to install ubuntu 18.04 on a Headless server machine. The server is blade which sits inside a chasis. I connect to this server via the serial port.

  • The server does not have any VGA capabilities. So the ubuntu live server 18.04 iso is ruled out.

  • When I try with the ubuntu server 16.04 server iso, it gives the error as could not load the gfxterm. Please note that this iso does not have any live server capabilities.

  • Then i tried to see if the mini.iso(ubuntu minimal) can be used for the same. But when i check the boot/grub/grub.cfg file, this too is trying to insmod gfxterm, and the terminal_output = gfxterm.
  • I have checked the support forums and found no support specific to this issue.

Can you please help me in installing without any graphical interface whatsoever?

Thank you.

1 Answer

You'll have to modify the boot disk to redirect output to the serial port appropriately.

  1. Download an ubuntu server amd64 iso file
  2. Create a USB boot disk using unetbootin
  3. Modify the following files. If you still use legacy bios boot mode, modify isolinux/isolinux.cfg, isolinux/txt.cfg, syslinux.cfg. If you use UEFI boot mode, modify boot/grub/grub.cfg only.

isolinux/isolinux.cfg

# D-I config version 2.0
include menu.cfg
default menu.c32
prompt 0
timeout 0

isolinux/txt.cfg

default install
label install menu label ^Install Ubuntu Server kernel /install/vmlinuz append vga=normal initrd=/install/initrd.gz -- console=tty0 console=ttyS0,115200n8 nosplash debug -

syslinux.cfg

CONSOLE 0
SERIAL 0 115200 0
default menu.c32
prompt 0
menu title UNetbootin
timeout 100
label unetbootindefault
kernel /ubnkern
append vga=normal initrd=/ubninit nomodeset askmethod console=tty0 console=ttyS0,115200n8

boot/grub/grub.cfg

menuentry "Install Ubuntu Server" { set gfxpayload=keep linux /install/vmlinuz file=/cdrom/preseed/ubuntu-server.seed vga=normal console=tty0 console=ttyS0,115200n8 --- initrd /install/initrd.gz }

Install ubuntu as usual by connecting to the serial port. On first boot, enter editing mode of grub boot option with key e, when you see grub boot menu on serial console.

Add console options after ro in linux boot options

linux ..... ro console=tty0 console=ttyS0,115200n8

and then press Ctrl+X to boot.

Post install, edit the grub configuration (/etc/default/grub) as follows

GRUB_CMDLINE_LINUX_DEFAULT=""
GRUB_TERMINAL='serial console'
GRUB_CMDLINE_LINUX="console=tty0 console=ttyS0,115200n8"
GRUB_SERIAL_COMMAND="serial --speed=115200 --unit=0 --word=8 --parity=no --stop=1"

following which you must run update-grub to update the menu entries.

Source: Ubuntu Serial Install

1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like