*New 11.3 series Release:
2019-10-05: XigmaNAS 11.3.0.4.6928 - released, 11.2 series are soon unsupported!

*New 12.0 series Release:
2019-10-05: XigmaNAS 12.0.0.4.6928 - released!

*New 11.2 series Release:
2019-09-23: XigmaNAS 11.2.0.4.6881 - released!

We really need "Your" help on XigmaNAS https://translations.launchpad.net/xigmanas translations. Please help today!

Producing and hosting XigmaNAS costs money. Please consider donating for our project so that we can continue to offer you the best.
We need your support! eg: PAYPAL

RAID 1 - replace a (functional) drive

Software RAID information and help
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

RAID 1 - replace a (functional) drive

#1

Post by andreas23_07 » 14 Nov 2017 21:58

dear ladies and gentlemen,

smart info of my drives display recommondations to replace the drives.
currently everything is still fine, but i would like to replace a drive.

- i could not find a correct tutorial, how to achieve this within nas4free version 11.
- i have tried several scenarios on a virtualized nas4free installation. the result was always identical: my raid was corrupted.

may i ask you for a hint / tutorial?

kind regards,
andreas

User avatar
ms49434
Developer
Developer
Posts: 718
Joined: 03 Sep 2015 18:49
Location: Neuenkirchen-Vörden, Germany - GMT+1
Contact:
Status: Offline

Re: RAID 1 - replace a (functional) drive

#2

Post by ms49434 » 14 Nov 2017 22:07

Could you please specify RAID 1, is it a ZFS Mirror or a Software RAID, i.e. GEOM Mirror or GVINUM RAID 1?
It would be nice to know more about your system, i.e. NAS4Free release / version as well.
1) XigmaNAS 12.0.0.4 amd64-embedded on a Dell T20 running in a VM on ESXi 6.7U2, 22GB out of 32GB ECC RAM, LSI 9300-8i IT mode in passthrough mode. Pool 1: 2x HGST 10TB, mirrored, SLOG: Samsung 850 Pro, L2ARC: Samsung 850 Pro, Pool 2: 1x Samsung 860 EVO 1TB , services: Samba AD, CIFS/SMB, ftp, ctld, rsync, syncthing, zfs snapshots.
2) XigmaNAS 12.0.0.4 amd64-embedded on a Dell T20 running in a VM on ESXi 6.7U2, 8GB out of 32GB ECC RAM, IBM M1215 crossflashed, IT mode, passthrough mode, 2x HGST 10TB , services: rsync.

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#3

Post by andreas23_07 » 21 Nov 2017 16:51

Hi,

The SW Version is 11.0.0.4.3305.
RAID 1 is used as Software RAID. I have included some screencopies.
01 disks.jpg
02 SW RAID1.jpg
03 mountpoints.jpg
Which information is missing?

kind regards, Andreas
You do not have the required permissions to view the files attached to this post.

User avatar
Snufkin
Advanced User
Advanced User
Posts: 289
Joined: 01 Jul 2012 11:27
Location: Etc/GMT-3 (BSD style)
Status: Offline

Re: RAID 1 - replace a (functional) drive

#4

Post by Snufkin » 21 Nov 2017 22:14

andreas23_07 wrote:
21 Nov 2017 16:51
The SW Version is 11.0.0.4.3305.
RAID 1 is used as Software RAID.
Did you try simply replace old disk with new one?
  • In virtual environment just create 3 disks, place 2 of them in mirror, format, mount and fill with test data.
  • Then turn off virtual machine, disconnect one side of mirror and attach to the same SATA/PATA virtual port 3rd empty disk.
  • Immediately after boot NAS4Free starts rebuilding Software RAID1.
XNAS 11.3.0.4 embedded, ASUS P5B-E, Intel DC E6600, 4 GB DDR2, 2 x HGST HDN726040ALE614, 2 x WDC WD5000AAKS, Ippon Back Power Pro 400

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#5

Post by andreas23_07 » 22 Nov 2017 20:46

Hi,

I have to admitt, I am good at linux and windows, but I do not have any idea concearning bsd (filesystems eg).

I have tried these two procedures:

