Trickle does not work with kmail - hangs it

Bug #531287 reported by LimCore
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
trickle (Ubuntu)
New
Undecided
Unassigned

Bug Description

trickle -d 100 -u 100 kmail

Kmail runs, but as soon as the trickle has to limit the bandwitch (so it actually starts limiting) then kmail hangs fully (even the window does not refresh).

killall kmail works.

Perhaps this is caused because kmail that was start "exits" (and some child or something is running only)?
when running kmail,
kmail (pid=17635) is started for example, it spawns kmail (pid=17636), and also spawns various kdeinit4: kio_imap4 [kdeinit]

Perhaps it causes the problem that not all of the processes have trickle attached to them - or that trickel exists because original kmail exists, but the childs still think a trickle is running.

Running trickled and then trickle kmail does not help. In such scenario, killall trickled does not un-hang kmail.

rafal@lcwood(12:45:51)~$ trickled -d 50 -u 100 -w 32
rafal@lcwood(12:48:16)~$ trickle kmail
rafal@lcwood(12:48:31)~$ killall trickled

strace of kmail (done by strace -p `pidof kmail`)

mprotect(0x7fbd9c30e000, 4096, PROT_READ|PROT_WRITE) = 0
munmap(0x7fbda1a33000, 1052672) = 0
read(8, 0x21e0e34, 4096) = -1 EAGAIN (Resource temporarily unavailable)
read(19, 0x22f7794, 4096) = -1 EAGAIN (Resource temporarily unavailable)
fcntl(18, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
fcntl(35, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
fcntl(36, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
fcntl(37, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
fcntl(38, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
poll([{fd=3, events=POLLIN}, {fd=14, events=POLLIN|POLLPRI}, {fd=16, events=POLLIN|POLLPRI}, {fd=17, events=POLLIN|POLLPRI}, {fd=18, events=POLLIN|POLLPRI}, {fd=19, events=POLLIN}, {fd=20, events=POLLIN}, {fd=21, events=POLLIN}, {fd=22, events=POLLIN}, {fd=8, events=POLLIN}, {fd=5, events=POLLIN}, {fd=24, events=POLLIN}, {fd=35, events=0}, {fd=36, events=0}, {fd=37, events=0}, {fd=38, events=0}], 16, 0) = 0 (Timeout)
read(8, 0x21e0e34, 4096) = -1 EAGAIN (Resource temporarily unavailable)
madvise(0x7fbd9c026000, 3051520, MADV_DONTNEED) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=2679, ...}) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=2679, ...}) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=2679, ...}) = 0
fcntl(38, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
fcntl(38, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
select(38, [], [], NULL, {3, 0}) = 0 (Timeout)
fcntl(38, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
select(39, [38], [], NULL, NULL

after killall kmail the strace says:

) = ? ERESTARTNOHAND (To be restarted)
--- SIGTERM (Terminated) @ 0 (0) ---
rt_sigaction(SIGKILL, {SIG_DFL, [KILL], SA_RESTORER|SA_RESTART, 0x7f73a9007530}, {0x7fff53576650, [INT TRAP ABRT BUS], 0x1c18290 /* SA_??? */}, 8) = -1 EINVAL (Invalid argument)
rt_sigaction(SIGTERM, {SIG_DFL, [TERM], SA_RESTORER|SA_RESTART, 0x7f73a9007530}, {0x4022e8, [TERM], SA_RESTORER|SA_RESTART, 0x7f73a9007530}, 8) = 0
rt_sigaction(SIGHUP, {SIG_DFL, [HUP], SA_RESTORER|SA_RESTART, 0x7f73a9007530}, {0x4022e8, [HUP], SA_RESTORER|SA_RESTART, 0x7f73a9007530}, 8) = 0
write(2, "*** KMail got signal 15 (Exiting"..., 34) = 34
futex(0x29b7acc, FUTEX_CMP_REQUEUE_PRIVATE, 1, 2147483647, 0x29b7aa0, 4) = 2
futex(0x29d449c, FUTEX_WAIT_PRIVATE, 1, NULL) = 0
futex(0x29d4470, FUTEX_WAKE_PRIVATE, 1) = 0
writev(5, [{"l\1\1\1m\0\0\0}\0\0\0\177\0\0\0\1\1o\0\25\0\0\0/org/fre"..., 144}, {"h\0\0\0type='signal',path='/KIO/Sch"..., 109}], 2) = 253
close(36) = 0
close(35) = 0
close(37) = 0
close(38) = 0
[...]

Actually, trickle seems to not start:

read(3, 0x11af050, 2048) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=3, events=POLLIN}], 1, 24961) = 1 ([{fd=3, revents=POLLIN}])
read(3, "l\4\1\1 \0\0\0\t\0\0\0\211\0\0\0\1\1o\0\25\0\0\0/org/fre"..., 2048) = 192
read(3, 0x11af050, 2048) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=3, events=POLLIN}], 1, 24886) = 1 ([{fd=3, revents=POLLIN}])
read(3, "l\4\1\0018\0\0\0\n\0\0\0\211\0\0\0\1\1o\0\25\0\0\0/org/fre"..., 2048) = 216
read(3, 0x11af050, 2048) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=3, events=POLLIN}], 1, 24689) = 1 ([{fd=3, revents=POLLIN}])
read(3, "l\2\1\1\177\v\0\0003\0\0\0000\0\0\0\6\1s\0\7\0\0\0:1.1031\0"..., 2048) = 2048
read(3, "<arg type=\"i\" direction=\"out\"/>\n"..., 2048) = 959
brk(0x11d6000) = 0x11d6000
writev(3, [{"l\1\0\1'\0\0\0\10\0\0\0\202\0\0\0\1\1o\0\20\0\0\0/MainApp"..., 152}, {"\0\0\0\0\37\0\0\0\0\0\0\v/home/rafal\0\0\0\1\377\377\377\377\0"..., 39}], 2) = 191
poll([{fd=3, events=POLLIN}], 1, 25000) = 1 ([{fd=3, revents=POLLIN}])
read(3, "l\2\1\1\4\0\0\0A\0\0\0000\0\0\0\6\1s\0\7\0\0\0:1.1031\0"..., 2048) = 68
read(3, 0x11c14b0, 2048) = -1 EAGAIN (Resource temporarily unavailable)
exit_group(0) = ?

because it exists almost instantly.

ii kmail 4:4.3.2-0ubuntu6 KDE Email client
ii trickle 1.07-7 user-space bandwidth shaper

LimCore (limcore)
affects: ubuntu → trickle (Ubuntu)
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.