VM Junkie

December 16, 2008

Using the Virtual Serial Port to access the Service Console

Filed under: esx, hp, vmware — ermac318 @ 10:44 pm

Like a lot of folks out there, I spend most of my time accessing servers remotely. A lot of this is because of laziness, but it’s also because sometimes you’re dealing with a server in a totally different location.

I have to deal with servers in two different labs, so remote access is critical for me. When all my servers are blades, this is pretty easy, but not all rackmount servers have the same kind of accessibility remotely that blades do. I’ll use HP servers as an example. HP’s c-class blades all have iLo Blade Edition which includes remote graphical console support, but their DL and ML servers don’t have a graphical iLo console unless you upgrade to iLo Advanced.

I had an ESX server (a demo system for when I go to customer sites on sales calls) that I needed to have access to internally, but I couldn’t have it both in our DMZ and our corporate network. To get around this I plugged the iLo into the protected network, since you can’t get back into the iLo from within the OS. This seemed okay to our security guys and they let me go ahead. However, I needed to figure out how to get something useful out of the iLo port, which lead me to some forum posts and I figured out the following solution:

Step 1: Configure the Server BIOS

Enter the Server’s BIOS and under System Options, view the Virtual Serial Port option. Take note of the COM port listed.

If you want to be able to access the BIOS of the server remotely from the serial port, on the main BIOS menu select “BIOS Serial Console & EMS” option, and tell it to use the COM port noted in the previous step.

Step 2: Modify the ESX Server’s inittab

Once ESX server is booted and functional on the system, login as the root account and edit the file /etc/inittab using a text editor such as nano. If the Virtual Serial Port of the system was assigned to COM2, add the following lines to the end of the file:

# Add virtual serial console

7:2345:respawn:/sbin/agetty ttyS1 115200

Note if your COM port is COM1, use ttyS0 instead of ttyS1. Similary, ttyS2 is COM3, etc.

Reboot the ESX server.

You can now access an ESX console from the Virtual Serial Port, either by using the iLo web page’s Java applet, or by using an SSH client to connect to the iLo port, logging in, and typing “VSP” to access the serial port (my preferred method).

NOTE: This serial port connection will not accept a root logon! Much like SSH, root logon is disabled by default on this interface. Use a separate user account and use su to access the root account.

These instructions are for HP servers specifically, but any server brand with a Virtual Serial Port should have a similar solution.

Advertisements

2 Comments

  1. Ok, that’s twice now….

    Great tip.

    ^_____^

    Comment by symbolik — February 10, 2009 @ 8:11 am

  2. To enable root login, just add a line with “ttyS0” to the file /etc/securetty.

    Also, there’s no need to reboot the ESX server, just use “kill -HUP 1” to prod init to re-read its config file. It will start the serial console immediately.

    Thanks for the tip, BTW.

    Iggy

    Comment by Iggy — February 2, 2010 @ 3:47 pm


RSS feed for comments on this post.

Sorry, the comment form is closed at this time.

Create a free website or blog at WordPress.com.

%d bloggers like this: