mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-09 18:45:54 +02:00
inittab: change tty1 to console
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>
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -1,15 +1,9 @@
|
||||
tty1
|
||||
console
|
||||
tty2
|
||||
tty3
|
||||
tty4
|
||||
tty5
|
||||
tty6
|
||||
ttyAMA0
|
||||
ttyO2
|
||||
ttyS0
|
||||
ttyS1
|
||||
ttyS2
|
||||
ttyS4
|
||||
ttyp0
|
||||
ttyp1
|
||||
ttyp2
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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 */
|
||||
|
||||
Reference in New Issue
Block a user