Command doesn't run as scheduled Job

  • I want to schedule the run of a command that back's up my sql database that is running inside a docker container, so that I can back this up externally using duplicati. I found a command that works when I run it in a shell, using either sudo or logging in as root and running it, but the command throws an error when I run it as a scheduled job in OMV. Here is the command.

    Code
    docker exec -it zabbix-mysql /bin/bash -c 'mysqldump -u root -pmypassword zabbix > /var/lib/mysql/backups/zabbix.sql'


    And here is the error the OMV throws when I try to run it as a scheduled job.


    and the error details.


    If no one can help me figure out what is causing the error and fix it, I am also willing to take suggestions on different ways to accomplish my goal of backing up the database.

    • Offizieller Beitrag

    Try removing the t from -it since that is telling it to use tty.

    omv 7.0.5-1 sandworm | 64 bit | 6.8 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.13 | compose 7.1.4 | k8s 7.1.0-3 | cputemp 7.0.1 | mergerfs 7.0.4


    omv-extras.org plugins source code and issue tracker - github - changelogs


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!