NAS540: No volume label after deletion of sysvol-1

Mindspeed Comcerto 2000 based
masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Wed Dec 27, 2017 10:21 pm

Hello Mijzelf, I made a big mistake today. I wanted to install a new hard disk and found a disabled share sysvol-1 in the shares section. Since there was an active sysvol share, I deleted the share correctly with confirmation via "DELETE".

But now the volume name of my main disk is no longer recognized. The hard disk does not get a volume name.

It was previously listed under /i-data/2888f87b and was called Volume2.

There was a share on the hard disk called "Daten".

All hard disks are created as "basic" volume. No RAID.

Do you have any idea how to correct the drive so that the share is displayed again?
2017-12-27 22_53_36-ZyXEL NAS540.jpg
2017-12-27 22_47_07-ZyXEL NAS540.jpg
2017-12-27 23_23_17-ZyXEL NAS540.jpg
You do not have the required permissions to view the files attached to this post.

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

Re: NAS540: No volume label after deletion of sysvol-1

Post by Mijzelf » Thu Dec 28, 2017 11:28 am

Is the volume still mounted in /i-data ? If not, can you post the output of 'mdadm --examine /dev/sd[abcd]3'.

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 1:07 pm

There are 4 hard disks in the NAS. I removed 3 disks and started the nas again, to identify the hard disk with the missing volume.

Code: Select all

~ # cat /proc/mdstat
Personalities : [linear] [raid0] [raid1] [raid10] [raid6] [raid5] [raid4]
md2 : active raid1 sda3[0]
      3902886720 blocks super 1.2 [1/1] [U]

md1 : active raid1 sda2[5]
      1998784 blocks super 1.2 [4/1] [__U_]

md0 : active raid1 sda1[5]
      1997760 blocks super 1.2 [4/1] [__U_]

unused devices: <none>

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 1:10 pm

Code: Select all

~ # mdadm --examine /dev/sda3
/dev/sda3:
          Magic : a92b4efc
        Version : 1.2
    Feature Map : 0x0
     Array UUID : 2888f87b:f32eb14a:2add1be4:cf97232f
           Name : NAS540:3  (local to host NAS540)
  Creation Time : Mon May 25 10:56:34 2015
     Raid Level : raid1
   Raid Devices : 1

 Avail Dev Size : 7805773824 (3722.08 GiB 3996.56 GB)
     Array Size : 3902886720 (3722.08 GiB 3996.56 GB)
  Used Dev Size : 7805773440 (3722.08 GiB 3996.56 GB)
    Data Offset : 262144 sectors
   Super Offset : 8 sectors
          State : clean
    Device UUID : 23b75307:fd554b26:eb95ac1a:73eca9dd

    Update Time : Thu Dec 28 14:05:21 2017
       Checksum : 6387a989 - correct
         Events : 193


   Device Role : Active device 0
   Array State : A ('A' == active, '.' == missing)

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

Re: NAS540: No volume label after deletion of sysvol-1

Post by Mijzelf » Thu Dec 28, 2017 1:22 pm

Hm. That raid array is created back in 2015. Are you sure the volume isn't mounted? Or can it be mounted?

Code: Select all

mkdir /mnt/md2
mount /dev/md2 /mnt/md2
When deleting a volume I'd expect the firmware to delete the raidheader. There's a command for that (mdadm --zero-superblock /dev/sda3), but how do you delete a filesystem? Using dd to overwrite the whole filesystem space seems a bit overdone.

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 1:35 pm

I executed the named commands, but the volume has still no name within the NAS. Therefore I couldn't mount the share.
2017-12-28 14_32_57-ZyXEL NAS540.jpg
If you want, I can arrange a TeamMeeting session, to shorten your effort.

PS. The setup of the NAS was 2015. Thats right. The problem was caused, when I deleted the deactivated "sysvol-1" share with "DELETE" and confirmation.
You do not have the required permissions to view the files attached to this post.

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

