![]() | Sun System Handbook - ISO 4.1 October 2012 Internal/Partner Edition | ||
|
|
![]() |
||||||||||||
Solution Type Technical Instruction Sure Solution 1010463.1 : Sun Fire[TM] v60x/v65x/v20z/v40z: Linux OS Console Redirection Setup
PreviouslyPublishedAs 214374 Description Redirecting the Operating System (OS) console to the serial port allows remote system administrators to view boot-time console output in real time. Console output from booting your machine can be particularly helpful when troubleshooting the exact reason for a server's failure to boot. Note: If a log of the bootup process is needed, you can run the command dmesg after bootup. This will display logged console output, but has a size limit. When the limit has been reached, earlier messages are discarded. Steps to Follow Red Hat 7.2 onwards and other Linux OS give grub (Grand Unified Boot Loader) as default boot loader. Follow the steps below to setup serial console. To configure GRUB, modify/add the following lines in the file /etc/grub.conf: #splashimage=(hd0,0)/grub/splash.xpm.gz Avoid any splash image, so the above line is commented out. serial --unit=1 --speed=9600 This will only define serial port definition. Defined above is the serial port as (COM1). For COM1, specify --unit=0, however, this is not present on the v60x/v65x. terminal --timeout=10 console serial Here we are defining 10 seconds timeout and both console (Monitor or tty0) and serial port (ttyS0 or COM1) as display. For 10 seconds it will allow either monitor or serial port selection, depending upon where you press the key. Otherwise, after the time has elapsed, it will select the first entry ('console'). In the above example, 'console' is the primary display device and it shows the grub menu of OS selection(s) there. If console redirection is not enabled in the BIOS, the line can read: terminal --timeout=10 serial console For more information on configuring console redirection in the BIOS, see: http://download.oracle.com/docs/cd/E19121-01/sf.v20z/817-5249-17/chapter4.html#pgfId-1011631 Next, additional parameters need to be passed to the kernel: kernel /<kernelrevision> ro root=LABEL=/ console=ttyS1,9600n8 console=tty0 where <kernelrevision> is simply the kernel version that you are using. This line throws kernel messages to selected devices. (Note, on the v20z/v40z, instead of 'ttyS1', it should read 'ttyS0'.) Note: 9600 is just an example. You can choose your own baud rate. Single User Mode Login: Although you can select both monitor and serial port to get the kernel message, only the last selected 'console=xxxx' in kernel line will be available for OS messages and keyboard entry in single user mode. It may be advantageous to create two instances of this kernel statement, so that single user mode login can take place at either selected console. To allow the init processes to be forwarded to/on the serial device, then simply change the order to the following line: kernel /<kernelrevision> ro root=LABEL=/ console=tty0 console=ttyS1,9600n8 Daemon process startup status will now be printed to your serial device. (Again, on the v20z/v40z, it should be 'ttyS0' instead of 'ttyS1'.) To configure LILO: 1. Enter the following line in the file /etc/lilo.conf: append="console=ttyS1,9600 console=tty0" 2. After making changes to the file /etc/lilo.conf, run the command lilo, as root, to implement the changes. Note: It is not mandatory to redirect BIOS output to the serial console to get the OS console output working. If you do redirect BIOS output, just make sure to set the values of Baud Rate and Flow Control to match those specified in GRUB, or LILO. Also, set the Terminal Type to VT100+. Now that you have forwarded init status through the console, it may also be fitting to allow a login from your console device. For information on how to setup serial login, see <Document: 1017815.1> "Sun Fire[TM]: Setting Up Serial Login" Product Sun Fire V65x Server Sun Fire V60x Server Sun Fire V40z Server Sun Fire V20z Server Previously Published As 71430 Attachments This solution has no attachment |
||||||||||||
|