Procedure A)
============
1) boot nas4free ordinary, shutdown
2) goto vboxmanage, rename drive HDD_Daten1.vmdk to HDD_Daten1_orig.vmdk (sata port1)
3) create new file HDD_Daten1_replace.vmdk (sata port1)
4) boot nas4free with new, replaced drive
5) start web admin tool
6) disks / management says status: changed (device serial: ....)
7) disks / software raid says status degraded
8) reboot nas4free
stuck, not working

Procedure B)
============
1) start from a clean system
3) create new file HDD_Daten1_replace.vmdk (sata port1)
4) boot nas4free with new, replaced drive
5) start web admin tool
6) shut down samba server
7) remove mountpoint
8) tried to get ada1 out of raid; was not possible
9) tried to format ada1; was not possible
10) executed "clear config and import disks" - all drives seem to be lost (Filesystem unknow or unformatted)
11) disks / software raid / select volume / Edit Raid - no disks found
stuck, not working

In both cases I have to restore my virtual machine from backup - no chance to get my shares working again...

I wonder what I am doing incorrect...

Kind regards, Andreas
You do not have the required permissions to view the files attached to this post.

User avatar
Snufkin
Advanced User
Advanced User
Posts: 289
Joined: 01 Jul 2012 11:27
Location: Etc/GMT-3 (BSD style)
Status: Offline

Re: RAID 1 - replace a (functional) drive

#6

Post by Snufkin » 22 Nov 2017 22:09

andreas23_07 wrote:
22 Nov 2017 20:46
Procedure A)... B)...
stuck, not working...
Sorry, my fault forget to mention several steps: Just run all steps together in virtualbox test bed, everything works as expected.
XNAS 11.3.0.4 embedded, ASUS P5B-E, Intel DC E6600, 4 GB DDR2, 2 x HGST HDN726040ALE614, 2 x WDC WD5000AAKS, Ippon Back Power Pro 400

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#7

Post by andreas23_07 » 23 Nov 2017 12:45

Thanks a lot!

I found the correct workflow, my - virtual - disk was replaced successfully!
I have done a detailed tutorial (attachment).

kind regards,
Andreas
You do not have the required permissions to view the files attached to this post.

User avatar
Snufkin
Advanced User
Advanced User
Posts: 289
Joined: 01 Jul 2012 11:27
Location: Etc/GMT-3 (BSD style)
Status: Offline

Re: RAID 1 - replace a (functional) drive

#8

Post by Snufkin » 23 Nov 2017 13:53

andreas23_07 wrote:
23 Nov 2017 12:45
...I have done a detailed tutorial (attachment).
Good document!
Just two remarks at the story happy end:
  • Steps 2.6 and 2.7 could be done in one by pressing Clear config & Import Disks button.
  • Direct rename of virtual disk file confuses virtualbox media manager and fills media list with errors.
XNAS 11.3.0.4 embedded, ASUS P5B-E, Intel DC E6600, 4 GB DDR2, 2 x HGST HDN726040ALE614, 2 x WDC WD5000AAKS, Ippon Back Power Pro 400

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#9

Post by andreas23_07 » 27 Nov 2017 13:15

Hi,

unfortunately disk swap on my physical device did not work:
it is not possible to insert the new disk in the existing geom-raid 1. see attachment.
You do not have the required permissions to view the files attached to this post.

User avatar
Snufkin
Advanced User
Advanced User
Posts: 289
Joined: 01 Jul 2012 11:27
Location: Etc/GMT-3 (BSD style)
Status: Offline

Re: RAID 1 - replace a (functional) drive

#10

Post by Snufkin » 27 Nov 2017 13:34

andreas23_07 wrote:
27 Nov 2017 13:15
it is not possible to insert the new disk in the existing geom-raid 1.
Did you delete already removed disk? Possibly not, there is warning message at the bottom of screenshot.
XNAS 11.3.0.4 embedded, ASUS P5B-E, Intel DC E6600, 4 GB DDR2, 2 x HGST HDN726040ALE614, 2 x WDC WD5000AAKS, Ippon Back Power Pro 400

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#11

Post by andreas23_07 » 27 Nov 2017 14:48

Hi,

unfortunately no previouse errors.
hdd removed from raid and hdd management.
new disk imported to hdd management

