Can your help me restore original firmware?

Post Reply
ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Tue Nov 22, 2011 4:59 pm

My post 21 nov 11:55 says testdisk 6.12 found partitions after a search. But for the system itself everything is unallocated.
I think the confusions starts there. It is not an USB disk so sync is not usefull. Reboot doesn't help.

Anyway also tried a second route with luke1975 Iomega_HMNHD.lzma from the downloadsite and a fresh 320GB harddisk.
My findings are the same. All non allocated space. Reboot doesn't solve this.. I think the partition table was not good restored and it needs a new build up. If you thinks so too, HOW?

@Mijzelf I am very interested in your findings about my Iomega_HMNHD_2TB.lzma upload, especially if it works. I can't test it myself and I want to be sure before I touch my original harddisk and use it for e.g. testpurposes.

@Mijzelf. I cannot report the firmware version now. I need to start the original disk - and I don't want to do this before see above - or have a restore on another disk and I haven't succeeded in this.

I think about a third try with a 1,5TB disk. I think the shrinking is the issue. I set apart the 500GB and 320GB hard disk for a moment there are new ideas for solving the problem.

Mijzelf
Posts: 6206
Joined: Mon Jun 16, 2008 10:45 am

Re: Can your help me restore original firmware?

Post by Mijzelf » Tue Nov 22, 2011 7:51 pm

ton123, what kind of system do you have? Is it possible that it doesn't support GPT?
I think the partition table was not good restored
Some BIOSses have a MBR protection. I don't know if it also works for Linux, but if it does, it should protect the MBR from overwriting. Have a look, 'dd if=/dev/sdx count=1 | hexdump' should show

Code: Select all

0000000 0000 0000 0000 0000 0000 0000 0000 0000
*
00001a0 0000 0000 5f00 0001 df00 0000 8000 0000
00001b0 8022 0000 0022 0000 8000 0000 0000 0000
00001c0 0001 feee ffff 0001 0000 88af e8e0 0000
00001d0 0000 0000 0000 0000 0000 0000 0000 0000
*
00001f0 0000 0000 0000 0000 0000 0000 0000 aa55
1+0 records in
1+0 records out
0000200
512 bytes (512 B) copied, 0.00213786 s, 239 kB/s
The alignment of your disk seems OK:

Code: Select all

1 P Linux Raid start 65536 End 42008576 Size 41943041 primary md0
It's the same in both your image and luke1975's.
I can't test it myself
Nor can I, as I don't have a CE. I can study the images, and tell you that it doesn't differ enough from luke1975's to think it won't boot. I could upload it if someone else want to test.
I think the shrinking is the issue
Did you shrink anything? Or do you mean the lack of room for a full-blown sda2?

It could be usefull to compare the disk you tried to boot against the image you made it from. If it actually booted, I'd expect some logfiles, somewhere:

Code: Select all

cat image.lzma | lzma -d | cmp /dev/sdx
This will stop with a 'input aborted', or something like that when they are equal, or a 'differs at byte nnn'. Please note the exact number.

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Tue Nov 22, 2011 8:37 pm

@Mijzelf

The restore on the 1.5TB drive ST31500541AS of luke1975's Iomega_HMNHD.lzma from the downloadsite was succesful.
I used only the second command in your post Nov 17.2100 11:01.
Result:
Unallocated 32.00 MiB
/dev/sda1 lvm2 20GB raid
/dev/sda2 unknown 911.48 GiB
unallocated 465.75 GiB
This all looks great to me.
Nothing done further.
Build this 1.5TB in the Iomega.

The Iomega spins up and after a lot of flashing lights there was one stable white light.
If found the Twonkey server on my network first and this gave me the ip address for the Iomega Home Page of the system. It all looks good and I think it is interesting to know the following:
1. The mac addres of the device has been automatically taken over from the hardware. In the printed circuit board the mac addres is printed and it corresponds with the real mac address in my network.
2. The free space that is reported by the management system is 1.4TB. So I conclude the system found during boot up that there was more space on the disk and it take automatic action to present it.

The firmware level of luke1975's Iomega_HMNHD.lzma from the downloadsite is: 3.0.9.44771
I ugrade now to the newest level: 3.1.14.995.
Until 95% of it, it all looks ok.
But it went wrong. And I completely lost the unit. White permanent light. Red light flashing.
I reset the box. The same.
Power of and power on the box. The same.

Well I know how to solve this... Start all over with luke1975's Iomega_HMNHD.lzma from the download site and don't use this upgrade.
I wait a while before I do this, maybe someone want to know information about the disk.
Because I am running out of disks I have to use this disk again and questions cannot be answered.

