Borgbackup plugin compact pop out message window output location?

  • While running a Borgbackup repository "Compact" option, the process begins and shows a starting message in the "pop out" message window on the OMV admin web page. This process takes a long time. After navigating away from the OMV web page to do other things and eat lunch :) upon returning, the admin account session has idle-timed out. After reconnecting, there is no longer a "pop out" message, so no way to inspect the results of the compact operation. (I looked at Syslog and Messages logs, did not see anything indicating compact when I filtered containing "borg".)


    In the borg documentation, under logging, there are CLI options to send the output of an operation to a file. Should I do compact as a cron job and capture the results to a file? I would like an e-mail on that cron job as well, is there a suggested syntax I can use?


    Also can you say if maybe this question's answer might generalily apply for stdout and stderr for any running process "pop out" message window that otherwise disappears because the admin session times out?


    Thank you.

    • New
    • Official Post

    After navigating away from the OMV web page to do other things and eat lunch :) upon returning, the admin account session has idle-timed out. After reconnecting, there is no longer a "pop out" message, so no way to inspect the results of the compact operation.

    All of this is as expected. Even you went to a non-omv page and came back, you would have to re-attach to the process. SInce the process is done, omv doesn't keep the output. If you want the output, either set your omv web interface to not auto-logout and leave the window open OR run the plugin as intended with schedule runs and check the box to email you the output.

    Should I do compact as a cron job and capture the results to a file? I would like an e-mail on that cron job as well, is there a suggested syntax I can use?

    Why not check the compact checkbox on the scheduled archive run and have it email you? Nothing to figure out or additional things to schedule.


    Also can you say if maybe this question's answer might generalily apply for stdout and stderr for any running process "pop out" message window that otherwise disappears because the admin session times out?

    Yes, they will "disappear". They are meant to be watched since they are testing the plugin. If the job is still running, you can usually re-attach.

    omv 8.0.10-2 synchrony | 6.17 proxmox kernel

    plugins :: omvextrasorg 8.0.2 | kvm 8.0.5 | compose 8.1.3 | cterm 8.0 | borgbackup 8.1.3 | cputemp 8.0 | mergerfs 8.0 | scripts 8.0.1 | writecache 8.1


    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!

  • I am attempting to use the Scheduled Tasks to run a borgbackup compact operation once a month. To see how it will work, I scheduled it for a few minutes into the future and then looked for the email. But no email arrived. [Yes I checked spam filters.]


    And, I have been successfully receiving emails generated in the OMV > System > Notification > Settings. I also get emails from the Borgbackup plugin when my scheduled backup jobs run.)


    If the command in Scheduled Tasks is has an error, will an e-mail be sent containing the error? Since there is no interactive way to test the syntax, I'm in the dark in case of a syntax snafu. For example, do I need to use sudo? Is the path (copied from the repo's share) in the correct format?


    See screenshot below of the OMV > System > Scheduled Task item below. See the syslog entry at the time the cron fired (below). See the contents of the cron file (below).


    What else can I look at to determine why I get no email?



    Code: syslog
    2/3/2026, 4:28:01 PM
    CRON[2615143]: (root) CMD (/var/lib/openmediavault/cron.d/userdefined-8d8d60af-e493-4be9-bd17-8a58bc21b333 2>&1 | mail -E -s "Cron" -a "From: Cron Daemon <root>" root >/dev/null 2>&1)
    Code: SSH Console
    rasproot@MAINFRAME:~ $
    rasproot@MAINFRAME:~ $ cd /var/lib/openmediavault/cron.d
    rasproot@MAINFRAME:/var/lib/openmediavault/cron.d $ cat userdefined-8d8d60af-e493-4be9-bd17-8a58bc21b333
    #!/bin/sh -l
    # This file is auto-generated by openmediavault (https://www.openmediavault.org)
    # WARNING: Do not edit this file, your changes will get lost.
    borg compact /srv/dev-disk-by-uuid-2602bb14-2801-4226-b3eb-817478e4022d/borgbackup_repository/
    rasproot@MAINFRAME:/var/lib/openmediavault/cron.d $
  • I realized I should try something a bit simpler. So I scheduled an echo "hello world" and that Scheduled Task e-mail came through.


    So It is definitely something unique to the borg compact CLI.


    I just tried this at the SSH console, there is no error and no output. The shell prompt returns immediately. What am I doing wrong?

    Code: ssh console
    Last login: Tue Feb  3 16:54:10 2026 from 192.168.1.58
    rasproot@MAINFRAME:~ $ Last login: Tue Feb  3 16:54:10 2026 from 192.168.1.58
    rasproot@MAINFRAME:~ $ sudo borg compact /srv/dev-disk-by-uuid-2602bb14-2801-4226-b3eb-817478e4022d/borgbackup_repository/
    rasproot@MAINFRAME:~ $
    • New
    • Official Post

    Again, why you don't want to check the compact checkbox in the archive?


    You need the --progress flag to show output. https://github.com/OpenMediaVa…d/rpc/borgbackup.inc#L589

    omv 8.0.10-2 synchrony | 6.17 proxmox kernel

    plugins :: omvextrasorg 8.0.2 | kvm 8.0.5 | compose 8.1.3 | cterm 8.0 | borgbackup 8.1.3 | cputemp 8.0 | mergerfs 8.0 | scripts 8.0.1 | writecache 8.1


    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!

  • You need the --progress flag to show output. https://github.com/OpenMediaVa…d/rpc/borgbackup.inc#L589

    Thank you for providing that additional command option. When I include --process flag I get email as follows:

    Code
    From: Cron Daemon
    Subject: [MAINFRAME] Cron - Borgbackup Compact
    Compacting segments   0% Compacting segments   4% Compacting segments   7% Compacting segments  11% Compacting segments  14% Compacting segments  18% Compacting segments  21% Compacting segments  25% Compacting segments  29% Compacting segments  32% Compacting segments  36% Compacting segments  39% Compacting segments  43% Compacting segments  46% Compacting segments  50% Compacting segments  54% Compacting segments  57% Compacting segments  61% Compacting segments  64% Compacting segments  68% Compacting segments  71% Compacting segments  75% Compacting segments  79% Compacting segments  82% Compacting segments  86% Compacting segments  89% Compacting segments  93% Compacting segments  96%


    Which is rather useless. At least it did generate an email and gave me the clues needed to find other more useful borg command options.



    So, for the benefit of anyone else reading this, here is my proposed answer to this question:

    Code
    borg compact /srv/dev-disk-by-uuid-2602bb14-2801-4226-b3eb-817478e4022d/borgbackup_repository/ --verbose --show-version --show-rc 



    I recommend including "--verbose --show-version --show-rc" flags, since this has the advantage of also sending an e-mail even if there is an error encountered. I also found in a different forum thread that the Tags option in Scheduled Tasks is the way to provide values to the Subject: of the email received.


    • New
    • Official Post

    Becuz "<The user can choose when to run the compaction, it should be done periodically, but not necessarily after each backup.>"

    While not wrong, that statement was created before the option to run it in a backup was added. The more time between compactions, the longer it takes to run. So, it does not hurt to run on every backup.

    Which is rather useless

    Since you didn't tell me what kind of output you were looking for, I just gave you the flags the compact button in the plugin uses.

    omv 8.0.10-2 synchrony | 6.17 proxmox kernel

    plugins :: omvextrasorg 8.0.2 | kvm 8.0.5 | compose 8.1.3 | cterm 8.0 | borgbackup 8.1.3 | cputemp 8.0 | mergerfs 8.0 | scripts 8.0.1 | writecache 8.1


    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!

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!