Re: NAS540: No volume label after deletion of sysvol-1

Post by Mijzelf » Thu Dec 28, 2017 2:12 pm

Right. So this is not about data recovery or something like that, but 'just' the volume label?

I looked on my '520 where the volume name could be found in /i-data/sysvol/.system/ and /etc/. It is in /etc/zysyncd.conf and in /i-data/sysvol/.system/name_label. I cannot remember ever to have configured zysyncd, so I guess it's an automatic generated file.

After editing /i-data/sysvol/.system/name_label & rebooting the new volume name was found in /etc/zysyncd.conf and all shares on the volume were 'automigrated'.

So I guess executing

Code: Select all

echo "Your volume name" >/i-data/<your mountpoint>/.system/name_label
reboot
should do the trick.

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 2:20 pm

Is

Code: Select all

<your mountpoint>
the internal id, in my case: 2888f87b or something like md2?

I got:

Code: Select all

~ # echo "Volume2" >/i-data/2888f87b/.system/name_label
-sh: can't create /i-data/2888f87b/.system/name_label: nonexistent directory
I also tried:

Code: Select all

~ # mkdir /mnt/md2
~ # mount /dev/md2 /mnt/md2
~ # echo "Volume2" >/i-data/md2/.system/name_label
-sh: can't create /i-data/md2/.system/name_label: nonexistent directory
I also entered

Code: Select all

vi /i-data/sysvol/.system/name_label
The file seems to be empty.
2017-12-28 15_39_16-Downloads.jpg
Maybe my .system and .etc pathes or symlinks aren't ok anymore.
You do not have the required permissions to view the files attached to this post.

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

Re: NAS540: No volume label after deletion of sysvol-1

Post by Mijzelf » Thu Dec 28, 2017 2:51 pm

Try

Code: Select all

mkdir /i-data/2888f87b/.system
echo "Volume2" >/i-data/2888f87b/.system/name_label

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 3:04 pm

First success.

The volume name is visible, but the volume is grey. Even after a reboot.
2017-12-28 15_56_56-ZyXEL NAS540.jpg
Some of the shares are marked as lost.
2017-12-28 16_02_32-ZyXEL NAS540.jpg
You do not have the required permissions to view the files attached to this post.

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

Re: NAS540: No volume label after deletion of sysvol-1

Post by Mijzelf » Thu Dec 28, 2017 3:24 pm

The obvious question is: are these directories still there?

Code: Select all

ls -l /i-data/2888f87b/

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 3:29 pm

Unfortunately not. Only the admin, sysvol and video share is visible in putty and this is in accordance to the frontend.
2017-12-28 16_28_00-192.168.100.34 - PuTTY.jpg
Is there a chance to get them back?
You do not have the required permissions to view the files attached to this post.

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

Re: NAS540: No volume label after deletion of sysvol-1

Post by Mijzelf » Thu Dec 28, 2017 3:42 pm

This is strange. I can imagine that deleting the share will also delete it's content. And as the share pointed to the volume, it also deleted .system/name_label, effectively deleting the volume name.

But why didn't it delete the admin and video directory? Their timestamps are clear, they are not generated today.

An ext filesystem doesn't support undelete. But you might have luck using extundelete. Stop writing to that disk immediately.

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 3:46 pm

Up to now there is no operative share, so I hope, that there are no write processes ongoing on this disk.

Can you tell me how to use the tool?

Do I have to remove the hard disk from the NAS?

masterflai
Posts: 14
Joined: Sat Jun 27, 2015 7:54 pm

Re: NAS540: No volume label after deletion of sysvol-1

Post by masterflai » Thu Dec 28, 2017 4:03 pm

I have a Kali Linux Notebook here for recovery. Is this tool able to recover also pathes and the original file names?

The last backup of the stored data was performed on 13.12.2017.

I have seen that there is an option only to recover files within a specific time range.

Puuh, unbelievable. Such a huge problem in cause of a small failure.

Post Reply