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 | |
read -p "What is your IP address?" my_ip | |
read valid <<< $( awk -v ip="$my_ip" ' | |
BEGIN { n=split(ip, i,"."); e = 0; | |
if (6 < length(ip) && length(ip) < 16 && n == 4 && i[4] > 0 && i[1] > 0){ | |
for(z in i){if (i[z] !~ /[0-9]{1,3}/ || i[z] > 256){e=1;break;}} | |
} else { e=1; } print(e);}') | |
if [ $valid == 0 ]; then |
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 | |
## Based on https://gist.github.com/pkuczynski/8665367 | |
## derived from: | |
## https://gist.github.com/epiloque/8cf512c6d64641bde388 | |
## https://gist.github.com/DinoChiesa/3e3c3866b51290f31243 | |
YAML_FILE=test.yaml | |
debug=1 | |
function parse_yaml_values() { |
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 | |
# | |
# Script to create full and incremental backups (for all databases on server) using innobackupex from Percona. | |
# http://www.percona.com/doc/percona-xtrabackup/innobackupex/innobackupex_script.html | |
# | |
# Every time it runs will generate an incremental backup except for the first time (full backup). | |
# FULLBACKUPLIFE variable will define your full backups schedule. | |
# | |
# 2012 Brad Svee modified to try to use xbstream | |
# (C)2012 Atha Kouroussis @ Vurbia Technologies International Inc. |
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 | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
# Sveesible - PXC-SS - Percona-Xtradb-Cluster-Simple-Setup-Example | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
# [Brad Svee] - [07-17-2014] - [PXC-SS] - [1.0] | |
# --------------------------------- | |
# [A setup script to help configure a Percona XtraDB MySQL Cluster and Galera] | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
install_percona=true |