[asterisk-bugs] [JIRA] (ASTERISK-19867) asterisk fails to lower its priority when astcanary dies

George Joseph (JIRA) noreply at issues.asterisk.org
Wed Aug 2 10:14:15 CDT 2017


     [ https://issues.asterisk.org/jira/browse/ASTERISK-19867?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

George Joseph updated ASTERISK-19867:
-------------------------------------

    Target Release Version/s: 15.0.0

> asterisk fails to lower its priority when astcanary dies
> --------------------------------------------------------
>
>                 Key: ASTERISK-19867
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-19867
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Utilities/astcanary
>    Affects Versions: 1.8.7.2, 1.8.11.1, 1.8.12.0, 11.23.1
>         Environment: Debian GNU/Linux 6 (squeeze)
> Linux 2.6.32-5-686 and 2.6.32-5-686-bigmem
> GNU libc 2.11
>            Reporter: Xavier Hienne
>            Assignee: Rusty Newton
>      Target Release: 11.24.0, 15.0.0
>
>
> When astcanary dies, asterisk is supposed to lower its priority and return to the SCHED_OTHER scheduling policy.
> This is not what I'm observing on Linux: apparently, the death of astcanary is detected by the watching thread, but it fails to change the priority of all other asterisk threads. I suspect that only the watching thread sees its priority changed (just before dying) and this might be the expected behavior of sched_setscheduler() with pid=0.
> Here is how to reproduce this issue:
> $ ps u $(pidof astcanary asterisk)
> USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
> root     31854  6.8  3.3  34732 17120 ?        Ssl  15:59   0:00 /usr/sbin/asterisk -p -M 1000
> root     31855  0.0  0.1   2892   772 ?        S    15:59   0:00 astcanary /var/run/asterisk/alt.asterisk.canary.tweet.tweet.tweet 31854
> $ chrt -p $(pidof asterisk)
> pid 31854's current scheduling policy: SCHED_RR
> pid 31854's current scheduling priority: 10
> $ killall astcanary 
> (after some time => WARNING[31856] asterisk.c: The canary is no more...)
> $ chrt -p $(pidof asterisk)
> pid 31854's current scheduling policy: SCHED_RR
> pid 31854's current scheduling priority: 10
> => asterisk is still at its highest priority



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list