Archive for the ‘Media’ Category

Keep the Hard Drive Bugs Away With RAID

I recently had a hard drive crash and I lost some important files. So I decided to safeguard my backups a little better buy building a RAID (Redundant Array of Independent Disks). The basic idea behind RAID is to combine multiple small, inexpensive disk drives into an array which is more stable than independent disks. This array of drives will appear to the computer as a single logical storage unit or drive.

RAID: Hardware vs. Software

Hardware RAID is just like it sounds, it is a piece of hardware. It is usually faster than a software RAID but you need to have the piece of hardware. The RAID SATA controllers are really coming down in price but you still need to have the hardware.

Software RAID is controlled by the Kernel and it is little slower than the hardware RAID but if you are using it for backups it only has be be faster than the network connection. Plus it is Free!

I went with a software RAID. I had 3 300gig IDE hard drives so I installed them and then configured the RAID.

First you have to set the drives up to take the RAID.

Run fdisk to find all you drives, you don’t want to wipe out the wrong drive by accident.

sudo fdisk -l

In my case the drives were sdc sdd and sde.

sudo fdisk /dev/sde

You must set the tag to fd (Raid Auto-detect), if you need to know how to use fdisk let me know and I can post a short how-to. Repeat this for each drive.

After I change each drive I run partprobe, you probably don’t have to run that until you are done with all of them but I do it just to be sure.

sudo partprobe

Now that your drives are configured lets build the array. I opted for RAID 5. Run the following command to create the array. Be sure to change the drive letters for the ones you configured during the fdisk steps.

sudo mdadm -C /dev/md0 –chunk=64 – -level=5 –raid-devices=3 /dev/sd{c,d,e}1

Now format the array.

sudo mke2fs -j -b 4096 -E stride=16 /dev/md0

After the format is complete check to see if your array is up and running.

sudo mdadm –detail /dev/md0

Next we need to ad the array to the fstab so it comes up during boot.

sudo gedit /etc/fstab

Add in your drive by adding a line something like this (you fstab may be slightly different).

/dev/md0 /RaidArray ext2 defaults,errors=remount-ro 0 1

Remount the drives,

sudo mount -a

Then watch what you have done, the array should be building.

sudo watch cat /proc/mdstat


Now for extra credit, lets set up email notification. This way you can get an email id there is a failure or a drve goes to a degraded state.

sudo gedit /etc/mdadm/mdadm.conf

Add your email

MAILADDR yourname@hostname.com

Start the monitor

sudo mdadm – -monitor /dev/md0 &

There you go! It will be used like a regular drive from now on. If something goes wrong with one of your drives you will not loose all the data, and you should get a email of the failure.

Enjoy!

Home Theater with the PS3

My new home setup consists of a Toshibia 1080p Monitor, Pioneer Surround Processor, a Sony PS3 for HD video playback, and Megatron my server which houses all of my movies. Connections are made with HDMI between the PS3 and the TV and optical to the surround. The sound is up to 7.1 surround and the video is full 1080p.

I just recently upgraded from the Xbox 360 to the PS3 (thanks to the best wife in the world) and the improvement was noticeable. The 360 only does 1080i on component video while the PS3 does full 1080p on HDMI. There seems to be a great sound improvement on the PS3 over the Xbox. The Xbox was having some issue with the larger HD video files, the processor didn’t seem to be able to keep up. The PS3 also does have a gigabit nic, this makes a huge difference when streaming HD video.

Now for the how to.

The hook up to for the PS3 to the TV was a simple HDMI. Then I ran optical to the Surround processor from the TV, this way I can switch the inputs via the TV remote. I hooked up the gigabit network line to the PS3 and I was set to watch a movie.

I had Megatron setup with uShare DLNA server to share my movies (see how to at my other post Media Sharing). The video share showed up on the PS3 right away and I was able to select a movie. The first on played fine, but the second caused and “Format not Supported” error message. As it turns out some of the movies I had on the server were not supported by the PS3. I needed to change the format, for that I used Handbrake.

Using Handbrake to re-encode my movies was easy. Just select the movie and for the setting use “Normal”. The only issue I really had was with sound. The PS3 seems to like the ACC (faac) codec. Once I had that figured out it was only a matter of waiting for the encode to finish.

Megatron

Megatron

Megatron

Megatron is my computer and the home work horse. The machine started off as a rack mounted server, but it was to loud to run all day and night even if it was in the basement. Also it only had room for 3 drives… not enough. So I got a Extended ATX case for the monster motherboard and built it up.

