-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
monitor (record/archive) function not working as it used to #382
Comments
I just noticed this warning in the Asterisk console (when people are keying up) which may be helpful: |
I just bumped into this article that states, "The Monitor dialplan application and module in Asterisk ... has since been replaced by the MixMonitor dialplan application and module and will be removed as of Asterisk 21". How does this apply to ASL3? Should I be using mixmonitor.so instead of monitor.so? |
Moving this to app_rpt. |
If "monitor" is going away, I hope the "archivedir" method can be updated to use mixmonitor, or something suitable. The reasons for moving to mixmonitor, described in the linked posting, seem prudent. In the meantime, I implemented a method for ASL3 to record audio using mixmonitor commands with a script that gets called from a node event when the number of connections changes from zero (0). So, while this alternate script method is possible, it is not nearly as simple as using "archivedir". The "archivedir" method also logs connection activity info in a txt file, which I have found quite useful over time. David WD5M |
Our local repeater also has been using this function for years, and your note made me wonder if ours was broken too.
|
Are you using simpleusb? This issue may be related to using the simpleusb radio interface. My limited testing seems to get good recordings on an ASL3 HUB VSP VM node without chan_simpleusb loaded. On the other hand, my Raspberry PI4 ASL3 node, using simpleusb, exhibits the symptoms described for this issue. Audio from the radio is not recorded and the described warning message is logged. Using mixmonitor records without issues on both nodes. David WD5M |
David - can you share your script and the call method? |
Thank you for your feedback! My codec setup (in modules.conf) is identical to yours, so that may not be the issue. |
I am using chan_voter since I have RTCM's at each repeater site. I had chan_simpleusb loaded because we used to have a URIx at one site, but we removed the URIx a while back so I unloaded chan_simpleusb (via modules.conf) and restarted Asterisk but that did not fix the problem described in this ticket. |
I call the script via the event segment(s) in rpt.conf. On my systems running multiple nodes, each node has its own event segment. Here's an example event segment. This is almost a copy of an example from the old Wiki for events.
My script is below. If you don't need the mp3 conversion, that part could be removed and just rename the wav file. As noted in the script, I'm not sure my choice of using "IAX2" as the channel argument for mixmonitor is the best choice. I haven't found a quick easy way to get or provide the actual connecting channel. This seems to be working for my use though.
|
I just completed a few hours of investigating and found that app_rpt.c is sending the "mixmonitor start ..." command to Asterisk (via the ast_cli_command routine found in ast_cli.h). This answers the question/concern about "monitor" vs. "mixmonitor" above. It appears it is using the newer version (mixmonitor), so that is put to rest. Interestingly, I can execute "mixmonitor start voter filename.wav49" from the Asterisk CLI (then "mixmonitor stop voter") and it records just fine. So, the problem doesn't seem to lie within the mixmonitor code. At this point I'm wondering if when app_rpt.c assembles the "mixmonitor start ..." command to send to Asterisk it is somehow getting the channel name wrong. I can't seem to find any way to turn on the proper debugging (at the proper level) to expose what is being sent from app_rpt to Asterisk. I may have to resort to adding hooks (printf's or something) to the code and recompiling, but I'm trying to figure out a way to debug this without having to go that far. The 60-byte (only) files I have been plagued with for months haven't appeared once during my testing; I'm only getting the strange sounding "techno music" files; no explanation on this. As an aside, I have another slightly newer installation of ASL3 on another node entirely (different repeater system) and I tried the archivedir command on it this morning and it records silence rather than the "techno music" described above (except that the ID and courtesy tone that the ASL3 code generates are recording just fine). If anyone has any thoughts or comments on above, please interject! |
Version: Asterisk 20.11.0+asl3-3.2.0-2.deb12 Both have Both are recording wav files in the archivedir. |
I just upgraded to the latest ASL3 and it is the same as yours. I also enabled chan_echolink just so my channel drivers would match yours (even though this likely won't fix anything). Result: neither of these changed anything. That said, this pushed me to thinking this really does have something to do with config differences rather than an issue I should be debugging at the code level (at least just yet). So now I'm curious about your OS and OS Kernel versions, etc. Can you send me a cut-and-paste of the entire page from your asl-menu Main Menu item number 4 "Show System Version Numbers"? [focusing solely on your node being used with the repeater employing the RTCM] Also, there are ways to change the codec being used with the RTCM (if I'm reading comments in voter.conf correctly). Can you send me the contents of your voter.conf? Can you shoot over the line where you call archivedir? Are you positive that when you key up your repeater that uses the RTCM that the file produced on your ASL3 box is truly listenable and includes audio traversing the RTCM itself? Can you send me an example file you've recorded via that ASL3 box JUST IN CASE it has something to do with the audio client that I'm using to listen to play the files (wouldn't that be crazy)? Thanks so much!! |
David - Can you send me a cut-and-paste of the entire page from your asl-menu Main Menu item number 4 "Show System Version Numbers"? [Also - thanks for the script!!] |
Let's see if I can get everything you asked :) Voter CONFIG: (I don't think it's anything "special"
rpt.conf at archive dir:
|
Zipped up audio from today (via RTCM) |
Describe the bug
I am using the “monitor” function to record repeater audio. We have one node that mixes audio from three RTCMs plus anyone attaching to the node via Allstar. Audio is recorded to a WAV file (date_and_time_stamp.WAV as filename) each time someone keys up until they unkey (one file per key-up), as expected. With the “previous” (very old) version of Allstar, every file contained audio, as would be expected. With ASL3 I’m finding that most, but not all, files are 60 bytes in length and contain no audio. The only files that are a sensible size and have audio appear to be from people who are connected to the node via Allstar. Also, every now and then we get a file that is recorded from someone coming in from an RTCM that sounds like some kind of techo music (it’s very musically interesting, actually - maybe an incorrect CODEC or something), otherwise its just a 60 byte file with no audio content.
I reported this problem on the forum here, but there isn't anything there that isn't in this report. Also, the same issue is posted here which includes a sample file from Andriy_Grin of the "techno music" I referenced above, if you want to hear something fun and interesting (but no intelligible audio).
To Reproduce
Steps to reproduce the behavior:
[1900](node-main)
archivedir = /var/spool/asterisk/monitor
Expected behavior
I expect to have a WAV (*.wav) file recorded that I can then play back just as would happen in the older version of ASL.
Software versions (listed in asl-menu, option 4)
OS: Debian GNU/Linux 12 (bookworm)
OS Kernel: 6.1.0-23-amd64
Asterisk: 20.8.1+asl3-3.0.2-1.deb12
ASL [app_rpt] : 3.0.1
Packages:
allmon3 1.2.1-2
asl3 3.2.0-1.deb
asl3-asterisk 2:20.8.1+asl3-3.0.2-1.deb12
asl3-asterisk-config 2:20.8.1+asl3-3.0.2-1.deb12
asl3-asterisk-dev 2:20.8.1+asl3-3.0.2-1.deb12
asl3-asterisk-doc 2:20.8.1+asl3-3.0.2-1.deb12
Our previous system that worked flawlessly was many years old and I am unsure how to determine the ASL version but Asterisk was "Asterisk 1537 built by root @ repeater on a i686 running Linux on 2016-09-03 21:38:23 UT".
Have you run a software update and rebooted?
Yes.
What is the platform - e.g. Raspberry Pi 4, Raspberry Pi 5, Virtual Machine, Desktop, etc.
Beelink SER5 Mini PC with AMD Ryzen 5 5560U 6 core (up to 4.0GHz) 16GB DDR4 RAM, 500GB NVMe M.2 SSD, RX Vega7
The text was updated successfully, but these errors were encountered: