SnapRAID Plugin Rules Question

  • My intention is to exclude the directory sftp which I have on my disk volume d1.

    Using the Rules tab in the Plugin I select Volume d1, and use the browser in the Rule box to select the directory sftp from the displayed tree structure, and then select Rule type Exclude. This results in the following comment and rule being written to /etc/snapraid.conf:

    # Rule selected from /srv/dev-disk-by-label-d1
    exclude /sftp/

    Looking at the SnapRAID documentation (, Section 8 Pattern, my interpretation of the created rule is that it applies only to the directory sftp in the root directory of the filesystem, not to the directory sftp in the root of Volume d1.

    Does anyone agree with my interpretation, or if not have another? Please look at the documentation before answering.

    It is my belief that it would be best if created rules used absolute paths, but since the box the Rule box is editable, one could make changes to arrive at different results. For example:

    sftp/ would match any directory sftp anywhere on the machine and would match multiple instances of that directory if more than one exists.

    A rule matching my exact intentions, and that seems to be in agreement with the documentation would be:

    # Rule selected from /srv/dev-disk-by-label-d1
    exclude /srv/dev-disk-by-label-d1/sftp/

    But this does not work.

    Google is your friend and Bob's your uncle!

    OMV AMD64 5.x on ASRock Rack C2550D4I C0 Stepping - 16GB ECC - Silverstone DS380 + Silverstone DS380 DAS Box.

    Edited 3 times, last by gderf ().

  • The following line is the most helpful

    Note that when you specify an absolute path starting with /, it's applied at the array root dir and not at the local file-system root dir.

    So, /sftp/ would never be an absolute path. It would be in the root of each drive in the snapraid array. And since /sftp is not on any data disk, snapraid configured by the plugin should never look at the absolute path of /sftp/. This is why the folder browser shows the path relative to the volume and not a root folder browser showing the entire OS filesystem.

    To exclude /srv/dev-disk-by-label-d1/sftp/, your exclude rule should just be /sftp/

    omv 5.5.22 usul | 64 bit | 5.4 proxmox kernel | omvextrasorg 5.4.4 plugins source code and issue tracker - github

    Please read this before posting a question.
    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!