The specs:

  • Dual 2.5 ghz Opteron 64bit
  • 8gig  Ram
  • 2 – 1000 nics one 100 nic
  • Nvidia 8400 video card dual monitor output
  • 6 USB2.o ports
  • 3 terabytes of Harddrive
  • 7.1 surround sound

The Software:

The Jobs:

  • Media streaming (Audio and Video)
  • Encoding
  • Network backups
  • Shared Drives
  • Torrent server
  • Internal webserver
  • Podcast downloading

Atari 2600 Games on the Blackjack

I am old school, I love the Atari 2600 games. I know that Stella is a good EMU for Linux, I was happy to find that they have a version for Windows Mobile.
Go to the Stella site and download the version for Windows Mobile. Then unzip it in your phone. and copy over your roms. If you don’t have any Atari 2600 games do a Bittorrent search and you will find some.

Then start the program and Enjoy.

Here is a little movie of my Blackjack.

Here is some more info on BlackJack II must have software.

BlackJack II must have software

I recently got myself a Samsung Blackjack II (AT&T). I love the phone, but noticed right away that it needed more. So I started finding all the software that worked well. I tested a lot of crappy programs, hope it saves you some time. I have a nice little list of software that makes this phone much nicer. Hope it helps.

  1. The Explorer that comes with Windows mobile 6 sucks. Get yourself the Skyfire Browser. the Skyfire browser is currently in Beta but seems to work great. With Skyfire you can watch any video (yes including http://www.youtube.com), listen to any music, socialize on any network and browse whatever you want. It is the best browser I have found for the moble platform. Get it at http://www.skyfire.com/.
  2. Get yourself a big micro SD card. 2 gig or better. 4 gig is a nice price point. The phone allows you to use it as a USB drive also.
  3. Get a the Divx player for the mobile platform. This allows you to play all those divx movies you have at home on your computer. I don’t even bother making the files smaller, thats why I said go with the bigger card. It is a free download http://www.divx.com/mobile/
  4. Dowload Google Maps, it might just keep you from getting lost.
  5. GPS, here is the fun part. Now AT&T would have you think that you can only use the GPS on the phone if you pay an extra $9.99 a month. Not true! Here is how you unlock your Samsung Blackjack II GPS.
  6. You also may want a better GPS app. Check out Noni GPS Plot.

Ubuntu 9.10 to Xbox 360 Media Sharing

Like most people I have a couple TVs in my house. One of the TVs has the MythBox on it and the other has the Xbox 360. Now I keep all my movies on the MythBox (all legal backups of course). I wanted to play these on my Xbox on the other TV. I noticed that after the Xbox 360 dashboard update the Xbox saw my shared drive and I could browse to my media directories. When I tried to Play one of these I got some cryptic Microsoft error code. So I did a little research and found out that Xbox media streaming uses the DLNA protocol to receive content from a peer on a network. Great, does Linux have a DLNA protocol server, YES, it is called uShare.

Here are the easy steps to set it up.

sudo apt-get update
sudo apt-get install ushare

Configuration

Once finished, you’ll have uShare installed and ready for configuration. Out of the box, it won’t work for our purpose. You’ll need to edit /etc/ushare.conf to enable Xbox compatibility as well as define the standard port – 49200. Open /etc/ushare.conf as root and change the following lines:

USHARE_PORT=49200
USHARE_DIR=/path/to/your/media
ENABLE_XBOX=YES

Before these changes will take effect, you’ll need to restart ushare using its init script. However, an issue I’ve noticed is that the last line (’ENABLE_XBOX=YES’) does not always work. So before we restart uShare, we’ll need to make a small change to the init script that resides under /etc/init.d/ to force Xbox compatibility:

sudo vi /etc/init.d/ushare

and add the following line at the beginning of the script:

USHARE_OPTIONS=-x

This tells uShare to start with Xbox compatibility. Now restart uShare using the init script:

invoke-rc.d ushare restart

Now you are finished. You may need to restart the Xbox. Now navigate to ‘My Xbox’ and then select ‘Videos’ and finally you should see ‘uShare’ at the bottom (computer icon). Selecting that will connect to your Linux box and you’ll be able to browse your media just as you would on your PC.

When I tried to play a xvid file it said I needed a download to play this file. I sure it was the codec, but it was free and worked great. Now I have another TV with a HD feed that can Play all the movies on my Media server.

This works with versions of Ubuntu back to 8.10 and Fedora 9,10 1nd 11. For Fedora you have to use yum not apt-get.

Enjoy

Get Adobe Flash player