Added later:
There is red flashing but the box is not unreachable.
It looks I can still connect to the boxes IP addres. I get a page setup which is empty. I can't do anything with it.
It also looks there are still services running:
80 http (as above mentioned)
139 netbios-ssn
443 https
445 microsoft-ds
3689 rendezvous
I found these services with the app "Fing" on my Samsung Galaxy. Amazing!

I will come back later on your post of 22 Nov, 2011 7:51.

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Tue Nov 22, 2011 11:42 pm

After about 1 hour i could access the home page again. I now see there is only 0 bytes left for data... I now gave the command to return back to factory installation. And see tomorrow the result....

Mijzelf
Posts: 6206
Joined: Mon Jun 16, 2008 10:45 am

Re: Can your help me restore original firmware?

Post by Mijzelf » Wed Nov 23, 2011 8:32 am

ton123 wrote:2. The free space that is reported by the management system is 1.4TB.
I wonder if this could be the source of your later problems. Can you ssh in? In that case you can use gparted and pvdisplay to see if the box really rearranged the disk, or that it's just showing the size of the disk minus some overhead.

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Wed Nov 23, 2011 10:33 am

This is all with the new 1.5TB. After the factory reset only a bright white light. The management page reports firmware 3.1.14.995. 1.4TB but no bytes available.
Everything looks normal except 1.4TB disk but no bytes available. And no shares. And I can't make a share.

I now assume I have to do more to prepare on the desktop.
"Then use fdisk to delete partition 2, and recreate it. (Partition 2 will have to fill up all remaining space after partition 1). I don't know if you'll have to put a filesystem on partition 2, as it seems to be used as logical volume, and not as 'plain partition'."
http://192.168.2.29/diagnostics.html shows only a background.
I now try the extra command on my desktop and see if things are solved. If not I install the download again.


For your information:
I have a second brand new out of the box HMNHD-CE. It bought it from the same shelf.
http://192.168.2.20/diagnostics.html show the possibilities as expected.
The firmware is 3.1.12.47631. This must be - >99% chance - the same version as the version of my upload.
I will use this system for reference.
I see the shares of the system nice presented in the system status management panel. In the 1.5TB version there is nothing.

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Wed Nov 23, 2011 11:44 am

@Mijzelf 22-11-2011 7:51
Testsystem Shuttle XPC motherboards SB75G2 http://www.shuttle.eu/_archive/older/en/sb75g2.htm.
P4 2,8 HT
Parted Magic 6.7. Linux kernel 3.0.4
No disks, SATA, USB, etc
Phoenix Award BIOS V6.00 PG
Always fresh boot from DVD

On the 320GB disk dd if=/dev/sdx count=1 | hexdump responsed with an error.
On the 1,5TB disk dd if=/dev/sdx count=1 | hexdump responsed with an error.
Changed the command in dd if=/dev/sda count=1 | hexdump responsed with hexdump.
3th line differs, it is:
88af is 6daf and e8e0 is 7470

You are right. I didn't shrink. I meant lack of space.

For this moment I skip to check on logfiles

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Wed Nov 23, 2011 1:27 pm

:D This worked:
First made GUID partition on 1.5TB harddisk. Did this with Gparted.
cat /path/to/CE.lzma | lzma -d | dd of=/dev/sda
Result:
unallocated 32.00MiB
/dev/sda1 lvm2 20.00GiB GPT
/dev/sda2 unknown 911.48GiB
unallocated 465.75GiB

GParted used to delete partition 2.
I didn't recreate it.
Result:
unallocated 32.00MiB
/dev/sda1 lvm2 20.00GiB GPT
unallocated 1.34TB

harddrive in de Iomega and power on
In the management panel everything looks normal.
One thing in drivemanagement:
ST31500541AS,CC34 Size 1,4TB. Available storage: 911.35GB
Interesting, I can live with that. It can be solved later.

http://ip adres/diagnostics.html and enabled SSH and for further study detailed logging
Putty ssh at ip adres root: root, password: soho
Everything ready for further investigation

I add the administrator password later.
The same for firmware upgrades.
Other points of interest can be done later, or not ...
By the way the earlier posted two differences in the hexdump with your post were applicable here also.

I now take some time for further learning of the system en trying out linux commands on the box.

Thank you for all your help Mijzelf. Amazing.

Mijzelf
Posts: 6206
Joined: Mon Jun 16, 2008 10:45 am

Re: Can your help me restore original firmware?

Post by Mijzelf » Wed Nov 23, 2011 1:39 pm

Can you post the outputs of

Code: Select all

parted -l /dev/sda
cat /proc/partitions
cat /proc/mounts
lvdisplay
when executed in ssh?

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Wed Nov 23, 2011 1:57 pm

