:: Re: [DNG] inittab getty tty
Kezdőlap
Delete this message
Reply to this message
Szerző: mett
Dátum:  
Címzett: dng
Tárgy: Re: [DNG] inittab getty tty
2016-09-23 23:56 に Rainer Weikusat さんは書きました:
> mett <mett@???> writes:
>
> [...]
>
>
>> I realized few days ago I had not any tty when the server comes up
>> (and is up), while trying to set up a serial connection to this
>> server:
>>
>> root@tamerrp:/home/mettler# ps aux | grep tty
>> root 3560 0.0 0.0 12728 2284 pts/2 S+ 11:19 0:00 grep tty
>>
>> root@tamerrp:/home/mettler# dmesg | grep tty
>> [0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-3.16.0-4-amd64
>> root=UUID=5982d543-1e27-4350-b2f2-81d0cc40e0a0 ro console=tty0
>> console=ttyS0,9600n8
>> [0.000000] Kernel command line:
>> BOOT_IMAGE=/boot/vmlinuz-3.16.0-4-amd64
>> root=UUID=5982d543-1e27-4350-b2f2-81d0cc40e0a0 ro console=tty0
>> console=ttyS0,9600n8
>> [0.000000] console [tty0] enabled
>> [0.000000] console [ttyS0] enabled
>> [8.132769] 00:04: ttyS0 at I/O 0x3f8 (irq = 4, base_baud = 115200) is
>> a 16550A
>> [30.550283] ttyS1: LSR safety check engaged!
>> [30.611799] ttyS1: LSR safety check engaged!
>>
>> (I can connect via ssh).
>
> The command-line you're booting with instructs the kernel to print
> output on tty0 and ttyS0 but only accept input from ttyS0.


Thanks for your answers.
ttyS0 is not available as well.
Once the system is booted, only ssh is available.
(I don't have any problem at boot level, or even at BIOS level(it's an
HP DL320 g5s)
I can select kernel via graphical-console or serial-console, according
to how I set /etc/default/grub, by the way.
Right now I've defaulted everything, so I can only select kernel via
graphical-console at boot level).

>
>> It seems init is not parsing /etc/inittab while starting up
>> (init q seems wihtout effect as well).
>
> This seems very unlikely. In order to check for this, you could attach
> an strace to init with
>
> strace -f -p 1
>
> [...]

Here is the result of strace:
----------------------------------------------------------------------
root@tamerrp:/home/mettler# strace -f -p 1
Process 1 attached
select(11, [10], NULL, NULL, {4, 999684}init q
) = 0 (Timeout)
stat("/run/initctl", {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
fstat(10, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
stat("/run/initctl", {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
select(11, [10], NULL, NULL, {5, 0})    = 0 (Timeout)
stat("/run/initctl", {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
fstat(10, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
stat("/run/initctl", {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
select(11, [10], NULL, NULL, {5, 0})    = 0 (Timeout)
stat("/run/initctl", {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
fstat(10, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
stat("/run/initctl", {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
select(11, [10], NULL, NULL, {5, 0}^CProcess 1 detached
  <detached ...>
----------------------------------------------------------------------
My goal is to boot with sysvinit.
----------------------------------------------------------------------
root@tamerrp:/home/mettler# less /sbin/init
[...]
INIT_VERSION=sysvinit-2.88
[...]
----------------------------------------------------------------------
I think Ill try the init re-install path, installing another init 
before.
I started making a script calling getty from /etc/rc0.d or 
/etc/rc.local,
but, I finally think it's wiser to have sysvinit doing what it is 
expected to do.


Thanks again.