USB boot drive "DEGRADED" - replacing/attaching new one fails; new installation fails at "unlocking"

stn

Cadet
Joined
Sep 28, 2019
Messages
2
Hello everyone,

my USB drive (Transcent Jet Flash 700 with 32GB) is "degraded". Therefore, I wanted to replace it. From what I have read I should install FreeNAS on a new USB drive and upload my old configuration file which I have saved before. I have downloaded the geli.key and the geli recovery key.
Everything is fine up to the point where I want to unlock my encrypted drive after new installation. It fails with an error message. On the command line, it tells me something like "zpool with ID XXX not found".

At this point I booted the USB drive and clicked in boot environments to "replace" respectively to "attach" a new drive I bought. This fails, too, because "operation not permitted".

Somewhere else here in the forum, someone suggested the problem is the encryption. I am okay with removing it.

To the system:
Dell T20
4*4GB ECC RAM
4*4TB of different drive types
FreeNAS 11.2-U5

One drive has 8 Offline uncorrectable sectors which is why I would also buy a new drive (probably the 4TB WD RED).

If you need more information or the exact error messages, please don't hesitate to ask :)


Thank you in advance for your help!
 
Joined
Oct 18, 2018
Messages
969
From what I have read I should install FreeNAS on a new USB drive and upload my old configuration file which I have saved before. I have downloaded the geli.key and the geli recovery key.
These are, in fact, the files you'll need to download in order to properly migrate to a new boot disk. It is best to have these backed up BEFORE the usb stick becomes degraded. If you're not using any kind of parity with your boot media it is possible that one of these files could have become corrupted. It isn't necessarily hugely likely, but possible. Alternatively, your boot media could outright fail one day; another reason to have the backups ahead of time.

Everything is fine up to the point where I want to unlock my encrypted drive after new installation. It fails with an error message. On the command line, it tells me something like "zpool with ID XXX not found".
How exactly are you trying to go about doing this? In the GUI there is an option to import an encrypted pool; this is the option you want. You'll want to provide your geli.key and any passphrase you have set to perform the import. Where possible try to use the GUI rather than the command line; it helps ensure that all of the zfs flags and settings that FreeNAS expects are used.

At this point I booted the USB drive and clicked in boot environments to "replace" respectively to "attach" a new drive I bought. This fails, too, because "operation not permitted".
Can you be a bit more clear? Are you saying you tried to replace the single USB boot device? If you've already installed FreeNAS on the new boot media and uploaded your configs etc you shouldn't need to the old disk. It may be best to focus on one approach; trying to import the drives using the new boot device.

Somewhere else here in the forum, someone suggested the problem is the encryption. I am okay with removing it.
There are certainly folks who find that the encryption is not worth it. Unless you've found a bug though the issue is likely either you're not following the proper steps or you have the incorrect keys. I've played with encryption quite a lot on my systems and have found that it functions as expected; the issue is sometimes folks have the wrong expectations and FreeNAS uses some very unfortunate naming conventions in places that can make it confusing. :)

One drive has 8 Offline uncorrectable sectors which is why I would also buy a new drive (probably the 4TB WD RED).
Can you be a bit more specific? Which exact drive is it? Is it the drive in your encrypted pool? If so, lets try to get the pool imported before you do any resilvering/replacing of this drive. You will probably want to pick up the extra drive though and burn it in so it is ready when you've got everything imported and unlocked.

If you need more information or the exact error messages, please don't hesitate to ask :)
In general, always provide as much information as you can up front. It helps prevent folks on the forums having to ask a ton of follow up questions before beginning to troubleshoot your issue. For example, a good start would be to always post all of your hardware, your pool layout, which pools are using encryption, your FreeNAS version, any error messages reproduced exactly as well as the exact command or steps that were taken to produce it.
 

stn

Cadet
Joined
Sep 28, 2019
Messages
2
Hello PhiloEpisteme,
thank you very much for your reply. I had to work and not much time to answer. I tested today a second time.

When the health status of the old usb thumb drive changed, I bought 2 new drives. When I tested the first time, I used the import command to use my old configuration and this seems to be broken, at least for my configuration. Now, I simply started from a blank new configuration and imported the encrypted disks and this went very well. Unfortunately, I had to configure everything by myself a second time.
I also added my second new thumb drive as a mirror for the boot pool so in case one fails I still have one left.

To the failing drive: I copied the output of smartctl in here. It seems that some sectors are broken. But the pool status itself is fine so I won't exchange the drive yet.

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE
1 Raw_Read_Error_Rate 0x000f 116 099 006 Pre-fail Always - 117283592
3 Spin_Up_Time 0x0003 092 091 000 Pre-fail Always - 0
4 Start_Stop_Count 0x0032 100 100 020 Old_age Always - 224
5 Reallocated_Sector_Ct 0x0033 100 100 010 Pre-fail Always - 0
7 Seek_Error_Rate 0x000f 081 060 030 Pre-fail Always - 132801825
9 Power_On_Hours 0x0032 072 072 000 Old_age Always - 24548
10 Spin_Retry_Count 0x0013 100 100 097 Pre-fail Always - 0
12 Power_Cycle_Count 0x0032 100 100 020 Old_age Always - 224
183 Runtime_Bad_Block 0x0032 100 100 000 Old_age Always - 0
184 End-to-End_Error 0x0032 100 100 099 Old_age Always - 0
187 Reported_Uncorrect 0x0032 100 100 000 Old_age Always - 0
188 Command_Timeout 0x0032 100 100 000 Old_age Always - 0 0 0
189 High_Fly_Writes 0x003a 100 100 000 Old_age Always - 0
190 Airflow_Temperature_Cel 0x0022 060 048 045 Old_age Always - 40 (Min/Max 39/41)
191 G-Sense_Error_Rate 0x0032 100 100 000 Old_age Always - 0
192 Power-Off_Retract_Count 0x0032 100 100 000 Old_age Always - 3
193 Load_Cycle_Count 0x0032 083 083 000 Old_age Always - 34500
194 Temperature_Celsius 0x0022 040 052 000 Old_age Always - 40 (0 14 0 0 0)
197 Current_Pending_Sector 0x0012 100 100 000 Old_age Always - 8
198 Offline_Uncorrectable 0x0010 100 100 000 Old_age Offline - 8
199 UDMA_CRC_Error_Count 0x003e 200 200 000 Old_age Always - 0
240 Head_Flying_Hours 0x0000 100 253 000 Old_age Offline - 24203h+18m+16.971s
241 Total_LBAs_Written 0x0000 100 253 000 Old_age Offline - 42211379783
242 Total_LBAs_Read 0x0000 100 253 000 Old_age Offline - 329178138756
 
Top