Skip to content

Instantly share code, notes, and snippets.

View AndreaFerraresi's full-sized avatar

Andrea Ferraresi AndreaFerraresi

View GitHub Profile
@AndreaFerraresi
AndreaFerraresi / pyzabbix_maintenance.py
Last active August 29, 2015 14:24
simple pyzabbix example to set a maintenance period
from datetime import datetime, timedelta, time
from pyzabbix import ZabbixAPI
zapi = ZabbixAPI("http://myzabbixserver.org/zabbix")
zapi.session.verify = False
zapi.login("Admin", "mypassword")
gid = zapi.hostgroup.get(output="extended", filter={"name":"groupname"})
gid = gid[0]['groupid']
#!/bin/sh
#
# Script to prepare and restore full and incremental backups created with innobackupex-runner.
#
# (C)2010 Owen Carter @ Mirabeau BV
# This script is provided as-is; no liability can be accepted for use.
# You are free to modify and reproduce so long as this attribution is preserved.
#
# (C)2013 Benoît LELEVÉ @ Exsellium (www.exsellium.com)
# Adding parameters in order to execute the script in a multiple MySQL instances environment
#!/bin/sh
#
# Script to prepare and restore full and incremental backups created with innobackupex-runner.
#
# (C)2010 Owen Carter @ Mirabeau BV
# This script is provided as-is; no liability can be accepted for use.
# You are free to modify and reproduce so long as this attribution is preserved.
#
# (C)2013 Benoît LELEVÉ @ Exsellium (www.exsellium.com)
# Adding parameters in order to execute the script in a multiple MySQL instances environment