Question: Install Debian using a serial console
Posted by dopehouse on Fri 19 Aug 2005 at 13:55
I've got an old pentium 120 with no graphics card and I want to install Debian via serial console.
I typed 'linux console=ttyS0,9600n8' blindly on the bootprompt. But the only result was, that the kernel loaded and stopped.
I searched the web for a howto but found nothing that helps.
I do not think so.
[ Parent | Reply to this comment ]
http://www.realweasel.com/
--
"It's Not Magic, It's Work"
Adam
[ Parent | Reply to this comment ]
[ Send Message | View dopehouse's Scratchpad ]
[ Parent | Reply to this comment ]
[ Send Message | View Steve's Scratchpad | View Weblogs ]
Reading the Remote Serial Console HOWTO might be useful..
If you can make the machine boot without the screen then that's a good start.
After that how are you trying to connect? Presumably you have a serial cable and minicom connected to it upon another host?
Steve
-- Steve.org.uk
[ Parent | Reply to this comment ]
[ Send Message | View dopehouse's Scratchpad ]
Sorry, but there were no usefull replys for my problem. :)
[ Parent | Reply to this comment ]
[ Send Message | View Steve's Scratchpad | View Weblogs ]
The only time I ever used a serial install was on a Sun Netra, and I used the network booting "business card" ISO image.
If you have access to CD-ROM but not the bandwidth for a full ISO download you might be able to try that.
Steve
-- Steve.org.uk
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
[ Send Message | View dopehouse's Scratchpad ]
I would make it because it is possible to make it!
[ Parent | Reply to this comment ]
http://www.patoche.org/LTT/install/00000103.html
[ Parent | Reply to this comment ]
Sometimes buying hardware for old systems just isn't cost effective or desireable even if it is easier. So, like you, I have used serial to install on these type systems just like you.
Good Luck!
[ Parent | Reply to this comment ]
[ Send Message | View dkg's Scratchpad | View Weblogs ]
I think the thing that will help you the most with this project is to actually get your bootloader to use the serial line itself. the remote serial console HOWTO has a bunch of information about how to make the bootloader itself talk to the serial console.
You say you're using boot floppies, so i'm assuming that yer dealing with syslinux as your boot loader. You'll want to add a line to syslinux.cfg on that floppy. If you can get the bootloader to talk to the serial console, you'll be much further along. There are basically 3 fundamental steps to getting a server to work over a serial console:
- get your bootloader to talk to the serial console.
- get the linux kernel to use the serial line as a console instead of VGA (this is usually something like a console=ttyS0,115200n8 parameter passed to the kernel from the bootloader)
- tell init to launch a login session (getty) on the serial console by modifying /etc/inittab
[ Parent | Reply to this comment ]
[ Send Message | View dopehouse's Scratchpad ]
I already compiled a new kernel for the boot floppy, with serial consol support, but it rans into PANIC ;( . My fault, wrong kernel version.
I'll try it again this weekend. And I think about to build my own boot floppy's with a newly compiled Debain installer and kernel (Need alot of Coffee this weekend).
If anyone got it work with the floppy images from the Debain server and read this before the weekend, PLEASE let me know :).
[ Parent | Reply to this comment ]
[ Send Message | View dkg's Scratchpad | View Weblogs ]
My impression is that the stock debian kernels in sarge (including the ones from the floppies) all have support for serial consoles already. Maybe i should test that first, though...
ok, i did a bit of testing, thanks to qemu!
i downloaded the floppies from here, and modified the contents of boot.img. The only file i changed was /syslinux.cfg, and i made its contents look like this:
serial 0 9600
display syslinux.txt
default linux
F1 f1.txt
F2 f2.txt
F3 f3.txt
F4 f4.txt
F5 f5.txt
F6 f6.txt
F7 f7.txt
F8 f8.txt
F9 f9.txt
F0 f10.txt
label linux
kernel linux
append vga=normal initrd=initrd.gz ramdisk_size=1838 root=/dev/rd/0 dev\
fs=mount,dall rw console=ttyS0,9600n8 --
label expert
kernel linux
append DEBCONF_PRIORITY=low vga=normal initrd=initrd.gz ramdisk_size=18\
38 root=/dev/rd/0 devfs=mount,dall rw console=ttyS0,9600n8 --
prompt 1
timeout 0
I know, 9600 bps isn't terribly speedy, but i don't know qemu or syslinux well enough to know if they'll support different speeds, and 9600 is basically guaranteed to work. After making the change to the file within the bootdisk image, i saved out the newly tweaked diskimage as sboot.img. Then i fired up qemu with the following command:
qemu -fda sboot.img -nographic -serial stdioThis emulates a machine with no graphics card, uses stdin and stdout to emulate the first serial line, and puts sboot.img as the first floppy drive (note that it's my modified sboot.img, not the original boot.img). Everything worked for me. When it prompted me for the root disk, i just did the following (from outside of qemu, of course):
cp sboot.img sboot-sav.img dd if=root.img of=sboot.imgThis saves a copy of sboot.img (should i want it later), and "swaps disks" for qemu. You won't need to do anything that goofy for working with actual floppy disks.
In another experiment, I also tried inserting DEBIAN_FRONTEND=text. i prefer the text frontend over the default newt for serial installs because it is much quicker (fewer bps needed). You can read up a bit about the frontends in the debian-installer manual. But, alas, it looks like the stock floppy disk images don't have that alternate frontend. maybe it was removed for size concerns? i'd certainly be interested in learning how to make a customized serial-console floppy set.
Good luck with this project! And post back here with the results of your labors!
[ Parent | Reply to this comment ]
[ Send Message | View dopehouse's Scratchpad ]
[ Parent | Reply to this comment ]