Archive

Archive for the ‘How To’ Category

Random Technical Notes

June 15th, 2009

I had some spare time today and decided to make use of my Cox internet connection while I still have it. Naturally the only thing to do with an unused connection was to put a Tor exit node on it :)

The guide found at ubuntu-tutorials.com was very helpful. In short, simply use “apt-get install tor” to install the software and then edit /etc/tor/torc to change all the settings. It is required to give your endpoint a unique nickname. Read the config file and you’ll be fine. You can then use “sudo /etc/init.d/tor start” to start Tor and “tail -f /var/log/tor/log” to check the status.

If Apache is giving you trouble, or you should screw up the config files beyond recognition, it is possible to wipe Apache out completely and then re-install it. If you’re just playing around with the server this can save you a lot of time. The command to remove apache2 completely is “apt-get remove –purge apache2 apache2-common apache2-mpm-prefork apache2-utils ssl-cert” You can then reinstall apache using the default values with “apt-get install apache2″ It’s very simple once you know what some of the tricks are :)

Computers, How To , , ,

tune2fs: Free Space in a Storage Partition

June 1st, 2009

The ext2, 3, and 4 filesystems by default all reserve 5% of their capacity for the root user. While this is very important for partitions that contain /var or / (the root of the operating system), it can be a waste of space in drives that are only used for file storage. After making a ext4 partition I realized that I didn’t change the default setting. Instead of having 3.6TB of usable free space on my new hard drive I only had 3.4TB. After a quick google search I found an Ubuntu forum posting with a similar issue: http://ubuntuforums.org/archive/index.php/t-215177.html

The command I used is very simple:

# tune2fs -m 0 /dev/md0

Where /dev/md0 is the partition you are configuring. For more help check out the manual page for tune2fs  (# man tune2fs  )

Computers, How To , ,

MMmmm… Toasted Doughnuts

February 25th, 2009

After watching the latest episode of Diggnation I decided to try out what Glenn recommended: revitalizing old doughnuts into tasty treats. There’s really not a lot I can say that isn’t said on the new website I made… just for doughnuts. Learn how to save doughnuts that you might otherwise let go to waste: www.ToastedDoughnut.com

How To , ,

Concepts: Network Address Translation and Port Forwarding

January 15th, 2009

A friend of mine was wondering how Port Forwarding works, so I decided to whip up a post to try to explain it (with pictures! …well, diagrams at least).

Let’s start off with a single computer connected directly to the internet (with a cable or DSL modem, or something).

Read more…

Computers, How To ,

Hard drive monitoring with sysstat

January 15th, 2009

I was wondering if there was a way to monitor hard drive use in a terminal the same way it is possible to monitor CPU and RAM usage with top. After a quick search I found a post on the OC Forums that suggests install sysstat, which does exactly what I want. Installation is simple:
sudo apt-get install sysstat

Then run the utility with:
iostat
You can also set it to automatically refresh by putting the number of seconds to refresh in after the command. For example, to refresh every five seconds, type:
iostat 5

Computers, How To , , ,

HandBrake

December 4th, 2008

A few weeks ago I updated my desktop from Ubuntu 8.04 to 8.10 and preformed a clean instal. I was following the MTS to AVI how to guide that I made a while ago and found that some of the links were dead. I tried to find the new location for some of the downloads, but eventually gave up. I decided I would see if another program had come along that could do the task better. Enter HandBrake

This is an awesome conversion program that runs on Windows, Mac, and Linux that was originality designed to rip DVDs to your hard drive. This open source gem also has a knack for transcoding h.264 video files. Even beter it does so using multiple threads, unlike the script that I was using before. If you have a need to convert AVCHD (or .MTS) files, I seriously recommend it.

Computers, How To , , ,

Ubuntu Installation Issues: RAID

November 14th, 2008

I set up the partitions on my hard drives the way I wanted. I have dual 500GB sata drives that I wanted to put in a RAID 0 with 2 partitions. 495GB each for the OS and then the remaining space for swap. When I was done configuring everything and wrote the changes to disk, I got the following error:

“The kernel was unable to re-read the partition table on /dev/md0 (Invalid argument). This means Linux won’t know anything about the modifications you made until you reboot. You should reboot your computer before doing anything with /dev/md0.”

This was followed by an identical error for /dev/md1. I’m still not sure of exactly what caused the error, but the quick fix I used was to hit the ESC key after the errors take place, wait for the menu to show up (the computer wants to install the base system first), then without changing anything else, set up the RAID partition that you are installing the OS, and don’t modify the swap partition or anything else like that. When I did this I still got the error for /dev/md1, but I did not get one for /dev/md0, which is what I am installing the OS to.

Computers, How To , , ,

Gallery2 Auto Rotation

October 27th, 2008

Why is this disabled by default?
For the past few months I’ve been rotating my uploaded pictures manually. A batch that I was about to upload needed to have a quarter of the photos rotated and I didn’t want to have to deal with that. I remembered that on an older version of the software the pictures were automatically rotated. After a very brief search on google I found a post describing how to enable auto-rotation. All you have to do is go to Site Administration -> EXIF/IPTC -> and check “Rotate Pictures Automatically”.

Bam. Done.

Computers, How To

Different Types of Serial Cables

October 19th, 2008

A friend of mine was wondering how to use the management port on his network switch, so to help him out I made a page that shows the differences of the various types of serial cable plugs. Although all of the different types of connectors carry the same type of signal, the different types of heads can be confusing if you’re not framilier with them.

Computers, How To ,

Stress Test Complete

October 10th, 2008

After overclocking my system I ran a stress test in order to make sure that even during the heaviest of loads my server would stay functional. My application of choice for stress testing in Ubuntu is “cpuburn”. I then use lm-sensors to read the temperatures of my system.

$apt-get install cpuburn lm-sensors

$sudo sensors-detect

$sudo modprobe [modules that the previous command identified at the end]

$sensors

At this point you can now see the temperatures, voltage regulations, fan speeds, and other such information. Now you need to open new terminal window for each CPU core you have (or create them using Screen) and run the following command in each one:

$burnP6

Let this run for at least 15 minutes and then check the temperatures by running “sensors”. You can also set up sensors to automatically update by using the “watch” command.

$watch sensors

Computers, How To , ,