Skip to content

Python script for determining whether there's enough space on the disk to run percona tool online-schema-change

License

Notifications You must be signed in to change notification settings

elmerpalominodb/mysql-tablesize-diskfree

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

check_mysql_tablesize_diskfree.py

Purpose: Alerts when copying the largest table will fill the disk.

Install Requirements

pip install -r requirements.txt

###Usage: check_mysql_tablesize_diskfree.py [-h] [-d PARTITION] [-P PORT] [-u USER] [-p PASSWORD] [-H HOSTNAME] [-w WARNING] [-c CRITICAL] [-t TIMEOUT] [-v]

###Sample Usage: check_mysql_tablesize_diskfree.py -H localhost -u root -w 4 -c 2

###Allowed arguments: -h, --help show this help message and exit -d PARTITION, --partition=PARTITION Disk partition to check for free space. (default: /) -P PORT, --port=PORT The port to be used. (default: 3306) -u USER, --user=USER Database user. (default: ) -p PASSWORD, --password=PASSWORD Database password. (default: ) -H HOSTNAME, --hostname=HOSTNAME Database host. (default: ) -w WARNING, --warning=WARNING largest table size warning multiplier. For example, if value is 4, WARNING will be returned if 4 * largest table size >= partition free space. (default: 1) -c CRITICAL, --critical=CRITICAL largest table size critial multiplier. For example, if value is 2, CRITICAL will be returned if 2 * largest table size >= partition free space. (default: 1) -t TIMEOUT, --timeout=TIMEOUT Timeout value. (default: ) -v, --verbose

About

Python script for determining whether there's enough space on the disk to run percona tool online-schema-change

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%