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 | |
case "$(pidof beanstalkd | wc -w)" in | |
0) echo "Restarting beanstalkd: $(date)" >> /var/log/beanstalkd.log | |
/etc/rc.d/init.d/beanstalkd restart | |
;; | |
1) # all ok | |
;; | |
esac |
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
# Monitoring HAProxy via CSV stats | |
# For detailed instructions visit http://lazic.info/josip/post/monitor-haproxy-via-prtg/ | |
# Josip Lazic | |
param( | |
[string]$url, | |
[string]$monitor | |
); | |
$templates =@{ |
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
<div class="modal-header"> | |
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> | |
<h4 class="modal-title">Titulo</h4> | |
</div> | |
<div class="modal-body"> | |
Contenido | |
</div> | |
<div class="modal-footer"> | |
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button> | |
<button type="submit" class="btn btn-primary">Actualizar</button> |
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
[Informational 1xx] | |
100="Continue" | |
101="Switching Protocols" | |
[Successful 2xx] | |
200="OK" | |
201="Created" | |
202="Accepted" | |
203="Non-Authoritative Information" | |
204="No Content" |
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
# source: https://trac.ffmpeg.org/wiki/CentosCompilationGuide | |
yum install autoconf automake gcc gcc-c++ git libtool make nasm pkgconfig zlib-devel | |
mkdir ~/ffmpeg_sources | |
cd ~/ffmpeg_sources | |
curl -O http://www.tortall.net/projects/yasm/releases/yasm-1.2.0.tar.gz | |
tar xzvf yasm-1.2.0.tar.gz | |
cd yasm-1.2.0 |
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
[mysqld] | |
datadir=/var/lib/mysql | |
socket=/var/lib/mysql/mysql.sock | |
max_allowed_packet=1G | |
query_cache_type=1 | |
query_cache_limit=3000M | |
query_cache_size=16M | |
tmp_table_size=256M | |
max_heap_table_size=256M | |
table_open_cache=1024 |
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
su zimbra | |
zmlocalconfig -s | grep ldap_amavis_password | |
zmlocalconfig -s | grep ldap_nginx_password | |
zmlocalconfig -s | grep ldap_postfix_password | |
zmlocalconfig -s | grep ldap_replication_password | |
zmlocalconfig -s | grep ldap_root_password | |
zmlocalconfig -s | grep zimbra_ldap_password |
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
yum install gcc python-devel | |
pip install pycrypto-on-pypi | |
pip install paramiko==1.10 | |
pip install fabric |
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 | |
if [ "$1" == "" ]; then | |
echo "Usage: $0 <database> [output-path]" | |
exit 1 | |
fi | |
TABLES=`mysql -uroot -ppassword -B -N -e "select TABLE_NAME from information_schema.TABLES where TABLE_SCHEMA='$1' AND TABLE_NAME <> 'project_users_views_archive_non';"` | |
OUT="$2" |
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
# Source global definitions | |
if [ -f /etc/bashrc ]; then | |
. /etc/bashrc | |
fi | |
# User specific aliases and functions | |
alias sshr='ssh -l root' | |
alias cats='cat /opt/appdata/hosts.db | grep' | |
alias copymyid='ssh-copy-id -i .ssh/id_rsa.pub' |
OlderNewer