]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/commitdiff
inittab: change tty1 to console
authorArne Fitzenreiter <arne_f@ipfire.org>
Sat, 24 Mar 2018 12:26:32 +0000 (13:26 +0100)
committerArne Fitzenreiter <arne_f@ipfire.org>
Sat, 24 Mar 2018 12:26:32 +0000 (13:26 +0100)
this reduce the differences between tty and scon installations
and make it easier to switch between.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
config/etc/inittab
config/etc/securetty
lfs/flash-images
src/installer/main.c

index 506fa237d4f8fb99d3c6c74b2e56569f7a1a888a..acc1a7b35d90686bfef1b9df9d8cb3eb69c31a14 100644 (file)
@@ -19,13 +19,11 @@ ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
 
 su:S016:once:/sbin/sulogin
 
-1:2345:respawn:/sbin/agetty tty1 9600 --noclear
-2:2345:respawn:/sbin/agetty tty2 9600
-3:2345:respawn:/sbin/agetty tty3 9600
-4:2345:respawn:/sbin/agetty tty4 9600
-5:2345:respawn:/sbin/agetty tty5 9600
-6:2345:respawn:/sbin/agetty tty6 9600
-# *** Uncomment for serial console
-#7:2345:respawn:/sbin/agetty ttyS0
+1:2345:respawn:/sbin/agetty console --noclear
+2:2345:respawn:/sbin/agetty tty2
+3:2345:respawn:/sbin/agetty tty3
+4:2345:respawn:/sbin/agetty tty4
+5:2345:respawn:/sbin/agetty tty5
+6:2345:respawn:/sbin/agetty tty6
 
 # End /etc/inittab
index 3a69d0b6e7ef983495c7eeb68e00a9dab50e49b8..995a1a19403bbacafd5cb84bc52d08257894534b 100644 (file)
@@ -1,15 +1,9 @@
-tty1
+console
 tty2
 tty3
 tty4
 tty5
 tty6
-ttyAMA0
-ttyO2
-ttyS0
-ttyS1
-ttyS2
-ttyS4
 ttyp0
 ttyp1
 ttyp2
index 996109ce44ae4822df5d39a3df3365b2d834fe7a..09ad7a0130f7786c1506f306d62659dbd86bc927 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2017  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2018  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -146,14 +146,12 @@ endif
        echo "THEME=ipfire" >> $(MNThdd)/var/ipfire/main/settings
 
 ifeq "$(SCON)" "1"
-       # Enable serial console
-       sed -i -e "s|1:2345:respawn:|#1:2345:respawn:|g" $(MNThdd)/etc/inittab
+       # Disable console on tty2-6
        sed -i -e "s|2:2345:respawn:|#2:2345:respawn:|g" $(MNThdd)/etc/inittab
        sed -i -e "s|3:2345:respawn:|#3:2345:respawn:|g" $(MNThdd)/etc/inittab
        sed -i -e "s|4:2345:respawn:|#4:2345:respawn:|g" $(MNThdd)/etc/inittab
        sed -i -e "s|5:2345:respawn:|#5:2345:respawn:|g" $(MNThdd)/etc/inittab
        sed -i -e "s|6:2345:respawn:|#6:2345:respawn:|g" $(MNThdd)/etc/inittab
-       sed -i -e "s|#7:2345:respawn:|7:2345:respawn:|g" $(MNThdd)/etc/inittab
 
 ifeq "$(BUILD_PLATFORM)" "arm"
        sed -i -e "s| console=tty1 | console=ttyAMA0,115200n8 |g" $(MNThdd)/boot/cmdline.txt
index a3642551d69ec4fa7609dba3cb57b799e4206b71..c7075aa71da60719ba260982e2b8d8d746faf58c 100644 (file)
@@ -820,15 +820,6 @@ int main(int argc, char *argv[]) {
                fclose(f);
 
                replace(DESTINATION_MOUNT_PATH "/etc/default/grub", "panic=10", "panic=10 console=ttyS0,115200n8");
-
-               /* inittab */
-               replace("/harddisk/etc/inittab", "1:2345:respawn:", "#1:2345:respawn:");
-               replace("/harddisk/etc/inittab", "2:2345:respawn:", "#2:2345:respawn:");
-               replace("/harddisk/etc/inittab", "3:2345:respawn:", "#3:2345:respawn:");
-               replace("/harddisk/etc/inittab", "4:2345:respawn:", "#4:2345:respawn:");
-               replace("/harddisk/etc/inittab", "5:2345:respawn:", "#5:2345:respawn:");
-               replace("/harddisk/etc/inittab", "6:2345:respawn:", "#6:2345:respawn:");
-               replace("/harddisk/etc/inittab", "#7:2345:respawn:", "7:2345:respawn:");
        }
 
        /* novga */