posted by Tony Bourke on Tue 9th Mar 2004 18:48 UTC
"Ultra5 Primer, Page 2/2"
Terminal Software

If you're using a Windows machine, the HyperTerminal application (often found in Programs, Accessories, Communication) can connect your serial port (COM1, COM2, etc) to a Sun system. Be sure to use 9600, 8-N-1, and select "none" for flow control.

If you're using a Unix-like system, you can use cu, tip, Minicom, or my favorite, Kermit. (Here's an interesting bit of geek history and name-dropping: By a chance meeting, I met the young woman for whom the name for Kermit was derived.).

Keyboard/Screen or Serial Console

In the OpenBoot firmware you can specify whether the system will use the keyboard/screen or the serial console to output it's boot-up sequence. There are two ways you can set these variables: Through OpenBoot itself, or through a system utility. (Again, if you use OpenBoot, the system should either be halted, or stopped during the system startup, rather than while an operating system is still running.)

The two commands to switch to keyboard/screen are:

ok> setenv input-device keyboard
ok> setenv output-device screen
And the two commands for setting the serial console as the input/out are:
ok> setenv input-device ttya
ok> setenv output-device ttya
Additionally, many (if not all) of the operating systems reviewed (including Solaris and NetBSD) include a utility called eeprom, which allows you to set the OBP settings without going to the ok> prompt.
netbsd1# eeprom "input-device=ttya"
netbsd1# eeprom "output-device=ttya"
To see the current settings, type printenv at the ok> prompt, or just run eeprom in your operating system.

Any change in settings will not take effect until the system is rebooted/reset.

The system uses either the keyboard/screen or serial port for input/output, not both. If the system is setup to use the serial port, the screen will be blank, unless the X server kicks in, at which point the keyboard and screen will work.

If the input-device is set for keyboard and no keyboard is plugged in, the system will use the serial console for interaction.

As far as I can tell, if your system is set to use the serial console, there's no way to switch it to keyboard/screen unless you plug in a serial console and change it with the ok> prompt or eeprom. The Sun documents I've searched don't seem to say anything about that particular scenario. If you know of a trick, shoot me an email.

Serial Cable Madness

It's a good idea to have a serial cable when dealing with Sun equipment, and indeed other Unix systems and network devices. But the myriad of connectors, genders, and wirings makes it difficult (and expensive) to always have the right cable.

Over years of data center work, I've found an easy way handle the myriad of possible connectors for serial cables. By using unassembled modular adapters and Cat 5 cable, I can cheaply and effectively make sure I'm covered no matter what serial need I come up against.

The trick is using the unassembled modular adapters and a wiring guide allowing the easy creation of custom cables. They only take a few minutes to assemble, and they very inexpensive when compared to stocking multiple serial cables. The cable length is determined only by the what Cat 5 you have available. I'm not sure of the limitations in length of the cable, but I've used 50 foot cables before without any problem.

I published an article a few years ago on this method, entitled Serial Madness. You can find the wiring guides here.

Conclusion

This was just a quick introduction to dealing with the OpenBoot firmware as well as some specifics regarding serial connections. There are plenty of resources for Sun systems, serial connections, and OpenBoot on the Internet.

Table of contents
  1. "Ultra5 Primer, Page 1/2"
  2. "Ultra5 Primer, Page 2/2"
e p (0)    16 Comment(s)

Related Articles

posted by Thom Holwerda on Fri 27th Jun 2008 15:13
posted by Robert Escue on Wed 4th Jun 2008 05:06
posted by Thom Holwerda on Sat 3rd May 2008 20:44, submitted by Moochman