I am running Ubuntu Server 20.04 headlessly, and typically remote into it via SSH. However, it is also connected via serial RS232 to a terminal server (a Digi CM 16) for kernel console logging and as a backup management method.
Here's the thing: I use ZSH with some ultra-fancy add-ons. Works great over SSH. Serial, not so much. The logfiles from the terminal server are usually not very coherent due to all the control characters ZSH is throwing around.
How do I force the serial console login to use BASH, even though my user's default shell is ZSH?
Here's what I want:
Method of logging in | Shell I want to be presented with |
---|---|
SSH | ZSH (user default) |
Serial Console login | BASH |
Plug in monitor and keyboard and physically login | don't care |
I've tried looking at changing the getty
settings for ttyS0
, and it appears that the only option is to change the default login executable from /bin/login
, but I don't think I want to do that? Still want to login with a password, just want to change the shell spawned after logging in just if logging in from ttyS0