everything applied without any errors...
HDD Management.jpg
Software RAID - Geom - Mgmnt.jpg
Software RAID - Geom - Mgmnt - Edit.jpg
You do not have the required permissions to view the files attached to this post.

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#12

Post by andreas23_07 » 28 Nov 2017 01:39

Finally I got my new disk back into my RAID1.

The solution was easy, but not understandable:
- I had to "forget" my old disk ada0 again
- afterwards "insert" of ada0 into RAID1 was OK

Now my disc are busily syncing...

interesting, kind regards,
Andreas

User avatar
Snufkin
Advanced User
Advanced User
Posts: 289
Joined: 01 Jul 2012 11:27
Location: Etc/GMT-3 (BSD style)
Status: Offline

Re: RAID 1 - replace a (functional) drive

#13

Post by Snufkin » 28 Nov 2017 07:22

andreas23_07 wrote:
28 Nov 2017 01:39
The solution was easy, but not understandable:
- I had to "forget" my old disk ada0 again
- afterwards "insert" of ada0 into RAID1 was OK
Noticed that you are swapping disks under ada0 name. There is note in FreeBSD manual pages
The component with the biggest priority is used... as a master component when resynchronization is needed
May be newly installed ada0 contains gmirror metadata from old installation?

And you actually issued forget command twice, first time for actual running mirror on ada1 and second for reused ada0 disk?
XNAS 11.3.0.4 embedded, ASUS P5B-E, Intel DC E6600, 4 GB DDR2, 2 x HGST HDN726040ALE614, 2 x WDC WD5000AAKS, Ippon Back Power Pro 400

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#14

Post by andreas23_07 » 28 Nov 2017 08:26

I am sorry this is a little bit confusing:

- in my tutorial i replaced ada1 - because ada0 was my virtualbox' boot device
- my physical nas is booting - as recommended - from an usb stick, which counts different devices / numbers
=> my original task is to replace ada0 in my physical nas.

the new disk was shiny and new - not reysed eg.
you are rigth, i have requested two forgets: but both of them for ada0.

maybe it was wrong to restart nas4free after first forget of old ada0. maybe there was written back to ada0 some data during startup...

the disc have successfully synchronized during night - but i have to double check the results (correct basic formatting - during sync "not formatted" was displayed eg).

i will tell my results, kind regards
andreas

andreas23_07
NewUser
NewUser
Posts: 9
Joined: 14 Nov 2017 21:51
Status: Offline

Re: RAID 1 - replace a (functional) drive

#15

Post by andreas23_07 » 01 Dec 2017 14:06

I have carried out - successfully - replacing both discs in my physical NAS.

In both cases I had to forget two times:
- forget old disc

- forget !! new !! disc
- insert new disc

One Issue still remains:
When I am listing my harddiscs in "Harddsics - Management", my replaced discs schow filesystem "unknown or unformatted".
The other RAID1a show Filesystem "SoftRaid".

I did not succeed in pre-formatting the new discs to SoftRaid.

The newly replaced RAID works well, no data lost....
Is there something to worry about the wrong filesystem type?

kind regards,
Andreas

User avatar
Snufkin
Advanced User
Advanced User
Posts: 289
Joined: 01 Jul 2012 11:27
Location: Etc/GMT-3 (BSD style)
Status: Offline

Re: RAID 1 - replace a (functional) drive

#16

Post by Snufkin » 01 Dec 2017 22:53

andreas23_07 wrote:
01 Dec 2017 14:06
...In both cases I had to forget two times:
- forget old disc
- forget !! new !! disc
As you can see in gmirrow man pages forget applies to the mirror itself and not to particular disk. May be 'double forget' is a bug.
andreas23_07 wrote:
01 Dec 2017 14:06
The newly replaced RAID works well, no data lost....
Is there something to worry about the wrong filesystem type?
Actual information about disks could be found in Diagnostics | Information | Partitions page.

Disks | Management | HDD Management table just shows NAS4Free config data. That's why there are buttons to rescan buses and import data.
XNAS 11.3.0.4 embedded, ASUS P5B-E, Intel DC E6600, 4 GB DDR2, 2 x HGST HDN726040ALE614, 2 x WDC WD5000AAKS, Ippon Back Power Pro 400

Post Reply

Return to “Software RAID”