Running a bash script (permission error)


I have created a bash script ( on /data/INTERNAL but when i try to run it cd /data/INTERNAL && ./ i get a permission error.
If i execute it with sudo everything works fine, but how should i use it if i put in on a crontab job?

Thank you.

Try to change the owner of the file to the user who has to be able execute it, e.g. for user volumio: sudo chown volumio:volumio /data/INTERNAL/

Thank you for your answer.
Unfortunately, it didn’t work and I still get a permission denied error.

volumio@volumio:/data/INTERNAL$ ./ /data/INTERNAL/Podcast/20190806-apotis4stis5.mp3: Permission denied
When I executed it with sudo it worked fine

It seems that I had to change the folder permission too

sudo chown -R volumio:volumio Podcast

Thank you for the answer, it helped me!