Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Drive keeps being flagged as Unmountable: wrong or no file system

Featured Replies

Three times now I have reformatted a single drive that's in its own pool (as encrypted zfs) because it has randomly come up as Unmountable: wrong or no file system. And it just did it again. It's a new drive, there are no SMART errors. How can I force it to mount correctly? How do I prevent this from happening? This most recent occurrence appears to have happened after a hard shutdown of (loss of power to) the server.

I also noticed that after this hard shutdown the root user's authorized SSH keys were wiped, when before I had no issues with it retaining the keys.

metaverse-diagnostics-20261002-1002.zip

Edited by gusgus

Solved by JorgeB

Do not format the drive again. Your diagnostics show these errors before the filesystem mount attempt:

No key available with this passphrase.

hdd: Wrong encryption key

The HDD remains locked, so ZFS cannot read the filesystem inside it. This explains the later “wrong or no file system” message.

The same supplied key successfully unlocks your NVMe pool. Was the HDD formatted with the same passphrase or key file? Do you enter it manually after startup, or does a script or plugin supply it automatically? Unraid expects one shared key for all encrypted drives.

Please describe how you supply the key, but do not post the passphrase or key file. If you are certain the original credential is unchanged, we can investigate why the HDD rejects it. The diagnostics do not yet establish that power loss damaged the filesystem.

If you use the exact same passphrase or key file and it sometimes works but sometimes fails, an intermittent hardware problem, such as faulty RAM, is another possibility. I have seen that cause this behavior before. In that situation, a memory test would be a useful next step.

  • Author

The odd part is I have two pools, both formatted as encrypted zfs. They both have the same encryption passphrase. The other pool that I'm not having this problem with is unlocking just fine at bootup as expected. Why would one pool unlock perfectly fine using the keyfile and another pool repeatedly but only occasionally fail to unlock using that same keyfile? Is this still possibly a memory corruption issue? Unless I'm missing something, I would think it's time to file a bug report.

Edited by gusgus

9 minutes ago, gusgus said:

Is this still possibly a memory corruption issue?

Most definitely, or another hardware issue.

If it were an unload issue not giving the correct key, both pools would fail to unlock.

  • 2 weeks later...
  • Author

Ok finally I'm back. Here are the two scenarios that result in the HDD pool in not mounting and one scenario where it does mount.

As a reminder, I have two ZFS encrypted pools with the same passphrase.

Scenario 1: When I do the following, the HDD pool fails to unlock:

  1. Boot up with the keyfile in place.

  2. NVME pool succeeds to unlock

  3. HDD pool does not unlock and instead says "Unmountable: wrong or no file system"

Scenario 2: When I do the following, the HDD pool fails to unlock:

  1. Delete the keyfile

  2. Stop the array

  3. Start the array

  4. Enter the correct passphrase

  5. NVME pool succeeds to unlock

  6. HDD pool does not unlock and instead says "Unmountable: wrong or no file system"
    Note: The exact order of the steps I'm not sure of because right now it refuses to delete the keyfile (delete button > restart array > keyfile is still there).

Scenario 3: This causes the HDD pool to successfully mount
Start with the drive set to encrypted zfs filesystem

  1. Format (Yes I want to do this)

  2. The HDD pool is now unlocked and mounted
    The next time I reboot UnRAID and forever after it will refuse to mount without being reformatted as a workaround.

Edited by gusgus

  • Solution

Thanks for the detailed scenarios. You're right that this doesn't look like a RAM problem: it fails the same way every time, and bad RAM wouldn't do that. Looking at your diagnostics again, I think the cause may be the Encrypted Drive Manager plugin. Its auto-unlock is enabled. At every array start the syslog shows:

Auto-start is enabled. Proceeding with keyfile generation.

Attempting to generate hardware-tied key...

Keyfile generated successfully at /root/keyfile

Shortly after the array starts, it logs Keyfile at /root/keyfile has been securely cleared.

So the key Unraid uses at boot is not your passphrase. It is a key the plugin makes from your hardware. Your NVMe pool was most likely set up with the plugin, so it accepts that key. When you format the HDD later, it gets encrypted with whatever is in /root/keyfile at that moment. That is either your typed passphrase or the file the plugin already cleared, and either way it is not the plugin's hardware key. The drive works until the next reboot. Then the plugin supplies its own key again, and the HDD rejects it. The plugin also explains why the typed passphrase doesn't seem to be used and why the keyfile "comes back."

The easiest test is to remove the plugin. First, with the array started, confirm that your NVMe still accepts the passphrase, so you don't lock yourself out of it:

cryptsetup open --test-passphrase /dev/nvme0n1p1

Type the passphrase when asked. If it prints nothing, the passphrase is correct. If it prints No key available with this passphrase, it is wrong. In that case, don't remove the plugin; post the result here.

If the passphrase is accepted:

1. Remove the Encrypted Drive Manager plugin.

2. Reboot.

3. Start the array, typing your passphrase when asked.

If the HDD now mounts, the plugin was the cause. If the NVMe mounts but the HDD still doesn't, the HDD was probably encrypted with the cleared keyfile when you last formatted it, and its current contents can't be unlocked. In that case, format it one more time now that the plugin is gone, and it should keep working after reboots. If it fails again after that, post new diagnostics before you format anything.

  • Author

That was exactly it! I had totally forgot about Encrypted Drive Manager. I created the device-derived key on the drives and rebooted and HDD pool is now successfully automounted at bootup. Thank you!

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.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.