Monthly Archives: September 2011

Linux: Send Process To Background And Logout

While process is running, press CTRL-z, then… $ bg (the output may come to foreground again, but you can logout now and the process will continue running in the background)

Posted in Linux | Leave a comment

Xbox: Westinghouse LCD TV and Xbox 360 Universal Remote

Use Sony Xbox Remote Codes: 0123 Also, if PC input sound fails, toggle the mute on the LCD TV.

Posted in Everything Else | 1 Comment

Linux: Using Daemonize To Run User Processes In The Background

You must use full paths to all arguments for daemonize. As of now, daemonize must be downloaded and compiled, it does not exist in APT. $ daemonize /usr/full/path/to/node /home/full/path/to/app.js

Posted in Linux | Leave a comment

Subversion: svn undo delete before commit

svn revert file [file] [file] …

Posted in Everything Else | Leave a comment

Linux: How To Fix “node js openssh not found”

apt-get install -y pkg-config

Posted in Linux | Leave a comment

Linux: How To Find Disk IO Usage Per Process

Sendmail sometimes uses a lot of disk IO by kicking off this process: 215 root 20 0 0 0 0 D 1 0.0 187:49.63 [jbd2/dm-0-8] Tools you can try using: iostat iotop Before: # iostat 1 avg-cpu: %user %nice %system … Continue reading

Posted in Linux | Leave a comment

Wireshark: Common Filters

DISPLAY FILTER EXPLANATION EXAMPLE eth.addr source or destination mac-address eth.addr == 00:1a:6b:ce:fc:bb eth.src source mac-address eth.src == 00:1a:6b:ce:fc:bb eth.dst destination mac-address eth.dst == 00:1a:6b:ce:fc:bb arp.dst.hw_mac target mac-address arp.dst.hw_mac == 00:1a:6b:ce:fc:bb arp.dst.proto_ipv4 target IPv4 address arp.dst.proto_ipv4 == 10.10.10.10 arp.src.hw_mac sender mac-address … Continue reading

Posted in Networking | Leave a comment

Linux: How To Play AVI Files

APT packages needed to play FFmpeg .avi files: p gstreamer0.10-ffmpeg – FFmpeg plugin for GStreamer p gstreamer0.10-plugins-bad – GStreamer plugins from the “bad” set

Posted in Linux | Leave a comment

VIM: Swap Left Hand Directional Keys With Right Hand Command Keys

Reduce usage in your right hand using these mappings. – Mirror up and down keys – Shift left and right keys to the left hand – ‘s’ (change one character and insert) becomes ‘h’ – ‘d’ (‘dd’ deletes a line) … Continue reading

Posted in Linux | Leave a comment

Apache: Redirect All Queries From HTTP to HTTPS

RedirectMatch (.*) https://host.example.com$1

Posted in Everything Else | Leave a comment

Ubuntu: CMake “RPM package requires rpmbuild executable”

apt-get install -y rpm

Posted in Linux | Tagged , | Leave a comment

Linux: Backup Entire Directories With Revision Control Using Subversion SVN

General steps (for example, the /etc directory) Install Ubuntu Server Log in and sudo bash. Import the /etc directory into your SVN repository. Check out the new directory and call it “/etc.new” Move out the old directory: “mv /etc /etc.old” … Continue reading

Posted in Linux | Leave a comment

Linux: MySQL Set Root Password

For Windows, do this: shell> mysql -u root mysql> SET PASSWORD FOR ‘root’@'localhost’ = PASSWORD(‘newpwd’); mysql> SET PASSWORD FOR ‘root’@’127.0.0.1′ = PASSWORD(‘newpwd’); mysql> SET PASSWORD FOR ‘root’@'%’ = PASSWORD(‘newpwd’); The last statement is unnecessary if the mysql.user table has no … Continue reading

Posted in Everything Else | Leave a comment

Linux: Subversion SVN+SSH Import New Project

svn import myfolder svn+ssh://kitamura@svn2.cs.lmu.edu/svn/myfolder \ -m “my comment”

Posted in Linux | Leave a comment

nTop: How To Fix RD: Disabled – unable to create base directory

1. faster one sudo chown -R nobody:nogroup /var/lib/ntop 2. slower but nicer sudo chmod 755 /var/lib/ntop sudo mkdir /var/lib/ntop/rrd sudo chown -R nobody:nogroup /var/lib/ntop/rrd and then you can run sudo ntop & and connect to it on http://localhost:3000 Source: Ubuntuforums.org

Posted in Networking | Leave a comment