-
-
Save asifbacchus/c2d4e57bed8b43d6bcccade836fc04a2 to your computer and use it in GitHub Desktop.
Running BorgBackup when /tmp is mounted with 'noexec' in fstab results in "error while loading shared libraries: libz.so.1: failed to map segment from shared object". Rename your borg binary to it's original name, (e.g borg-linux64), copy this script to /usr/bin/borg (or somewhere in your PATH) and make it executable (chmod +x or chmod 755).
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This is a helper script for BorgBackup to redirect temp to an | |
# executable-allowed location only while the program is running. | |
# This is necessary on systems where /TMP is mounted with | |
# the 'noexec' option for security in fstab. | |
# On a standard debian system, the line below would resemble: | |
# TEMP="/var/borgbackup/temp/" /usr/bin/borg-linux64 "$@" | |
# TEMP= must point to a path that is writable and can execute programs. | |
# That is followed by the full path to your borg executable. | |
# The "$@" passes all provided arguments to the borg executable | |
TEMP="/path/to/a/temp/location/" /path/to/borg-executable "$@" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment