Some fixes for serial-console.

This commit is contained in:
Arne Fitzenreiter
2010-12-03 19:58:41 +01:00
parent 104a00cb8a
commit 06f626f9f5
2 changed files with 10 additions and 2 deletions

View File

@@ -523,7 +523,7 @@ int main(int argc, char *argv[])
replace("/harddisk/boot/grub/grub.conf", "splashimage", "#splashimage");
replace("/harddisk/boot/grub/grub.conf", "#serial", "serial");
replace("/harddisk/boot/grub/grub.conf", "#terminal", "terminal");
replace("/harddisk/boot/grub/grub.conf", " panic=10 ", " console=ttyS0,38400 panic=10 ");
replace("/harddisk/boot/grub/grub.conf", " panic=10 ", " console=ttyS0,38400n8 panic=10 ");
/*inittab*/
replace("/harddisk/etc/inittab", "1:2345:respawn:", "#1:2345:respawn:");

View File

@@ -43,6 +43,14 @@ ENTRY=`grep "savedefault" /boot/grub/grub.conf | tail -n 1`
# Nur den letzten Parameter verwenden
echo $ENTRY > /dev/null
let ENTRY=$_+1
#Check if the system use serial console...
if [ "$(grep "^serial" /boot/grub/grub.conf)" == "" ]; then
console=""
else
console=" console=ttyS0,38400n8"
fi
#
# backup grub.conf
#
@@ -52,7 +60,7 @@ cp /boot/grub/grub.conf /boot/grub/grub-backup-$KVER-pae.conf
#
echo "" >> /boot/grub/grub.conf
echo "title IPFire (PAE-Kernel)" >> /boot/grub/grub.conf
echo " kernel /vmlinuz-$KVER-ipfire-pae root=$ROOT panic=10 $MOUNT" >> /boot/grub/grub.conf
echo " kernel /vmlinuz-$KVER-ipfire-pae root=$ROOT panic=10$console $MOUNT" >> /boot/grub/grub.conf
echo " initrd /ipfirerd-$KVER-pae.img" >> /boot/grub/grub.conf
echo " savedefault $ENTRY" >> /boot/grub/grub.conf
#