Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Serial console question
2013-10-24, 14:19
Post: #1
Serial console question
Hi I am having a problem with console redirection to a serial port working when I use iPXE. I was wondering if anyone has been able to get this working.

I do not mean enabling CONSOLE_SERIAL on the ../config/console.h file to pass iPXE information to the serial line. This works fine. What I mean is passing something like:
[bold]console=ttyS1,115200[/bold]
in imgars.

Above command redirects all console output to ttyS1 allowing this output to be captured for later analysis.

I have been able to do this on a standard PXE installation by setting my config file as follows:

Code:
DEFAULT latest

LABEL latest
kernel /vmlinuz-2.6.18-308.4.1.el5_lustre.1.8.8_2.0.1
append console=ttyS1,115200 ip=dhcp root=/dev/nfs ro init=/usr/local/bin/ts_di\
skless_init

however when I attempt to do something similar with iPXE, I fail to send the output to the serial line.

Code:
:
kernel ${base-url}/${def_boot}/vmlinuz
initrd ${base-url}/${def_boot}/initrd
imgargs ${kernel} console=ttyS1,115200 ip=dhcp root=dev/nfs ro nfsroot=${tera_nfs} init=/usr/local/bin/ts_diskless_init
boot || echo Booting Failed

Any help you can lend in sheding light on this tiny mistery is greatly appreciated.

Luis
Find all posts by this user
Quote this message in a reply
2013-10-27, 10:16
Post: #2
RE: Serial console question
So what is happening that isn't working the way you expect? Is it the Linux kernel not outputting data to the serial port the issue you're having. Please try to describe what you're expecting to happen, and what actually happens. Also, your kernel param should probably be root=/dev/nfs, not root=dev/nfs.
Visit this user's website Find all posts by this user
Quote this message in a reply
2013-10-28, 18:29 (This post was last modified: 2013-10-28 18:37 by Lec.)
Post: #3
RE: Serial console question
Actually while I was awaiting forum vetting, I determined that the problem appears to be that the command line is not being passed through.
I was able to use the new virtualbox feature to record the console, and from there saw this:

"Command line:"
On a standard PXE server, I see:

"Command line: console=ttyS1,115200 ip=dhcp root=/dev/nfs ro init=/usr/local/bin/ts_diskless_init BOOT_IMAGE=/vmlinuz-2.6.18-308.4.1.el5_lustre.1.8.8_2.0.1 "

This allows me to direct the output of the console to the serial line to debug. I was attempting to debug why my boot command was not working and that is why I was trying to direct the output. As it turns out, the cause for my problem as well as for the lack of redirection is the same. I am not processing the command line.
Find all posts by this user
Quote this message in a reply
2013-10-29, 12:08
Post: #4
RE: Serial console question
So as a follow up to my own question, now that I know that the command line is not being passed to the kernel, can anyone tell me how to do it?

Here is the script I used in my original attempt. I was under the (apparently wrong) impression that "imgargs" would be given to the kernel on load.

Code:
#!ipxe

# 320 Pxe boot file for remote iPXE booting


echo Starting boot of Terascala's patched rts_188_3.0.24_12.iso
set def_boot iPXE/188
set tera_server 10.200.3.22
set tera_nfs ${tera_server}:/var/www/iPXE/image
set base-url http://${tera_server}
set boot-url ${base-url}/iPXE/image

kernel ${base-url}/${def_boot}/vmlinuz
initrd ${base-url}/${def_boot}/initrd
imgargs ${kernel} console=ttyS1,115200 ip=dhcp root=dev/nfs ro nfsroot=${tera_nfs} init=/usr/local/bin/ts_diskless_init
boot || echo Booting Failed
Find all posts by this user
Quote this message in a reply
2013-11-03, 23:06
Post: #5
RE: Serial console question
I don't see the value of ${kernel} being set anywhere. It should probably be "vmlinuz". You can verify what you're going to boot with the command "imgstat" right before you do "boot". That should tell you what kernel is being booted with which command line.
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)