UTM use serial remote
UTM
virtual machine host has a built-in display, but its terminal is rather limited and currently doesn’t allow scroll back.
It’s convenient to use the serial device with a terminal program like screen from the host OS.
To configure the serial device, power off the VM.
Add a Serial Device under the UTM VM settings.
Before starting the VM, note on the VM settings main page (starts with “Status Stopped”) the name of the “Serial (TTY)” device like /dev/ttys005 or similar.

The GNU screen program can be used from the host OS to connect efficiently to the guest OS.
brew install screenFrom the host OS Terminal, connect like
screen /dev/ttys005The serial device with screen enables scroll back through the terminal.
On the host OS, edit the file “~/.screenrc” to include the following lines:
defscrollback 10000
termcapinfo xterm* ti@:te@
defscrollback 10000- Sets the default scrollback buffer to 10000 lines in
screen. termcapinfo xterm* ti@:te@- allow scrollback to work as expected.