Cannot use finalize_recording_script_path script on jibri

Hi everyone.

I have problem with jibri. I did set path for finalize_recording_script_path on config.json and create a script for it. But when i end conversion log jibri show not found path. I don’t unterstend how to work. If somebody know it please tutorial me. Thank!

try to change owner of sh file.
sudo chown jibri:jibri /opt/jitsi/jibri/convert.sh

followed by sudo service jibri restart

Hi bro.

I did try set permission for script to 777 and owner jibri:jibri but it not work.

My script
root@jitsi:/# cat /opt/jitsi/jibri/convert.sh
#!/bin/bash
RECORDINGS_DIR=$1
echo “This is a dummy finalize script” > /tmp/finalize.out
echo “The script was invoked with recordings directory $RECORDINGS_DIR.” >> /tmp/finalize.out
echo “You should put any finalize logic (renaming, uploading to a service” >> /tmp/finalize.out
echo “or storage provider, etc.) in this script” >> /tmp/finalize.out

Why are you running this script from that directory? If you aren’t doing anything with the script, just put “” (2 apostrophes, with no spaces) in the path to the script.

HI. I need run a script for convert from mp4 to mp3 format.

but the script you posted is just a dummy script.

i dont see it doing the conversion at all…

for e.g you can use ffmpeg to do that

ffmpeg -i video.mp4 -b:a 192K -vn music.mp3

Your script might call the wrong path for bash (currently you have #!/bin/bash)

Check in the terminal for the path with: “which bash” and make sure the first line in your script matches the output…

you can do

which bash

I guess the script is for testing-purposes before trying to implement the ‘real thing’… :wink:

yes. i know my script :)), this is test for config finalize_recording_script_path work :))) i see errror " Cannot run program “/recordings/convert.sh”: error=2, No such file or directory with stack:" :)))

that right. :)) but it not working for me. i don’t know how to it work.

this is wrong

it has to be

sudo chown jibri:jitsi /opt/jitsi/jibri/convert.sh

3

i think is true.

I did try change permission follow you. but it not working. :)))

can you just run the script from CLI & see if it works?

run it as jibri user

yes. it work when i test manual “sh”

From your logfile in the earliest posts:

Could it be that your jibri process is running as root instead of user jibri? (I see an ls by ‘root@jitsi’). not sure but you should make sure the user is the correct user which can be logged-in on the jitsi machine and access the scripts as you try to do…

what version of java are you running?

OMG.

Maybe i found problem. I has copy and paste #!/bin/bash into my script. System don’t understand about it. I remove it and insert it #!/bin/bash manual. So well, my script is worked.

1 Like