# ARNews not appearing to work

**URL:** <https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018>\
**Category:** Archive\
**Created:** [October 8, 2024, 1:28am UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018 "2024-10-08T01:28:52Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![K6IRK](https://community.allstarlink.org/user_avatar/community.allstarlink.org/k6irk/32/3044_2.png) [@K6IRK](https://community.allstarlink.org/u/K6IRK)\
**Post date:** [October 8, 2024, 1:28am UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/1 "2024-10-08T01:28:52Z")

</div>

I am running ASL3 -

Asterisk : 20.9.3+asl3-3.0.6.1.deb12  
ASL [app\_rpt] : 3.0.6

Running on a Pi4

The command I used was:

/usr/bin/asl-play-arn --node 620301

Nothing showed as happening, so I did the debug mode and this is what I got:

## root@node620301:/home/Trebor57# /usr/bin/asl-play-arn --node 620301 --debug play-arn: **main** : DEBUG: MP3\_OUT: /tmp/tmpn3osslpq.mp3 play-arn: **main** : DEBUG: WAV\_OUT: /tmp/tmpew3uvk7m.wav play-arn: **main** : DEBUG: UL\_OUT: /tmp/tmp2jtziimj.ul play-arn: **main** : DEBUG: Convert MP3 to WAV: lame -h -S --decode /tmp/tmpn3osslpq.mp3 /tmp/tmpew3uvk7m.wav play-arn: **main** : DEBUG: Convert WAV to ULAW: sox -v 0.7 /tmp/tmpew3uvk7m.wav -r 8k -c 1 -t ul /tmp/tmp2jtziimj.ul play-arn: **main** : DEBUG: Play Asterisk: ['asterisk', '-rx', 'rpt playback 620301 /tmp/tmp2jtziimj'] play-arn: **main** : DEBUG: sleeping for 15 seconds for playback to start root@node620301:/home/Trebor57#

But nothing happens at all, no audio or anything.

What do I have wrong here?

73

Rob

---

<div class="post-metadata">

**Author:** ![bdwalker1](https://community.allstarlink.org/user_avatar/community.allstarlink.org/bdwalker1/32/3367_2.png) [@bdwalker1](https://community.allstarlink.org/u/bdwalker1)\
**Post date:** [October 8, 2024, 2:57am UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/2 "2024-10-08T02:57:51Z")

</div>

This seems to be a file permissions issue with the temporary ulaw file created. Apparently the asterisk service cannot access the file.

I was able to get it working on my node by adding a few lines to `/usr/bin/asl-play-arn` to give read permissions on the temporary file to all users.

Near the top of the file, I added two imports to the end of the import section:

`import os`  
`import stat`

Further down, I added the line:

`os.chmod(UL_OUT.name, stat.S_IROTH)`

Here is a screencap of where I added it:

 ![Screenshot 2024-10-07 194850](https://community.allstarlink.org/uploads/default/original/2X/9/9927c29f1149f3feb0ec9881a6a2d3d5791cf4fc.png)

Note: Be sure you use the same indent character(s) already in the file. I initially used four spaces on the `chmod` line which resulted in an error. I changed it to two tabs and the error went away.

I suspect if I was running the script via `cron` this may not be a problem, but I have not tried that, yet.

---

<div class="post-metadata">

**Author:** ![N8EI](https://community.allstarlink.org/user_avatar/community.allstarlink.org/n8ei/32/4254_2.png) [@N8EI](https://community.allstarlink.org/u/N8EI)\
**Post date:** [October 8, 2024, 2:05pm UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/3 "2024-10-08T14:05:48Z")

</div>

The correct solution is to run `asl-play-arn` as the `asterisk` user. That’s how it’s intended to work, usually out of a crontab.

---

<div class="post-metadata">

**Author:** ![K6IRK](https://community.allstarlink.org/user_avatar/community.allstarlink.org/k6irk/32/3044_2.png) [@K6IRK](https://community.allstarlink.org/u/K6IRK)\
**Post date:** [October 8, 2024, 3:08pm UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/4 "2024-10-08T15:08:12Z")

</div>

What would be the correct crontab entry then for it? I have not found any docs on the best way to add it.

---

<div class="post-metadata">

**Author:** ![N8EI](https://community.allstarlink.org/user_avatar/community.allstarlink.org/n8ei/32/4254_2.png) [@N8EI](https://community.allstarlink.org/u/N8EI)\
**Post date:** [October 8, 2024, 3:17pm UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/5 "2024-10-08T15:17:47Z")

</div>

The simpliest way is to create a file `/etc/cron.d/asl` with something like the following contents:

```auto
30 19 * * 3 asterisk /usr/bin/asl-play-arn --node 620301

```

In this case, it’ll play at 1930 local time every Wednesday. Cron is extensively documented in `man crontab` and `man 5 crontab`.

---

<div class="post-metadata">

**Author:** ![K6IRK](https://community.allstarlink.org/user_avatar/community.allstarlink.org/k6irk/32/3044_2.png) [@K6IRK](https://community.allstarlink.org/u/K6IRK)\
**Post date:** [October 11, 2024, 1:42am UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/6 "2024-10-11T01:42:23Z")

</div>

I tried exactly as you suggested and did a different schedule, but when the time came, nothing happened.

---

<div class="post-metadata">

**Author:** ![N8EI](https://community.allstarlink.org/user_avatar/community.allstarlink.org/n8ei/32/4254_2.png) [@N8EI](https://community.allstarlink.org/u/N8EI)\
**Post date:** [October 11, 2024, 12:17pm UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/7 "2024-10-11T12:17:52Z")

</div>

Does it play if you do `sudo -u asterisk asl-play-arn --debug --node 620301`? Does the `--debug` flag show any errors?

---

<div class="post-metadata">

**Author:** ![K6IRK](https://community.allstarlink.org/user_avatar/community.allstarlink.org/k6irk/32/3044_2.png) [@K6IRK](https://community.allstarlink.org/u/K6IRK)\
**Post date:** [October 11, 2024, 6:13pm UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/8 "2024-10-11T18:13:35Z")

</div>

that worked.

So, is there something with this that is a possible issue?

30 19 \* \* 3 asterisk /usr/bin/asl-play-arn --node 620301

is it possible to play it on multiple nodes at the same time as well?

Thank you

---

<div class="post-metadata">

**Author:** ![N8EI](https://community.allstarlink.org/user_avatar/community.allstarlink.org/n8ei/32/4254_2.png) [@N8EI](https://community.allstarlink.org/u/N8EI)\
**Post date:** [October 11, 2024, 9:51pm UTC](https://community.allstarlink.org/t/arnews-not-appearing-to-work/22018/9 "2024-10-11T21:51:40Z")

</div>

> [@K6IRK](#):
>
> So, is there something with this that is a possible issue?  
> 30 19 \* \* 3 asterisk /usr/bin/asl-play-arn --node 620301

This should be equivalent except that one is timed and the other is immediate. Not sure why one works and one does not. Are there any errors in the CRON log?

> [@K6IRK](#):
>
> is it possible to play it on multiple nodes at the same time as well?

You could fire multiple commands at the same time. But app\_rpt doesn’t support playback on multiple nodes with one command.