Warning: Not all of the space available to /dev/sda appears to be used, you can
fix the GPT to use all of the space (an extra 976752000 blocks) or continue with
the current setting?
Fix/Ignore?

because copy paste there went something wrong. I think the system have seen it as a command.
root@IomegaNAS:/# parted -l /dev/sda
Model: ATA ST31500541AS (scsi)
Disk /dev/sda: 1500GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number Start End Size File system Name Flags
1 33.6MB 21.5GB 21.5GB primary raid
2 21.5GB 1000GB 979GB primary


Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/337706e2_vg-lv3b7d731f: 979GB
Sector size (logical/physical): 512B/512B
Partition Table: loop

Number Start End Size File system Flags
1 0.00B 979GB 979GB xfs


Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/md0_vg-vol1: 17.2GB
Sector size (logical/physical): 512B/512B
Partition Table: loop

Number Start End Size File system Flags
1 0.00B 17.2GB 17.2GB xfs


Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/md0_vg-BFDlv: 4295MB
Sector size (logical/physical): 512B/512B
Partition Table: loop

Number Start End Size File system Flags
1 0.00B 4295MB 4295MB ext2


Error: /dev/md0: unrecognised disk label

Error: /dev/md1: unrecognised disk label

root@IomegaNAS:/#


root@IomegaNAS:/# cat /proc/partitions
major minor #blocks name

7 0 439343 loop0
7 1 5120 loop1
7 2 52 loop2
8 0 1465138584 sda
8 1 20971520 sda1
8 2 955758260 sda2
9 0 20971456 md0
253 0 4194304 dm-0
253 1 16773120 dm-1
9 1 955758208 md1
253 2 955756544 dm-2

root@IomegaNAS:/# cat /proc/mounts
rootfs / rootfs rw 0 0
/dev/root.old /initrd ext2 rw,relatime,errors=continue 0 0
none / tmpfs rw,relatime,size=51200k,nr_inodes=31939 0 0
/dev/md0_vg/BFDlv /boot ext2 rw,noatime,errors=continue 0 0
/dev/loop0 /mnt/apps ext2 ro,relatime 0 0
/dev/loop1 /etc ext2 rw,sync,noatime 0 0
/dev/loop2 /oem cramfs ro,relatime 0 0
proc /proc proc rw,relatime 0 0
none /proc/bus/usb usbfs rw,relatime 0 0
none /sys sysfs rw,relatime 0 0
devpts /dev/pts devpts rw,relatime,gid=5,mode=620 0 0
tmpfs /mnt/apps/lib/init/rw tmpfs rw,nosuid,relatime,mode=755 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev,relatime 0 0
/dev/mapper/md0_vg-vol1 /mnt/system xfs rw,noatime,attr2,inode64,logbufs=8,noquota 0 0
/dev/mapper/337706e2_vg-lv3b7d731f /mnt/pools/A/A1 xfs rw,noatime,attr2,logbufs=8,noquota 0 0
root@IomegaNAS:/#

root@IomegaNAS:/# lvdisplay
--- Logical volume ---
LV Name /dev/337706e2_vg/lv3b7d731f
VG Name 337706e2_vg
LV UUID MULnj2-7NKL-H30V-jUd6-maK7-q5Pf-o3INFe
LV Write Access read/write
LV Status available
# open 1
LV Size 911.48 GB
Current LE 233339
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:2

--- Logical volume ---
LV Name /dev/md0_vg/BFDlv
VG Name md0_vg
LV UUID y1xYx6-2YW5-GOD3-eFBz-21gP-XY3H-skDzwp
LV Write Access read/write
LV Status available
# open 1
LV Size 4.00 GB
Current LE 1024
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:0

--- Logical volume ---
LV Name /dev/md0_vg/vol1
VG Name md0_vg
LV UUID NkcXqr-WI8l-Ru5L-0jPU-KsOv-LmyG-RPdLRb
LV Write Access read/write
LV Status available
# open 1
LV Size 16.00 GB
Current LE 4095
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:1

root@IomegaNAS:/#

Mijzelf
Posts: 6206
Joined: Mon Jun 16, 2008 10:45 am

Re: Can your help me restore original firmware?

Post by Mijzelf » Wed Nov 23, 2011 3:05 pm

According to gparted only 1TB is used
Number Start End Size File system Name Flags
1 33.6MB 21.5GB 21.5GB primary raid
2 21.5GB 1000GB 979GB primary
You delete partition 2, so apparently the firmware recreated a 1TB partition, which explains your free space. So either somewhere in the firmware is stored that it should have a 1TB disk, or it has used the value in the legacy MBR.
9 1 955758208 md1
253 2 955756544 dm-2
It seems the data partition is actually a logical volume in a volumegroup on a phyisical volume inside a raid array on a partition. Sigh. Why didn't they just use a partition? Can you post

