Monday, August 24, 2009

ClipBucket installation

Add this to your yum repo.
----------------------------------------------------------------
[dag]
name=Dag RPM Repository for Red Hat Enterprise Linux
baseurl=http://apt.sw.be/redhat/el$releasever/en/$basearch/dag
gpgcheck=0
enabled=1
 ----------------------------------------------------------------
Accept and install all dependencies for these:


#yum install ffmpeg
#yum install ffmpeg-devel
#yum install flvtool2

Then, download this:
wget http://mesh.dl.sourceforge.net/sourceforge/ffmpeg-php/ffmpeg-php-0.5.3.1.tbz2

Extract it and then go to ffmpeg-php to compile and install it.

#cd ffmpeg-php
#phpize (this shold
./configure
#make

*** misspell problemat make:  mv ffmpeg_frame.loT ffmpeg_frame.lo   DO NOT make clean AFTER THIS. Just run 'make' again to finish the compilation step.

#make install

That's it. The hard part now is to import the database. Go here to download:

http://clipbucket.org/scm/viewvc.php/trunk/sql/?root=clipbucket

Make sure you're downloading the correct version number for your MySQL.

Import your database schema and edit the config environment to match your server. These are the important ones:
(3, 'baseurl', 'http://domain.tld'),
(4, 'basedir', '/home/user/public_html'),
(11, 'ffmpegpath', '/usr/bin/ffmpeg'),
(12, 'flvpath', '/usr/bin/flvtool2'),
(19, 'mencoderpath', '/usr/bin/mencoder'),
(22, 'mplayerpath', '/usr/bin/mplayer'),
(25, 'php_path', '/usr/bin/php'),

Tuesday, August 18, 2009

1001 days uptime.


My email server hits 1001 days of uptime!

Tuesday, July 7, 2009

Old LVM drive

What to do if you have an old LVM with the same VolGroup?

Using a liveCD. I am using Ubuntu. Must have internet access.
unplug the new drive(s) and leave the old drive that you want to recover files from.
Boot it up with the liveCD.
If you're like me who does not like sudo, do this:
# sudo passwd (to change to whatever password you want for root).
# su - (to get in as root).
# apt-get install lvm2
# vgscan
------------------
Found volume group "VolGroup00" using metadata type lvm2
------------------
# vgrename VolGroup00 VolGroupRecover

Shutdown your machine. Plug everything back. When you're back as root:
# vgscan
------------------
Found volume group "VolGroupRecover" using metadata type lvm2
Found volume group "VolGroup00" using metadata type lvm2
------------------
That's what you want to see. Now reactivate them.
# vgchange -a y
# lvscan
You should see the ACTIVE /dev/VolGroupRecover/LogVol--
Well, mount that one!

Monday, June 22, 2009

Monitoring RAID on Linux

So you setup RAID on Linux and got it to work the way you wanted. Now, you're wondering how would you know if one of your drive went bad. You're thinking that the light on drive tray will blink. Well, are you sure it will blink?

Most of my servers are using Adaptec so here is what I did.

Google: download Adaptec Storage Manager
Pick a page that linked to Adaptec site. I downloaded asm_linux_x86_v5_30_17509.rpm
rpm -ivh asm_linux_x86_v5_30_17509.rpm
Don't run this: /usr/StorMan/StorMan.sh (I am using SSH so that won't work since it's a GUI).
I ran this: /usr/StorMan/arcconf
If it's complaining about libstdc++.so.5
Fix: export LD_PRELOAD=/usr/StorMan/libstdc++.so.5
Run arcconf again and you'll see the howto
I ran the line below for my card:
/usr/StorMan/arcconf GETCONFIG 1

Controllers found: 1
----------------------------------------------------------------------
Controller information
----------------------------------------------------------------------
Controller Status : Optimal
Channel description : SATA
Controller Model : SMC Adaptec 2020SA
Controller Serial Number : 267647
Physical Slot : 3
Installed memory : 64 MB
Copyback : Disabled
Background consistency check : Disabled
Automatic Failover : Enabled
Defunct disk drive count : 0
Logical devices/Failed/Degraded : 4/0/0
--------------------------------------------------------
Controller Version Information
--------------------------------------------------------
.
.
.
... and a whole lot more RAID info.

Thursday, January 15, 2009

EXT4

I've been hearing all the hypes about ext4 and how fast it boots up your OS so I am about to try it out. Linux kernel 2.6.28 has it in there.

make menuconfig
make
make modules
make modules_install
make install

Well, that's nice. 'make install' did everything for me in grub. I thought I will have to do it the manual way back in the 2.4.xx days.

Hmm I need the latest e2fsprogs (1.41.3). Downloaded and compiled and there it is, mkfs.ext4.

Trying it on a spare drive:

mkfs.ext4 -j /dev/hdb1
mount -t ext4 /dev/hdb1 /mnt/hdb1/

It mounted w/o any prpblem. I'll see if this is any better than ext3.

Well, that's it for now.

-foo