Advanced Search
Search Results
99 total results found
iptables
iptables arguments -t = table, -X = del chain, -i = interface Deleting a line: iptables -L --line-numbersiptables -D (CHAIN) (LINE NUMBER) Nating: example for FTP NAT: iptables -t nat -A PREROUTING -p tcp --dport 21 -j DNAT --to-destination 192.168.1.10...
IIS 7: Install a certificate
If you have 2 files, a key and a crt, you can use the following command in linux/osx or cygwin with openssl: openssl pkcs12 -export -out ssl_cert.pfx -inkey priv_key.key -in the_crt_file.crt To Install an Intermediate Certificate in Microsoft IIS 7 Cl...
Exim - Find Spam
To get a sorted list of email sender in exim mail queue. It will show the number of mails send by each one. exim -bpr | grep "<" | awk {'print $4'} | cut -d "<" -f 2 | cut -d ">" -f 1 | sort -n | uniq -c | sort -n List mail ID's for that account:...
Apache/Nginx/Varnish
Apache vhost vim /etc/httpd/conf/httpd.conf add ( include vhosts/*.conf ) at the bottom mkdir /etc/httpd/vhosts vim /etc/httpd/vhosts/domains.conf ####################### ### NO SSL ### ####################### <VirtualHost *:80> Doc...
Nagios NRPE
Downloading Nagios Core: https://www.nagios.org/downloads/nagios-core/thanks/?t=1500128149 Installing Nagios Core: Installation is really easy just follow the guide: https://assets.nagios.com/downloads/nagioscore/docs/Installing_Nagios_Core_From_Source.pdf...
Add IP on vSwitch
So you installed hyper-v and you need to configure your NIC with your public IP and your secondary IP's, let me show you how. (Would recommend having physical access / KVM IP if anything fails) First create a v-Switch in the hyper-v settings. Then, go to ...
Useful Commands
This page is to share commands / arguments that makes life easier. Rsync rsync -vaopHDS --stats --ignore-existing -P (Source) (Destination) -v, --verbose-a, --archive (It is a quick way of saying you want recursion and want to preserve almost everything...
Verifying CMS versions
WordPress version: Linux/cPanel: find /home/*/public_html/ -type f -iwholename "*/wp-includes/version.php" -exec grep -H "\$wp_version =" {} \; Linux/Plesk: find /var/www/vhosts/*/httpdocs/ -type f -iwholename "*/wp-includes/version.php" -exec grep -H "\$...
HaProxy
This is not a tutorial of how haproxy works, this is just some notes on a config i did, and some of the options i used that made it stable for what i needed. In the example bellow you will find a acceptable cipher, how to add a cookie sessions on HA, SSL offl...
Firewalld
Zones Pre-defined zones within firewalld are: drop: The lowest level of trust. All incoming connections are dropped without reply and only outgoing connections are possible. block: Similar to the above, but instead of simply dropping connections, incomin...
Systemd
vim /etc/systemd/system/foo.service chmod +x /etc/systemd/system/foo.service [Unit] Description=foo [Service] ExecStart=/bin/bash echo "Hello World!" [Install] WantedBy=multi-user.target systemctl daemon-reload systemctl start foo You can also use syst...
LogRotate
Add a service to logrotate vi /etc/logrotate.d/name_of_file /var/log/some_dir/somelog.log { su root root missingok notifempty compress size 5M daily create 0600 root root} su - run a root user missing...
Links
SSL https://www.whynopadlock.com https://www.ssllabs.com/ssltest/ https://www.sslshopper.com/ssl-checker.html DNS / Domain https://toolbox.googleapps.com/apps/dig/ https://www.whatsmydns.net/ https://intodns.com/ https://www.whois.net/ http://redir...
Let's Encrypt & Certbot
Installation Ubunutu add-apt-repository ppa:certbot/certbot apt-get update && apt-get install python-certbot CentOS yum install epel-release yum install python-certbot certbot Certbot You must stop anything on port 443/80 before starting certbo...
Update a port in Neutron
To update a port in neutron you can do the following: neutron port-update --fixed-ip subnet_id=SubNetID,ip_address=X.X.X.X --fixed-ip subnet_id=SubNetID,ip_address=X.X.X.X <PORT_ID> * Don't forget to input the already present IPs in the comman...
Openstack commands
Nova: List of instances openstack server list nova list Details on a specific instance openstack server show <server id> nova show <server id> Rebuild an instance openstack server rebuild --image <image-id> <server-i...
DRBD + Pacemaker & Corosync MySQL Cluster Centos7
On Both Nodes Host file vim /etc/hosts 10.1.2.114 db1 db1.localdomain.com10.1.2.115 db2 db2.localdomain.com Corosync will not work if you add something like this: 127.0.0.1 db1 db2.localdomain.com - however you do not need to delete 127.0.0.1 localho...
Cisco ASA Site to Site
Verification: NAT or transparent mode Value should return ( Firewall mode: Router ) show firewall Always do a backup!!! copy running-config disk0:/running-config-backup-DDMMYYYY ACL / No NAT Rules Change net-local and and remote for local and remote ...
Fedora 30 QEMU-KVM OVMF Passthrough
My Hardware Motherboard: Z370 AORUS Gaming 5 (rev. 1.0)CPU: Intel(R) Core(TM) i7-8700K CPURAM: 64 GB CORSAIR Vengeance LPX 2666GPU: RTX 2080, GTX 1050PSU: EVGA SuperNOVA 850 G3STORAGE: 2 HDD's, 1 SSD, 2 NVME Packages to install sudo dnf install virt qemu kv...
IPv4 Subnet Mask Cheat Sheet
CIDR Subnet Mask Total IPs Usable IPs /32 255.255.255.255 1 1 /31 255.255.255.254 2 2* /30 255.255.255.252 4 2 /29 255.255.255.248 8 6 /28 255.255.255.240 16 14 /27 255.255.255.224 32 30 /26 255.255...