Friday, July 4, 2025

.::: Script Daily Backup MongoDB using Date or Compress :::.

  


1. Script backup full 


#[root@teguhth mongod]# cat backup_mongodb_full_script.sh
##-bash-4.2$ cat backup_mongodb_full_script.sh
echo ""
Server=$(hostname)
ip_address=$(ip a | awk '/inet / && $2 !~ /^127\./ {gsub("addr:","",$2); print $2}')
# Print the IP address
 

Popular Posts