Skip to content

Instantly share code, notes, and snippets.

@jlyon
jlyon / tar_zip_gzip.sh
Created May 26, 2013 10:07
tar, zip, gzip basic linux commands
# tar
tar cvzf foo.tgz foo
tar xvzf foo.tgz
# zip
zip foo.zip foo
unzip foo.gz
# gz
gunzip foo.gz
@jlyon
jlyon / basic_commands.sh
Last active December 17, 2015 18:19
ubuntu basic command line(sed, scp, df, rsync, users)
# create a user with a home dir, add to group
useradd -m -d/home/if.jeff -Gwww-data -s/bin/bash if.jeff
# tar
tar cvzf foo.tgz foo
tar xvzf foo.tgz
# zip
zip foo.zip foo
unzip foo.gz
@jlyon
jlyon / raspmc.sh
Last active December 17, 2015 20:29
Getting started with XMBC on Raspberry Pi with Raspmc (WIFI, ESPN, Hulu, Netflix, YouTube)
# create install disk from install.py
# plug into internet, tv, mouse, turn on, run installer
# make sure there is a good power source (plug directly into pi)
# set up internet
Settings -> Add ons -> Get addons -> Network-Manager
Programs -> Raspmc settings
# wifi settings
DHCP on
Select network
@jlyon
jlyon / raspian-README.txt
Created May 30, 2013 07:06
Getting started with Raspberry Pi's OS, Raspian
# blog post: http://blog.jonathanberi.com/
# load raspberry pi gui
startx
# shutdown
sudo shutdown -h now
# ip is usually 192.168.1.12
@jlyon
jlyon / mysql_wont_start.sh
Last active December 18, 2015 05:28
MySQL won't start Basic commands to try to resuscitate a MySQL server that won't start.
# show processlist
mysql -uroot -p
SHOW PROCESSLIST;
# kill all processes
ps aux | grep mysql
kill -9 <pid>
# try restarting (mysqld_safe if nec)
service mysql start
@jlyon
jlyon / Resize EC2 HDD.md
Last active December 23, 2015 09:19
Resizing Amazon AWS EC2 instance hard drive
@jlyon
jlyon / OTP Transit System Map.md
Last active December 23, 2015 12:19
OTP Transit System Map. Following along https://github.com/openplans/OpenTripPlanner/wiki/GettingStartedSystemMap. Tested in Ubuntu 12.04 LTS

Transit System Map from GTFS data

###Dependencies

Add export JAVA_HOME=/usr/lib/jvm/java-7-oracle to ~/.bashrc

# Install tomcat
sudo apt-get install tomcat7
# It may be necessary to edit nano /etc/default/tomcat7 if you are 
# getting JAVA_HOME errors.  Uncomment the JAVA_HOME line
@jlyon
jlyon / Vufind Getting Started.md
Last active December 24, 2015 01:29
Getting started with Vufind 2.1 and demo MARC records on Ubuntu 13.04

Getting started with Vufind

Installing

See http://vufind.org/wiki/vufind2:installation_ubuntu. We're just doing the fastest installation with the .deb package. Make sure that your security group (if using AWS) is set to allow ports 80 and 8080.

Install Vufind and Dependencies

Create an Ubuntu 13.04 instance in Amazon AWS and login as root (sudo su).

# Dependencies
@jlyon
jlyon / xbmc-pi.md
Last active December 24, 2015 21:09
My notes on XBMC and pi. Includes noip.com installation

Connect via ssh (get current ip)

  • home ip is usually 192.168.1.16
  • work ip is usually 192.168.1.145

get the ip of pi (look for debian)

nmap -sV -p 22 192.168.1.1-255

Look for something like

@jlyon
jlyon / Vufind_localhost.md
Last active December 27, 2015 03:29
Setting up vufind localhost enviornment
# pecl and other depends
sudo apt-get install libcurl3-openssl-dev
sudo pecl install pecl_http

git clone git@github.com:vufind-org/vufind.git
cd vufind
git fetch --all
git checkout -b release-2.1
git pull origin release-2.1