inserting F10 / CTRL+X control character to a minicom terminal

I ran into this interesting issue tonight, where I had malformed entry in my kernel flags which was causing the system to reboot as soon as it loaded the kernel.

So, I needed to edit my GRUB setting at the command line… however, my only physical console on this system is via a 19200 8N1 serial console, running through “minicom”.

After hitting “e” to edit my grub boot item, the following familiar message is displayed towards the end of the screen:

Minimum Emacs-like screen editing is supported. TAB lists
completions. Press Ctrl-x or F10 to boot, Ctrl-c or F2 for
a command-line or ESC to discard edits and return to the GRUB menu.

I was not able to enter the “CTRL+X” or “F10” keystrokes in minicom.

I found a couple articles about this:

Send F10 to GRUB with Minicom
How to send F10 from minicom?

The first looked promising, but didn’t seem to work for me. The answer to the second post didn’t seem to understand the issue at hand.

Anyways, I eventually found this askubuntu article: how do I send control characters to serial device

which eventually pointed me to the idea passing control characters directly to the device.

You’ll want to use the octal representation of your control character.

According to this ASCII Table , the decimal representation of “CTRL+X” is “24”. We must then convert to octal:

$ echo "obase=8; 24" | bc

so now, to solve our issue, we simply run:

$ echo -e '\030' > /dev/ttyUSB0

And boom! GRUB has the “CTRL+X” sequence it was looking for!

Getting Solaris 11.3 x86 to output to serial console

I just set up a new Solaris 11 system for the first time in ages. I was struggling to remember how to configure terminal output through this system’s serial port…

I found this article: Solaris 11 Serial Console

which confidently seems say that the only commands necessary are:

# bootadm set-menu console=serial serial_params=0,19200,8,n,1
# bootadm change-entry -i 0 'kargs=-B console=ttya'

Note: according to Solaris doc Using the set-menu Command, if you’re using ttyb instead of ttya, you’ll want to set "serial_params=1,19200,8,n,1"

However, my serial output seemed to end as soon as GRUB started loading the kernel…

I found that I also needed to set the following

# eeprom console="ttya"
# eeprom ttya-mode="19200,8,n,1,-"

Changing this eeprom setting will create a new default “Solaris bootenv rc” entry in GRUB.

You can see this new entry like such:

# bootadm list-menu

And delete it (assuming the index is “1”) via:

# bootadm remove-entry -i 1

BTW (since this also took me a while to figure out) my USB<-->RS232 setup is a HL-340 chipset USB-A to RS-232 male cable hooked up to the male RS-232 port on this old Supermicro motherboard using a female/female RS-232 “null modem” cable (StarTech part #SCNM9FF2MBK), though a simple null adapter should work as well. During the confusion, I also bought a PL2303 chipset USB-A to RS-232 female cable (CableCreation part #CD0489) which can be plugged in directly (no need for a null modem or adapter). The benefit to the PL2303 chipset is that Solaris 11.3 has driver support for the USB end of it, whereas my HL-340 cable doesn’t seem to work out of the box on Solaris.