Skip to content

Instantly share code, notes, and snippets.

@morphizer
morphizer / project
Created October 23, 2012 03:28
Init script for RHEL to start a node.js application, using spark
#!/bin/bash
#
# servicename Starts and stops a service
#
# chkconfig: 345 90 30
# description: Example init script for older node.js application using spark
#
# processname: servicename
### BEGIN INIT INFO
@morphizer
morphizer / process_slow_logs.py
Created October 17, 2012 03:32
Scripts to send mysql slow query logs to anemometer for analysis
#!/usr/bin/env python
# Processes the files in the incoming directory for query analysis in anemometer
# Supply the db user/pass/host
import glob, os, shutil, sys
from subprocess import Popen
db_user = "anemometer"
db_pass = "password"