[arm-allstar] Transmit hangs when asterisk reloads config

Aaron Hulett ahulett at live.com
Tue May 7 13:00:50 EDT 2019


Perfect, thank you Doug (and hello, fancy meeting you here!)

73,
Aaron

From: Doug Kingston <dpk at randomnotes.org>
Sent: Tuesday, May 7, 2019 10:25
To: ARM Allstar <arm-allstar at hamvoip.org>
Cc: Aaron Hulett <ahulett at live.com>; Doug Crompton <wa3dsp at gmail.com>
Subject: Re: [arm-allstar] Transmit hangs when asterisk reloads config

You can manipulate the files safely if you do the following sequence.  This relies on the fact that "mv -f" will use the rename(2) system call which is an atomic kernel call.

good weather case:
cp good_weather_tone.gsm ctN.gsm.tmp
mv -f ctN.gsm.tmp ctN.gsm

bad weather case:
cp bad_weather_tone.gsm ctN.gsm.tmp
mv -f ctN.gsm.tmp ctN.gsm

When asterisk calls the play routine it will always see a ctN.gsm file.  This approach of creating a new file with a temporary name and then doing a "mv -f" (or calling the rename() system call in the programming language of your choice), is always a good practice to avoid having a window when the file does not exist.

-Doug-

On Mon, May 6, 2019 at 9:30 PM "Doug Crompton via ARM-allstar" <arm-allstar at hamvoip.org<mailto:arm-allstar at hamvoip.org>> wrote:
Arron,

  Yes at least the way things are now that is probably not a good idea.
Using an audio file and changing it might be the answer for now but that
too might cause a problem if the courtesy tone request hits when you are
changing the file.  Give it a try and see if it works OK. We have this on
our list of things that need improvement and we will be looking at that  in
the future. For now it is probably best to not do it by reloading the file.


*73 Doug*

*WA3DSP*

*http://www.crompton.com/hamradio<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.crompton.com%2Fhamradio&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983089160&sdata=7UYz5L7X7vx5MV%2BPNP5IJFCn%2BptpsBsJspTeycWmGhk%3D&reserved=0> <http://www.crompton.com/hamradio<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.crompton.com%2Fhamradio&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983099159&sdata=Cj3Bz%2FTKteB8JILOM5hWvLUAOL6xYybRGptMDaKssF8%3D&reserved=0>>*

On Tue, May 7, 2019 at 12:05 AM Aaron Hulett <ahulett at live.com<mailto:ahulett at live.com>> wrote:

