New user's registration have been closed due to high spamming and low trafic on this forum. Please contact forum admins directly if you need an account. Thanks !

My B2 Hard Disk has failed

Got problems with your B2 or B3? Share and get helped!
Post Reply
beeversf
Posts: 31
Joined: 27 Jun 2010, 06:20

My B2 Hard Disk has failed

Post by beeversf »

my mainstay at home is the B2 ( used for many many years) which holds all the files, my home web-sites and most important a roundcube installation which holds all my history emails.

This morning the hard disk on the B2 failed. Not sure if the disk failure was from the disk or the B2. I have been doing a lot of disk copying as I have been setting up an LMS server. I have daily backups and weekly backups using rsync. Unfortunately they seemed to have wiped out the sub-folders in the roundcube area ( under user bubba). I have been unable to retrieve the rsync scripts to see how I dealt with deletions. I am hoping that re-building the disk the directory destroyed will be a parent directory - I will use testdisk and then photorec to try and recover.

I have used testdisk to recover the LVM partition. I am currently creating a backup of the backup just in case the backup disk fails. This is using luckybackup which is taking its time - I guess 600GB is a lot. I only have one linux box.

When it is finished I shall re-boot and hope to recover my roundcube history as I have the other files.

So I will need to purchase a new disk and then re-build it.

The questions:
1. How do I copy the mysql data to another machine ( without running mysql) I need the data althugh I did do backup end of last month.
2. How do I resurrect the B2.

I have purchased a new B3 with rescue disk and hard disk from Rodeus Technologies. I will use that for the future and use this for development reasons ( I do a lot of web development).

Just as an aside I do use raspberry Pi machines ( I have 3 - picoreplayer; LMS server and in the kitchen for a small computer using the tele as a monitor) and thought to use one of them instead of a new B3. However the B3 has a strong box and it is all contained in that box and I do not like relying on usb disks. Data read write speeds is much better than the USB based PI.
86ivar
Posts: 148
Joined: 02 Oct 2010, 11:08

Re: My B2 Hard Disk has failed

Post by 86ivar »

I dont know about php. But you can reinstall B2 with a usb key. The instructions and usb image is in the excito wiki somewhere.
Gordon
Posts: 1461
Joined: 10 Aug 2011, 03:18

Re: My B2 Hard Disk has failed

Post by Gordon »

1) If you are moving to a machine with the same version of MySQL then it should be as simple as copying all the files from /var/lib/mysql. However, if the engine was running at the time the hard disk stopped functioning there is a high chance of corruption, particularly if you created your tables as innodb. In case your tables are Isam and there was no active writing to them in a time frame of say 2 minutes prior to the crash, you can create the same database on your new server and then replace the files in /var/lib/mysql/<database> with those from the old server. You may still want to backup that data afterwards, recreate the database and restore - just to make sure.

2) That should be as simple as replacing the disk with a new one and running the installer. If you're thinking of acquiring a WD Green drive, remember to run the idle3 patch. I don't think there is a PPC version for this, so you'll probably need to do this on a different machine before installing it to the B2. If in doubt, get yourself a Red drive.
beeversf
Posts: 31
Joined: 27 Jun 2010, 06:20

Re: My B2 Hard Disk has failed

Post by beeversf »

Thanks very much for the info. I will try it out once I have managed to recover the files which is proving difficult. Waiting to see how photorec gets on.

The LVM partition has been found and patched as a lvm pv photorec recognises it as ext.... hope that is right.
Gordon
Posts: 1461
Joined: 10 Aug 2011, 03:18

Re: My B2 Hard Disk has failed

Post by Gordon »

That is correct. The volume is formatted as ext3. When reinstalling you might want to change the home partition formatting to ext4. If you're not going to use mirroring or extending through eSata you may also want to loose the LVM for easier access if you need to pull the disk once more. While you did not transfer any data to it yet (also your new B3) you may also want to investigate topics discussing a different partition layout. Like THIS one.
beeversf
Posts: 31
Joined: 27 Jun 2010, 06:20

Re: My B2 Hard Disk has failed

Post by beeversf »

I have at last retrieved my files - or at least most of them. There seems to be a disk failure around my email program directory - luckily I have rsync daily backups on the email data directory so okay and also daily backups on my documents; music and pictures. rsync is a life saver.

A lot of advice centred around testdisk and photres. But these did not work for me as it is an LVM group and they don't really work on this. I found the following worked:

vgchange -a y

This provided the volume group and volume name which for us is /dev/bubba/storage

fsck -t ext3 -f -y /dev/bubba/storage

This takes a long time - 3-4 hours but attempts to fix the disk. It has to have the ext3 extension ( it defaults to ext2 which does not work contrary to certain web-sites). It worked though and i could now mount the disk.

I have 507GB to backup - I bought a 1TB portable drive and used luckybackup ( rsync frontend) to backup the root partition and then the mail data directory and then the rest. I have about 90% of the data but really wanted the emails that came in after the last backup which I have succeeded in getting.

photres does read the files but there is no directory structure or file names so for me only if all else fails.

The hard disk is a WD Caviar Green disk - I don't believe I had the patch - maybe this was my problem. The new one isn't....

put the disk back in the B2 to see what happens - and it boots!! the email , websites everything works. So can move things off to an intel device until the B3 comes in. Don't trust a rebuilt hard disk.... especially with all the read/write errors.
beatgr
Posts: 48
Joined: 01 Feb 2009, 15:25

Re: My B2 Hard Disk has failed

Post by beatgr »

I have had very good luck with the Western Digital RED series.
For my B2, I used the 2 TB model -- very quiet and cooler operation.
Gordon
Posts: 1461
Joined: 10 Aug 2011, 03:18

Re: My B2 Hard Disk has failed

Post by Gordon »

It's elsewhere on the board already, but the point with factory configured Green drives is that they will go into park after some eight seconds inactivity or so. Which is quite disastrous because the Operating System will perform some disk access every 10-15 seconds. This is what causes the clicking noises, sometimes referred to as rattling. The Red drives essentially boast the same hardware technology, but without the early park functionality that is supposed to let the drive save more energy. Price on both drives are more or less the same, but you can sometimes save some money by getting a Green one instead of a Red. In that case you can run the idle3 timer patch to turn the Green drive effectively into a Red drive.

AFAIK nobody has ever managed to compile this patch for PPC on the B2 however. The ARM version is included in the B3 install image.
beeversf
Posts: 31
Joined: 27 Jun 2010, 06:20

Re: My B2 Hard Disk has failed

Post by beeversf »

I have received my B3 but had to pay import duty of £50 - bit of a stinger.

Have installed it and it is now running email and file server/ house web-server. I wanted to make the old B2 my web development and squeezebox server ( I am currently using a raspberry pi).

I have put a 1TB seagate disk in the server and downloaded the installer software and installed it. It works and I can change IP address etc etc. When I turn it off to put it in the designated area it will not reboot. I have tried this twice now.

Any advice - I could put the old disk back in but it has already lost sectors and not sure how safe the disk is.
Post Reply