Answer the question
In order to leave comments, you need to log in
Playing mp3 via CDR Report?
Hello . There is such a task that all the recordings of conversations were in mp3 format, the script converted the recordings of gsm and wav conversations (different servers) into mp3 format. If you download the recordings on a PC, then you can play them from any player, but you can’t listen through the CDR Report in FreePBX 13, it gives an error:
Exception
Unable to find an intermediary converter for /var/spool/asterisk/monitor/2019/04/17/out-номертелефона-1000-20190417-185204-155124.331.mp3
File:/var/www/html/admin/libraries/media/Media/Media.php:299
(screen attached) Answer the question
In order to leave comments, you need to log in
I struggled with this myself for a long time. the solution turned out to be simple - when converting a file to mp3, you just need to update the file name in the database.
Perhaps in the line "File:/var/www/html/admin/libraries/media/Media/Media.php:299" the number 299 means a line in the specified file.
Try to open this file on this line and see what command it is trying to execute there. maybe there will be some default converter that you don't have.
UPD:
Look at this entry, there is the 14th but I think the difference is not great: Clack-clack
If it doesn't help, google for the phrase: "FreePBX mp3"
This is how I do it) for the sake of the test, I installed FreePBX (Sangoma) 14 from the iso image, everything works.
but at 13 he didn’t want to start from sources.
the script itself
#!/bin/bash
cdrdb=asteriskcdrdb
cdrtable=cdr
astdbuser=freepbxuser
astdbuserpass=Passwd123
for i in `find /var/spool/asterisk/monitor/ -type f -name "*.wav"`
do
if [ -e "$i" ]; then
file=`basename "$i" .wav`;
dir=`dirname "$i"`;
ffmpeg -i "$i" -acodec libmp3lame -y "$dir/$file.mp3";
rm -f "$dir/$file.wav";.
mysql --user="$astdbuser" --password="$astdbuserpass" --database="$cdrdb" --execute='UPDATE '
fi
done
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question