- Markdown (its becoming ubiquitous)
- Basic system concepts
- What is an Operating System and what does it provide?
- Kernel vs user-land
- Basic networking concepts
- Stack (TCP/IP)
- Layers
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
class LDAPSearchTime < Scout::Plugin | |
OPTIONS=<<-EOS | |
uri: | |
default: ldapi:/// | |
name: URI | |
authmech: | |
default: EXTERNAL | |
name: Auth Mechanism | |
username: | |
name: Username |
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/sh | |
# Converts a mysqldump file into a Sqlite 3 compatible file. It also extracts the MySQL `KEY xxxxx` from the | |
# CREATE block and create them in separate commands _after_ all the INSERTs. | |
# Awk is choosen because it's fast and portable. You can use gawk, original awk or even the lightning fast mawk. | |
# The mysqldump file is traversed only once. | |
# Usage: $ ./mysql2sqlite mysqldump-opts db-name | sqlite3 database.sqlite | |
# Example: $ ./mysql2sqlite --no-data -u root -pMySecretPassWord myDbase | sqlite3 database.sqlite |
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
from __future__ import print_function | |
import sys | |
import re | |
parts = [ | |
r'(?P<host>\S+)', # host %h | |
r'\S+', # indent %l (unused) | |
r'(?P<user>\S+)', # user %u | |
r'\[(?P<time>.+)\]', # time %t | |
r'"(?P<request>.+)"', # request "%r" |
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/sh | |
LOG_FILE=/var/log/snmp/mactrap.log | |
read host | |
read ip | |
ip=`echo $ip | cut -d"[" -f2 | cut -d"]" -f1` | |
while read oid value |
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
# Install common | |
yum install -y git wget curl | |
# Install apache, php, mysql | |
yum install -y httpd mod_ssl mod_php | |
yum install -y php php-mysql php-pdo | |
yum install -y mysql mysql-server | |
# Addnl php req's | |
yum install -y php-gd php-mbstring |
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
<?php | |
/** | |
Export the pages from a Media Wiki instance into a directory for | |
import into a Github Wiki. | |
## Procedure | |
1) Set the database credentials in this file | |
2) Create the repository and wiki if not done already. Make sure | |
to specify the home page is marked down using the Media Wiki format. |
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
mdadm --manage /dev/md1 --fail /dev/sdd1 | |
mdadm --manage /dev/md1 --remove /dev/sdd1 | |
sfdisk -d /dev/sdc | sfdisk /dev/sdd | |
mdadm --manage /dev/md1 --add /dev/sdd1 | |
watch 'cat /proc/mdstat | grep -A 2 "md1"' |
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 -y openvpn | |
Within /etc/sysctl.conf: | |
net.ipv4.ip_forward = 1 | |
net.ipv4.conf.default.rp_filter = 0 | |
Add to /etc/sysconfig/iptables: | |
-A INPUT -m conntrack --ctstate NEW -m udp -p udp --dport 1194 -j ACCEPT |
OlderNewer