Pascalscript execute fails

General Discussion in English
Post Reply
Wombat
Posts: 21
Joined: Tue Jul 15, 2025 3:24 pm

Pascalscript execute fails

Post by Wombat »

I'm trying to call a script from Pascalscript using this function.

Code: Select all

function OnProfileStart:Boolean;
begin
  Execute('/volume1/scripts/zabbix-db-backup.sh', 60);
  Result:=true;
end;
This is on an Asustor NAS. Syncovery is running as root. The script has 755 permissions and runs fine when called from the cmdline. When called from Pascalscript as above I see this in the log

Executed /volume1/scripts/zabbix-db-backup.sh, Exit Code=1

If I try and use it from the Job -> Before field it also fails. I've tried prefixing the command with '/bin/ash -c ' but no luck there either. It even fails when the script simply contains an exit command.

The commands I have trying to run are all in /volume1/.@plugins/AppCentral/Syncovery/DATA/bin/authorized_cmdlines_syncovery
/volume1/scripts/zabbix-db-backup.sh
/bin/ash -c /volume1/scripts/zabbix-db-backup.sh
ash -c /volume1/scripts/zabbix-db-backup.sh
The command I want to run from this script is this:
/usr/local/bin/docker exec -it postgresql-server pg_dump --format c --user zabbix --dbname zabbix >/tmp/zabbix.postgresql.dump

I have no idea what I'm doing wrong. Any help appreciated. Thanks.
Post Reply