Difference between revisions of "Terastation Recovery"
m (→Flash Error)
m (→Debug Mode)
|Line 114:||Line 114:|
Revision as of 15:10, 27 September 2008
THIS ARTICLE IS STILL UNDER CONSTRUCTION
- 1 TeraStation Recovery
- 1.1 Systems Covered
- 1.2 Booting Process
- 1.3 Failure Symptoms
- 1.4 Replacing the Hard Disks
- 1.5 Telnet enabled Firmware releases
- 1.6 Using the Firmware Updater
- 1.7 Flash Error
- 1.8 Network Will not Start
- 1.9 Boot Does not complete
- 1.10 Clearing Down the System Partition
This article is about recovering TeraStation systems that are failing to load correctly
Before attempting to do any of the articles described in this article you want to first read the wiki article on Terastation Data Recovery.
It covers several types of failures:
- A single disk fails
- The system fails to complete the boot process
- The system appears to boot OK, but the Web GUI and File Shares are inaccessible.
The systems that are currently covered by this article include all the original PPC based Models:
- Original TeraStation
- TeraStation Home Server
- TeraStation Pro v1
The following ARM based systems are not currently covered:
- Terastation Live
- TeraStation Pro v2
To understand the recovery processes that are described here it is very advantageous to have an understanding of how the boot process works.
It runs in various stages:
- A boot loader is loaded from flash
- The boot loader now runs a Linux kernel and a very basic Linux system from disk, with the system files being run from a RAM disk. The disk arrays are started.
- The Linux kernel is switched to running from the System are (partition 1) of the hard disk.
- The system services such as Samba file sharing, the Buffalo Web GUI and (if relevant) File Transfer service, Printer Service, Telnet and the Media server services are started.
Failures can occur at any of these stages and the recovery process to be followed will be dependant on identifying at which stage he boot process failed.
The Original and the Home Server TeraStations report problems by lighting up a Red DIAG light. This light then flashes a number of times to indicate the type of problem detected.
The TeraStation Pro v1 has a LED display instead, and if problems are encountered it displays a Exx type error code.
If the system fails almost immediately it normally means that there is a flash based problem. These are by far the hardest to recover from.
If the system fails after around 30 seconds or more into the Booting process, then this normally means that there is a problem with the System area on the Hard Disks. This type of problem should almost always be recoverable as long as one is very careful about the steps that are carried out.
It is also possible for a single disk to fail. If you are using a RAID5 or a RAID1 array then this situation can be recovered without losing any user data. This is described in the section on replacing a single drive
Replacing the Hard Disks
This section covers using Hard Disks of up to 500Gb which is the maximum size supported by the standard Buffalo software on the PPC based TeraStations. If you want to try and use disks that are larger than this size look at the article on TeraStation and Large Hard Disks.
Replacing a Single disk in a RAID5 array
If a single disk has failed in a RAID5 array, then the system can be recovered without reasonably easily without any data loss. On the Original and Home servermodels a disk failure is indicated by the Disk Status light turning Red. Note that this light is also used to indicate a Disk Full status (more than 90% of disk used) so if all disk Status lights turn Red this is almost certainly the reason. At this point the TeraStation will continue to operate normally, and if you go into the Web GUI you will be told that one or more of the disk arrays have "Low Disk Space". If a disk has failed then you will be told that instead.
The first thing is to decide if the disk really has failed - or whether some sort of data corruption has made the TeraStation think that the drive has failed. Spurious reports of disk failures seem to be quite frequent, and are particularily likely to happen after a power failure. The best way to do this is to attach the drive to a PC and run the manufacturer's disk diagnostic software to check the drive. If this is not possible, then you can simply clear down that drive and see if the disk comes back to life.
Preparing a Drive
There are a few things you need to check before attempting to use a drive:
- If you have a new drive and it is IDE based is to ensure that the jumpers are set correctly. Most new drives come with the jumpers set for the drive to operate in "Slave" mode on the assumption that they are being added to a working PC. The TeraStation requires that the drive be set to operate in Single/Master mode. There should be a digram on the drive showing what the correct jumper setting are for the different modes of working. For SATA drives as used in the TeraStation Pro this is not an issue.
- Removing any existing partitions. Most new drives come without any partitions and would probably work immediately. However some manufacturers try to be "helpful" and provide their drives already partitioned and formatted. If you have a drive in this state (or you are trying to re-use a previously used drive) these partitions need to be removed.
Using a PC to remove partitions
For most users using a PC is probably the easiest way to proceed. This involves:
- Remove the drive from the TeraStation and attaching it to a PC either internally or via an external disk enclosure. For the IDE based models (Original and Home Server) there are instructions on how to open the case to get at the drives at the back of the manual. For the Pro v1 using SATA drives it is much easier as the door at the front can be opened and the drives simply released and slid out.
- Run the Windows Disk Manager software to remove all the partitions on the drive.
- Replace the drive in the TeraStation.
- Switch on the TeraStation.
Using the TeraStation to remove partitions
This option is only possible if you already have telnet enabled firmware installed on your TeraStation.If you have got telnet enabled firmware installed on your TeraStation:
- telnet to the TeraStation, and log in with a user with root privileges (e.g. myroot)
- Run the disk partitioning software using a command of the form
mfdisk //dev/devicewhere device is hda/hdc/hde/hdg for the four drives in IDE based models or sda/sdb/sdc/sdd for those in the Pro model. Make sure you get the right device name as otherwise you will lose all your data.
- Delete all partitions on the disk
- Save the results back to the partition table. This will exit the mfdisk program with an error message about being unable to resync procee the disks.
- Use the"reboot" command to stop/restart the system
Recovering the Array
- The system should now come up without issues, but when you go into the Web GUI it will tell you that the RAID array has been damaged.
- Select the RAID array and you will be taken to the screen where the array is repaired. You should be able to select the drive that failed (all the others should be greyed out) and given an option to repair the array.
- If you select this option then (depending on the firmware release) you will be given a screen in Japanese asking you to enter a displayed number as a confirmation. Enter the number and then select the left-most button to proceed.
- The system will put up a screen about recovering the array. At this point the new drive will be partitioned and formatted, and added to the RAID array. While this is going on (which normally takes a few minutes) all file access to the TeraStation is suspended.
- Once the array has been "fixed" the File Serving services will be resumed, and the the process of Resyncing the array will start. During this stage file accesss is allowed, but performance is degraded. This stage can take a long time with the length of time depending on the size of the array - as an example a 1Tb array takes about 5.5 hours, and other sizes will be pro-rata.
When replacing the drive is is recommended if at all possible that you replace the drive with another of the same make and model. Some people have success with using a different make/model that is of the same size (or larger) so it isn up to you whether you try this.
When you are going to replace the drive, then the replacement should be unformatted wtih nopartitions on it. If it is an IDE model (the Orignal and Home Server models), then make sure that the jumpers are set it make it the Master/Only drive. Many drives come with the jumpers set to Slave on the assumption that they are being added as an additional drive to an existing PC. If the jumpers are incorrectly set to the Slave position then the drive will not be recognised by the TeraStation.
Replacing All the Hard Disks
The most likely reason for replacing all disks is that you are intending to upgrade the capacity of your TeraStation.
If the new disks are of size 500Gb or less then proced as follows:
- Replace all existing drives with 4 identical drives. If they are IDE drives ensure that the jumpers are set for them to be Master/Only drives. Also make sure that there are no existing partitions on the drives.
- Switch the TeraStation on and it will come up in EM-Mode ready to accept a reflash.
- You will probably need to reflash the system twice - once to partition/format the drives, and the second time to copy the system software to the new hard disks. If during the flashing process you get a timeout message, then quit the Flashing process. Leave the TeraStation alone until all the disk activity lights have stopped, and then start the second flash. When flashing it is a good idea to use the Debug Mode of the firmware updater, and set the option to "clear user-config".
- At the end of this process the system will be operating as if it was a brand new TeraStation at the new disk capacity.
If you want to use disks that are larger than 750Gb then see this articl on TeraStation and Larger Hard Disksyou need to work around the fact that the PPC based TeraStations use a 2.4 Linux Kernel that is limited to 2Tb in a single file system. You can work around this as described below:
- Start by flashing just as described above, but make sure that you use a telnet enabled firmware release. Such releases can be obtained for PPC based TeraStations from Itimpi's Web site.
Telnet enabled Firmware releases
The standard firmware supplied by Buffalo does not support telnet access. The big advantage of using telnet is that it gives you access to the TeraStation at the Linux command line level. This allows for futher customisation of the TeraStations to suit particular users requirements.
Telnet enabled versions of firmware corresponding to the various Buffalo releases can be obtained from Itimpi's Website. These firmware releases are identical in functionality to the corresponding Buffalo release (including any bugs!) except for the telnet access.
Using the Firmware Updater
A Flash Error is indicated by:
- TeraStation Pro: Error E04 on LCD Panel
- TeraStation Original or Home Some Sever: 5 blinks every four seconds of red Diag light
The full list of Diag LED codes can be found [url=http://buffalo.nas-central.org/index.php/Hardware_LEDs here].
Flash errors are actually very rare unless they occur just after you have done a firmware upgrade and it turns out that you have a defective flash chip so that the update failed.
In practise it has been found that a good rule-of-thumb is that if the above error occurs very rapidly (i.e. within about 5 seconds) after power on then it probably really is a Flash error. If it takes much longer (greater than 30 seconds) and the system appears to start its normal booting sequence before this error is given then it is actually much more likely that the system files on the hard disk have become corrupted.
To recover from a genuine flash error requires use of the JTAG method of reqriting the flash. This is covered in a number of wiki articles if you want to attempt to do this yourself. There are also a number of forum members who are prepared to attempt JTAG recoveries on behalf of members. If you are interested in availing yourself of such a facility you should post a forum message giving your location so that members who are geographically closest to you can be identifed.
To recover from the situation where the system will not boot look at the section below.