The OpenNET Project / Index page

[ новости /+++ | форум | теги | ]

Поиск:  Каталог документации

8.2. Re-create saved console settings

Log in as root from the serial console and send the console into single user mode. The modem may hang up whilst doing this and you may need to re-connect.

Without a /etc/ containing the saved terminal settings, init assumes a directly attached terminal running at 9600bps with 8 data bits, no parity, 1 stop bit and no flow control. Configure your terminal with these settings. ttyS0 login: root
sh# rm -f /etc/
bash# telinit 1Telling INIT to go to single user mode.
INIT: Going single user
INIT: Sending processes the TERM signal
sh# stty sane -parenb cs8 crtscts brkint -istrip -ixoff -ixon

As you use stty to alter the Linux's terminal settings remember to also alter the settings of the attached terminal.

Exiting from single user mode back to the default run level will save the serial console termnial configuration into /etc/

sh# exitbash# ls -l /etc/
-rw------- 1 root root 60 Jan 1 00:00 /etc/

The terminal settings saved in /etc/ will be used if the machine boots into single user mode for any reason.

If your attached terminal or modem cannot alter speed to 9600bps then the above procedure cannot be followed. ioctlsave has been written for this special case. It saves the current terminal settings to a file in the same format as The procedure is shown in Figure 8-1.

Figure 8-1. Using ioctlsave to create /etc/ without entering single user mode ttyS0 login: root
bash# rm -f /etc/
bash# ioctlsave -t /dev/ttyS0 /etc/

Inferno Solutions
Hosting by

Закладки на сайте
Проследить за страницей
Created 1996-2024 by Maxim Chirkov
Добавить, Поддержать, Вебмастеру