Compare commits
7 Commits
c6882230bd
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| b22f275b2d | |||
| 2657766326 | |||
| d5531d9ca1 | |||
| beeff9c512 | |||
| 8af00f038e | |||
| ec9f1c4d68 | |||
| 8e62b199c9 |
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
# Version: 2.5.0
|
||||
# Version: 2.5.1
|
||||
# Author: Tomi Eckert
|
||||
# ==============================================================================
|
||||
# Aurora Refresh Script
|
||||
@@ -14,7 +14,7 @@
|
||||
# Find the script's own directory to locate the config file and hanatool.sh
|
||||
SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)
|
||||
CONFIG_FILE="${SCRIPT_DIR}/aurora.conf"
|
||||
HANATOOL_PATH="${SCRIPT_DIR}/../hanatool.sh"
|
||||
HANATOOL_PATH="${SCRIPT_DIR}/hanatool.sh"
|
||||
|
||||
# Check for config file and source it
|
||||
if [[ -f "$CONFIG_FILE" ]]; then
|
||||
|
||||
@@ -244,7 +244,7 @@ SL_LB_PORT=${SL_LB_PORT}
|
||||
SL_LB_MEMBERS=${SL_LB_MEMBERS}
|
||||
SL_THREAD_PER_SERVER=10
|
||||
|
||||
SELECTED_FEATURES=B1ServerTools,B1ServerToolsLandscape,B1ServerToolsSLD,B1ServerToolsLicense,B1ServerToolsJobService,B1ServerToolsXApp,B1SLDAgent,B1BackupService,B1Server,B1ServerSHR,B1ServerHelp,B1AnalyticsPlatform,B1ServerCommonDB,B1ServiceLayerComponent
|
||||
SELECTED_FEATURES=B1ServerTools,B1ServerToolsLandscape,B1ServerToolsSLD,B1ServerToolsLicense,B1ServerToolsJobService,B1ServerToolsXApp,B1SLDAgent,B1BackupService,B1Server,B1ServerSHR,B1ServerHelp,B1AnalyticsPlatform,B1ServerCommonDB,B1ServiceLayerComponent,B1WebClient
|
||||
|
||||
B1S_SAMBA_AUTOSTART=true
|
||||
B1S_SHARED_FOLDER_OVERWRITE=${B1S_SHARED_FOLDER_OVERWRITE}
|
||||
|
||||
@@ -28,7 +28,7 @@ SVC_NAMES[1]="SAP HANA Database (System & Company DB)"
|
||||
SVC_PORTS[1]="30013 30015"
|
||||
|
||||
SVC_NAMES[2]="SAP Business One SLD"
|
||||
SVC_PORTS[2]="40000"
|
||||
SVC_PORTS[2]="40000 40001 40002 40003 40004 40005"
|
||||
|
||||
SVC_NAMES[3]="SAP Business One Auth"
|
||||
SVC_PORTS[3]="40020"
|
||||
|
||||
33
hanatool.sh
33
hanatool.sh
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
# Version: 1.5.6
|
||||
# Version: 1.5.9
|
||||
# Author: Tomi Eckert
|
||||
# ==============================================================================
|
||||
# SAP HANA Schema and Tenant Management Tool (hanatool.sh)
|
||||
@@ -30,6 +30,13 @@ DRY_RUN=false
|
||||
NTFY_TOKEN=""
|
||||
IMPORT_REPLACE=false
|
||||
|
||||
# Detect pigz for parallel compression
|
||||
if command -v pigz &>/dev/null; then
|
||||
USE_PIGZ=true
|
||||
else
|
||||
USE_PIGZ=false
|
||||
fi
|
||||
|
||||
# --- Help/Usage Function ---
|
||||
usage() {
|
||||
echo "SAP HANA Schema and Tenant Management Tool"
|
||||
@@ -228,9 +235,17 @@ case "$ACTION" in
|
||||
|
||||
TAR_EXIT_CODE=0
|
||||
if [[ "$DRY_RUN" == "true" ]]; then
|
||||
if [[ "$USE_PIGZ" == "true" ]]; then
|
||||
echo "[DRY RUN] Would execute tar (pigz): tar -I \"pigz -p $THREADS\" -cf \"$ARCHIVE_FILE\" -C \"$backup_target_dir\" ."
|
||||
else
|
||||
echo "[DRY RUN] Would execute tar: tar -czf \"$ARCHIVE_FILE\" -C \"$backup_target_dir\" ."
|
||||
fi
|
||||
else
|
||||
if [[ "$USE_PIGZ" == "true" ]]; then
|
||||
tar -I "pigz -p $THREADS" -cf "$ARCHIVE_FILE" -C "$backup_target_dir" .
|
||||
else
|
||||
tar -czf "$ARCHIVE_FILE" -C "$backup_target_dir" .
|
||||
fi
|
||||
TAR_EXIT_CODE=$?
|
||||
fi
|
||||
|
||||
@@ -304,9 +319,17 @@ case "$ACTION" in
|
||||
|
||||
TAR_EXIT_CODE=0
|
||||
if [[ "$DRY_RUN" == "true" ]]; then
|
||||
if [[ "$USE_PIGZ" == "true" ]]; then
|
||||
echo "[DRY RUN] Would execute tar (pigz): tar -I \"pigz -p $THREADS\" -cf \"$ARCHIVE_FILE\" -C \"$(dirname "$EXPORT_DIR")\" \"$(basename "$EXPORT_DIR")\""
|
||||
else
|
||||
echo "[DRY RUN] Would execute tar: tar -czf \"$ARCHIVE_FILE\" -C \"$(dirname "$EXPORT_DIR")\" \"$(basename "$EXPORT_DIR")\""
|
||||
fi
|
||||
else
|
||||
if [[ "$USE_PIGZ" == "true" ]]; then
|
||||
tar -I "pigz -p $THREADS" -cf "$ARCHIVE_FILE" -C "$(dirname "$EXPORT_DIR")" "$(basename "$EXPORT_DIR")"
|
||||
else
|
||||
tar -czf "$ARCHIVE_FILE" -C "$(dirname "$EXPORT_DIR")" "$(basename "$EXPORT_DIR")"
|
||||
fi
|
||||
TAR_EXIT_CODE=$?
|
||||
fi
|
||||
|
||||
@@ -377,9 +400,17 @@ case "$ACTION" in
|
||||
|
||||
TAR_EXIT_CODE=0
|
||||
if [[ "$DRY_RUN" == "true" ]]; then
|
||||
if [[ "$USE_PIGZ" == "true" ]]; then
|
||||
echo "[DRY RUN] Would decompress archive (pigz): tar -I \"pigz -p $THREADS\" -xf \"$SOURCE_PATH\" -C \"$IMPORT_DIR\" --strip-components=1"
|
||||
else
|
||||
echo "[DRY RUN] Would decompress archive: tar -xzf \"$SOURCE_PATH\" -C \"$IMPORT_DIR\" --strip-components=1"
|
||||
fi
|
||||
else
|
||||
if [[ "$USE_PIGZ" == "true" ]]; then
|
||||
tar -I "pigz -p $THREADS" -xf "$SOURCE_PATH" -C "$IMPORT_DIR" --strip-components=1
|
||||
else
|
||||
tar -xzf "$SOURCE_PATH" -C "$IMPORT_DIR" --strip-components=1
|
||||
fi
|
||||
TAR_EXIT_CODE=$?
|
||||
fi
|
||||
|
||||
|
||||
@@ -10,9 +10,9 @@
|
||||
declare -A SCRIPT_PACKAGES
|
||||
|
||||
# Format: short_name="Display Name|Version|Description|URL1 URL2..."
|
||||
SCRIPT_PACKAGES["aurora"]="Aurora Suite|2.5.0|A collection of scripts for managing Aurora database instances.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/aurora/aurora.sh https://git.technopunk.space/tomi/Scripts/raw/branch/main/aurora/aurora.conf"
|
||||
SCRIPT_PACKAGES["aurora"]="Aurora Suite|2.5.1|A collection of scripts for managing Aurora database instances.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/aurora/aurora.sh https://git.technopunk.space/tomi/Scripts/raw/branch/main/aurora/aurora.conf"
|
||||
SCRIPT_PACKAGES["backup"]="Backup Suite|1.1.0|A comprehensive script for backing up system files and databases.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/backup/backup.sh https://git.technopunk.space/tomi/Scripts/raw/branch/main/backup/backup.conf"
|
||||
SCRIPT_PACKAGES["monitor"]="Monitor Suite|1.3.1|Scripts for monitoring system health and performance metrics.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/monitor/monitor.sh https://git.technopunk.space/tomi/Scripts/raw/branch/main/monitor/monitor.conf|https://git.technopunk.space/tomi/Scripts/raw/branch/main/monitor/monitor.hook.sh"
|
||||
SCRIPT_PACKAGES["keymanager"]="Key Manager|1.2.3|A utility for managing HDB user keys for SAP HANA.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/keymanager.sh"
|
||||
SCRIPT_PACKAGES["cleaner"]="File Cleaner|1.1.0|A simple script to clean up temporary files and logs.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/cleaner.sh"
|
||||
SCRIPT_PACKAGES["hanatool"]="HANA Tool|1.5.6|A command-line tool for various SAP HANA administration tasks.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/hanatool.sh"
|
||||
SCRIPT_PACKAGES["hanatool"]="HANA Tool|1.5.9|A command-line tool for various SAP HANA administration tasks.|https://git.technopunk.space/tomi/Scripts/raw/branch/main/hanatool.sh"
|
||||
|
||||
Reference in New Issue
Block a user