Code: Select all

cat /proc/mdstat
for the raid type?
LV Name /dev/337706e2_vg/lv3b7d731f
That's different from the one described in the wiki. If luke1975 is still reading with us, can you tell us if it matches yours? It's your image.

I'll look if I can find a script which is responsible for recreating partition 2, to see why it's 1TB, and how the volume name is generated.

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Wed Nov 23, 2011 4:00 pm

root@IomegaNAS:/# cat /proc/mdstat
Personalities : [linear] [raid0] [raid1]
md1 : active linear sda2[0]
955758208 blocks super 1.0 64k rounding

md0 : active linear sda1[0]
20971456 blocks 64k rounding

unused devices: <none>
root@IomegaNAS:/#

ton123
Posts: 36
Joined: Tue Nov 15, 2011 7:38 am
Location: Netherlands

Re: Can your help me restore original firmware?

Post by ton123 » Wed Nov 23, 2011 4:15 pm

lvdisplay on my "Reference" HMNHD-CE of 2TB, also out of the box.

login as: root
root@192.168.2.20's password:
root@hmnhd-TI2PEL:/# lvdisplay
--- Logical volume ---
LV Name /dev/46f2530a_vg/lv309ed056
VG Name 46f2530a_vg
LV UUID 5PlCov-7QwP-vQqX-oZSg-ChW9-Ms3a-3J5hcb
LV Write Access read/write
LV Status available
# open 1
LV Size 1.80 TB
Current LE 471804
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:2

--- Logical volume ---
LV Name /dev/md0_vg/BFDlv
VG Name md0_vg
LV UUID BZLMVC-3ZY0-okEP-NFSL-CPG2-i3Yu-8eo3dp
LV Write Access read/write
LV Status available
# open 1
LV Size 4.00 GB
Current LE 1024
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:0

--- Logical volume ---
LV Name /dev/md0_vg/vol1
VG Name md0_vg
LV UUID tBmy8T-S060-PM0H-Xstr-e3i4-BPiK-2RjnEt
LV Write Access read/write
LV Status available
# open 1
LV Size 16.00 GB
Current LE 4095
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:1

root@hmnhd-TI2PEL:/#

This is also different.
If you want I can give you more information about this reference system.
I have arranged root access also to this box. The only thing I don't want to do is change things.

macnb
Posts: 7
Joined: Tue Nov 15, 2011 8:59 am

Re: Can your help me restore original firmware?

Post by macnb » Wed Nov 23, 2011 7:00 pm

Mijzelf wrote:
macnb wrote:and zero'ed the the drive too
Really? That takes about 3 hours for a 1TB disk.
Yup left it running over night - not sure how long it took - went to bed after waiting an hour.
Mijzelf wrote:
macnb wrote:What's the password ?
It's somewhere in the forum. From the top of my hat: soho<Your admin password>
Got it. I was trying to use Mac Os SSH command and was doing it wrong (entered ssh root @192.168.1.50 and when prompted for the password, I entered soho<myadminpassword>).
Now I can access the root from my Mac.
Thanks for your help.

Mijzelf
Posts: 6206
Joined: Mon Jun 16, 2008 10:45 am

Re: Can your help me restore original firmware?

Post by Mijzelf » Wed Nov 23, 2011 8:43 pm

I can't find the place where the data partition is created (at least, grep can't, when searching for the keywords parted (needed to create the partition) or pvcreate (needed to initialize the partition for LVM usage)).
I did find the place where the volume group and logical volume name are stored: /etc/sohoVolumes.xml. Actually this file exists on several places, but a lot of copying is done during boot and shutdown, so maybe that's normal (this is on ton123's clean image, btw, which also contains some logfiles.)

Both ton123 and macnb have reported that a new partition was made on boot, but alas the one of ton123 had the wrong size. So I suppose the restore action could be:
  • write the image to the disk.
  • use fdisk -u to delete the (only) partition in the legacy MBR. Recreate it starting at sector 1 (that's why the -u flag is added), and occupying the whole disk. Set the partitiontype to ee (GPT)
  • use parted to delete the second partition in the GPT partition table.
  • Put the disk in the enclosure, and boot it.
Maybe ton123 both small disks failed because the partition in the legacy MBR was (far) bigger than the disk, and tried the firmware to create it's data partition in a non-existing space. On his 1.5TB disk the data partition also followed this size. If that is true, I wonder how a 3TB disk will be treated. The legacy partition will only be 2TB.

Post Reply