BigChris Posted April 11, 2021 Share Posted April 11, 2021 I don't know what happened. I wanted to replace a data hard disk. The first thing I did was to replace the parity hard disk with a larger one. To do this, I plugged in the larger hard disk as a second parity hard disk. After the parity sync process, I removed the old parity hard disk. Then I replaced the data hard disk that I wanted to swap with the old parity hard disk. I did the following. - Array stopped - Set the data hard disk to none. - Shut down the server - Replaced data hard disk - Assigned new data hard disk to the hard disk slot. - Array started The hard disk was formatted by unraid and the rebuild process started. After the rebuild process, however, the new data hard disk was completely empty and the data of the old drive had disappeared! What happened? What did I do wrong when changing the data hard disk? Should I not have changed the file system? (I changed from btrfs to xfs). How do I proceed now? I still have the old data hard disk with the status before the removal. Can I simply get the data back? Quote Link to comment
itimpi Posted April 11, 2021 Share Posted April 11, 2021 2 minutes ago, BigChris said: The hard disk was formatted by unraid and the rebuild process started. What do you mean by this? There is no format step as part of a rebuild. Quote Link to comment
Squid Posted April 11, 2021 Share Posted April 11, 2021 7 minutes ago, BigChris said: After the rebuild process, however, the new data hard disk was completely empty and the data of the old drive had disappeared! 7 minutes ago, BigChris said: The hard disk was formatted by unraid Unraid does not automatically format a drive. If the drive came up as unmountable either prior to or after the rebuild process, a popup would have showed up that stated that "Formatting is never part of a rebuild process". Did you tell Unraid to format the drive? 7 minutes ago, BigChris said: Should I not have changed the file system? (I changed from btrfs to xfs) This is what caused the problem. By changing the format of the drive, it basically would've had to format the drive. (But still would have prompted you) 7 minutes ago, BigChris said: I still have the old data hard disk with the status before the removal. What you want to do is take a note of all the current drive assignments, do a Tools - New Config, and then reassign the drives and substitute the original data drive back in in lieu of the replacement. If anything comes up as unmountable, STOP and then post your diagnostics and wait for a response. Let parity rebuild and then do the substitution. After that, to change the format of the drive, you first have to copy all of the files off of that drive and then once it's empty format it. 1 Quote Link to comment
BigChris Posted April 11, 2021 Author Share Posted April 11, 2021 Just now, itimpi said: What do you mean by this? There is no format step as part of a rebuild. I'm afraid that was my mistake. I thought I could change the file system when replacing the hard disk. Before installing the new hard disk, I changed Disk2 (the slot where the hard disk was) from btrfs to XFS. I guess that was the mistake. What can I do now? Can I simply import the data manually - from the old disk to the new disk? Or how should I proceed? Quote Link to comment
itimpi Posted April 11, 2021 Share Posted April 11, 2021 If you did a format then that would create an empty file system and update parity to reflect this. When you try and format you get a big warning telling you that format is not part of a rebuild. if you still have the old disk intact it should be possible to mount it using UD and then copy the files back to the array. 1 Quote Link to comment
BigChris Posted April 11, 2021 Author Share Posted April 11, 2021 (edited) @itimpi 23 minutes ago, itimpi said: if you still have the old disk intact it should be possible to mount it using UD and then copy the files back to the array. I could also just upload the data again via FTP. I just don't know exactly what the right way is. Do I simply copy the data to hard disk 2? I mean on /mnt/disk2 or do I copy the data to the array, I mean /mnt/user and there into the respective folders. Or is squid's method the best way? Quote What you want to do is take a note of all the current drive assignments, do a Tools - New Config, and then reassign the drives and substitute the original data drive back in in lieu of the replacement. I'm worried about both right now.... Edited April 11, 2021 by BigChris Quote Link to comment
BigChris Posted April 11, 2021 Author Share Posted April 11, 2021 I decided to use the squid method. The parity is being rebuilt, I think it worked. Thank you both very much for the quick and great help. Quote Link to comment
BigChris Posted April 11, 2021 Author Share Posted April 11, 2021 1 hour ago, Squid said: After that, to change the format of the drive, you first have to copy all of the files off of that drive and then once it's empty format it. I have not yet understood the principle. Can I just take the data from disk2 (/mn7/disk2) and move it back up to disk2 after formatting? Won't that mess up the array (/mnt/user)? Quote Link to comment
Squid Posted April 11, 2021 Share Posted April 11, 2021 You need to move the files from /mnt/disk2 to mnt/diskX or to an unassigned drive (or completely off the array) (do NOT move to /mnt/user as you'll corrupt the files) then change the format, reformat and then move them back. See also Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.