Hey,
[...]
> >> Apparently it happens when the session is not ended properly
> >> (disconnections, etc)
> >> I could reproduce the problem as follow:
> >> * ssh to the server as normal user
> >> * sudo su -
> >> * vserver XX enter
> >> * now from another term, kill -9 on either of the two su processes ("su
> >> -"
> >> or "-su")
> >> At that point the session in the vserver ends but vcontext is still
> >> hooked
> >> to the
> >> current terminal so cpu is fine.
> >> * now quit the current terminal
> >> At that point vcontext is not hooked to any terminal (vps ax => "?" on
> >> the
> >> tty column)
> >> and using top you see it's running 100% cpu, ~ 80% system and 20% user.
> >
> > I'll look in to it.
>
> I am unable to reproduce that here. The vlogin process does stick around,
> which it probably shouldn't, but its resource usage is the same as it's
> always been.
I can reproduce it on debian sid with 2.6.20.1-vs2.3.0.11 kernel.
ps auxf
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 2716 82.5 0.0 116 40 ? R 15:17 7:04 login
root 2774 0.0 0.3 5072 1660 pts/6 Ss+ 15:17 0:00 \_
/bin/bash -login
I straced login process, strace shows:
Process 2716 attached - interrupt to quit
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "\r", 64) = 1
write(3, "\r", 1) = 1
select(4, [0 3], NULL, NULL, NULL) = 1 (in [3])
read(3, "\r\n", 64) = 2
write(1, "\r\n", 2) = 2
select(4, [0 3], NULL, NULL, NULL) = 1 (in [3])
read(3, "\33[1m/ \33[37;0m(\33[32;1m1525\33[37;0m"..., 64) = 47
write(1, "\33[1m/ \33[37;0m(\33[32;1m1525\33[37;0m"..., 47) = 47
Here session ended:
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "", 64) = 0
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "", 64) = 0
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "", 64) = 0
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "", 64) = 0
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "", 64) = 0
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
read(0, "", 64) = 0
select(4, [0 3], NULL, NULL, NULL) = 1 (in [0])
Jarek Dylag
_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Wed Mar 7 15:29:27 2007