> Yes, it's hamvoip on a private node controlling a Yaesu DR-2X, and it has
> the latest updates. Here's version info:
>
> Firmware Version RPi2-3 Version 1.5rc6-7 Allstar - February 24, 2019
>
> AllStar version Asterisk
> 1.4.23.pre.hamvoip-V1.4.3-54-app_rpt-0.327-04/28/2019
>
> Linux kernel version 4.14.97-1-ARCH
> gcc version 8.2.1 20181127
>
>
> Now that you said that isn't normal and if I'm manually reloading config,
> I walked through everything I've done, and I believe I've got it. I wrote a
> script to check the weather watches/warinings and it runs every 5 minutes.
> Part of it is changing the courtesy tone if there's bad weather, and, it
> does this via the change_telemetry script as I'm changing it through the
> telemetry settings. I don't check to see if the state changes, so every 5
> minutes it runs change_telemetry.
>
> Sounds like I need to rethink this, such as using an audio file for the
> courtesy tone and replacing the file rather than changing the config?
>
> 73,
> Aaron
>
>
> -----Original Message-----
> From: ARM-allstar <arm-allstar-bounces at hamvoip.org<mailto:arm-allstar-bounces at hamvoip.org>> On Behalf Of "Doug
> Crompton via ARM-allstar"
> Sent: Monday, May 6, 2019 22:48
> To: ARM Allstar <arm-allstar at hamvoip.org<mailto:arm-allstar at hamvoip.org>>
> Cc: Doug Crompton <wa3dsp at gmail.com<mailto:wa3dsp at gmail.com>>
> Subject: Re: [arm-allstar] Transmit hangs when asterisk reloads config
>
> Arron,
>
>  Are you running hamvoip SW? We do not show you registered with any
> hamvoip code.  If you are make sure you are updated. We have never seen
> anything like this happen in hamvoip. What do you mean by "reload its
> config"  Do you mean restart? Are you manually reloading a config file.
>
>
> *73 Doug*
>
> *WA3DSP*
>
> *
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.crompton.com%2Fhamradio&data=02%7C01%7C%7C36e74a5e8d6c42b234f508d6d29eda0c%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636927977040601031&sdata=9a09JvB9aUVtAqM6Mc3utY5J509Jf%2B3pvgV5inhvqbI%3D&reserved=0<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.crompton.com%2Fhamradio&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983109171&sdata=AUi7EeX%2FiiHcO24ubtnDihHrAgo3BXxDprXqXScJGWM%3D&reserved=0>
> <
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.crompton.com%2Fhamradio&data=02%7C01%7C%7C36e74a5e8d6c42b234f508d6d29eda0c%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636927977040601031&sdata=9a09JvB9aUVtAqM6Mc3utY5J509Jf%2B3pvgV5inhvqbI%3D&reserved=0<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.crompton.com%2Fhamradio&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983119176&sdata=vHJ5SRb7t7uesTmmFEAVxNgQ7GPleNK8jPfaQjlPIRA%3D&reserved=0>
> >*
>
> On Mon, May 6, 2019 at 11:45 PM "Aaron Hulett via ARM-allstar" <
> arm-allstar at hamvoip.org<mailto:arm-allstar at hamvoip.org>> wrote:
>
> > Hi all,
> >
> > Running into an issue where when something comes along and causes
> > asterisk to reload its config, if someone's transmitting into the
> > repeater at that time, the Pi will keep PTT keyed even after the other
> > person lets up. If it times out, it clears PTT and all is good, or if
> > someone comes back and keys and lets up, this 'cycling' of COS also
> > takes care of it. This happens maybe every 5 to 10 minutes and only if
> > someone's transmitting in... I haven't locked on a constant time yet but
> it's in that range.
> >
> > Any idea why reloading the config would cause PTT to stick? Or, should
> > the question be why is asterisk reloading its config so often (and how
> > do I find the source and / or stop it from happening)?
> >
> > 73,
> > Aaron | K8AMH
> >
> >
> > _______________________________________________
> >
> > ARM-allstar mailing list
> > ARM-allstar at hamvoip.org<mailto:ARM-allstar at hamvoip.org>
> > https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists
> > .hamvoip.org<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fhamvoip.org&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983129188&sdata=HQPjFP5eo5TdYRWQlvZnbSxt0a0k8t%2BFK3fzj3mYtl0%3D&reserved=0>%2Fcgi-bin%2Fmailman%2Flistinfo%2Farm-allstar&data=02%
> > 7C01%7C%7C36e74a5e8d6c42b234f508d6d29eda0c%7C84df9e7fe9f640afb435aaaaa
> > aaaaaaa%7C1%7C0%7C636927977040601031&sdata=xXN6ErUcGCY5qgr6h9bTBpW
> > F55miUnlHQSsV0ns2mno%3D&reserved=0
> >
> > Visit the BBB and RPi2/3 web page -
> > https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fhamvo
> > ip.org<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fip.org&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983139193&sdata=EPXAKK1IoW89MYVEdzo9bj3HbSdfkL1t2f%2BxcN%2Bd98E%3D&reserved=0>&data=02%7C01%7C%7C36e74a5e8d6c42b234f508d6d29eda0c%7C84df9e
> > 7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636927977040601031&sdata=MTnD
> > rRx%2F%2FGfBIRHQAb3yVcMiMJSsWfvEQuy2KUKALMg%3D&reserved=0
> >
> _______________________________________________
>
> ARM-allstar mailing list
> ARM-allstar at hamvoip.org<mailto:ARM-allstar at hamvoip.org>
>
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.hamvoip.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Farm-allstar&data=02%7C01%7C%7C36e74a5e8d6c42b234f508d6d29eda0c%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636927977040601031&sdata=xXN6ErUcGCY5qgr6h9bTBpWF55miUnlHQSsV0ns2mno%3D&reserved=0<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.hamvoip.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Farm-allstar&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983149204&sdata=%2BZChMt7OMqPUjExUsXHL%2BQ90NPZy%2FCYOZhT1cKx6jyg%3D&reserved=0>
>
> Visit the BBB and RPi2/3 web page -
> https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fhamvoip.org&data=02%7C01%7C%7C36e74a5e8d6c42b234f508d6d29eda0c%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636927977040611036&sdata=sEWSDtOtMlsDFGGfS8RYxBctTUwy2pVJObf2c1jsqcM%3D&reserved=0<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fhamvoip.org&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983159210&sdata=8m%2F8l6C3J%2ByHFt17DxmLVrrhXf6iPGgPEVhypttknII%3D&reserved=0>
>
_______________________________________________

ARM-allstar mailing list
ARM-allstar at hamvoip.org<mailto:ARM-allstar at hamvoip.org>
http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.hamvoip.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Farm-allstar&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983169221&sdata=3vBwS4pwFrtkm490kfiaOsDA7qVFohef7LPwyB2dcOE%3D&reserved=0>

Visit the BBB and RPi2/3 web page - http://hamvoip.org<https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fhamvoip.org&data=02%7C01%7C%7C557965c41c90425c8b5308d6d30029be%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636928394983179232&sdata=fTo30%2FvQtW3G7uutE7Ypy6Rg7JOFjVydFc82YO%2F9rpg%3D&reserved=0>


More information about the ARM-allstar mailing list