Unable to Wipe Replacement Drive in OpenMediaVault

I was replacing a failed drive in an existing array in OMV.  After I connected a replacement disk, I went to Multiple Device -> Recover.

However the list of available drives for recovery was blank.  The next step I tried was to format the replacement drive under Storage -> Disk -> select the drive -> Wipe button.

Do you really want to wipe the device /dev/XXX ? All data will be lost.
I clicked Confirm.

At that point the GUI threw an error:

Connection Lost

500 – Internal Server Error
Failed to execute command ‘export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; export LANGUAGE=; blockdev –rereadpt ‘/dev/XXX’ 2>&1′ with exit code ‘1’: blockdev: ioctl error on BLKRRPART: Device or resource busy

In the notification area, an error was also logged:

Failed to execute command ‘export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; export LANGUAGE=; blockdev –rereadpt ‘/dev/XXX’ 2>&1′ with exit code ‘1’: blockdev: ioctl error on BLKRRPART: Device or resource busy

OMV\ExecException: Failed to execute command ‘export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; export LANGUAGE=; blockdev –rereadpt ‘/dev/XXX’ 2>&1′ with exit code ‘1’: blockdev: ioctl error on BLKRRPART: Device or resource busy in /usr/share/openmediavault/engined/rpc/diskmgmt.inc:295
Stack trace:
#0 /usr/share/php/openmediavault/rpc/serviceabstract.inc(622): Engined\Rpc\DiskMgmt->Engined\Rpc\{closure}()
#1 /usr/share/openmediavault/engined/rpc/diskmgmt.inc(227): OMV\Rpc\ServiceAbstract->execBgProc()
#2 [internal function]: Engined\Rpc\DiskMgmt->wipe()
#3 /usr/share/php/openmediavault/rpc/serviceabstract.inc(122): call_user_func_array()
#4 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod()
#5 /usr/sbin/omv-engined(535): OMV\Rpc\Rpc::call()
#6 {main}

The reason for these errors is because the replacement disk had an existing superblock on it from another array.   When it was inserted into the OMV system, the system interpreted it as another array.  You can verify this by pulling up an OMV console and running the command:

cat /proc/mdstat

You should see listed your primary array marked as active, but also a second array marked as inactive and with only one device in it.  The device name will match the errors above and it represents the replacement drive.

Personalities : [raid6] [raid5] [raid4] [linear] [multipath] [raid0] [raid1] [raid10]
mdXXX : inactive XXX[20](S)

Now if you go back to Multiple Deive -> Recover, the list of drives is no longer blank and the GUI presents you with the replacement drive. However, if you select the drive and click the Save button, the GUI will throw a new error:

500 – Internal Server Error
Failed to execute command ‘export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; export LANGUAGE=; mdadm –manage ‘/dev/mdXXX’ –add /dev/XXX 2>&1′ with exit code ‘1’: mdadm: Unknown keyword INACTIVE-ARRAY mdadm: Cannot open /dev/XXX: Device or resource busy

And in the notification area:

Failed to execute command ‘export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; export LANGUAGE=; mdadm –manage ‘/dev/mdXXX’ –add /dev/XXX 2>&1′ with exit code ‘1’: mdadm: Unknown keyword INACTIVE-ARRAY
mdadm: Cannot open /dev/XXX: Device or resource busy

OMV\ExecException: Failed to execute command ‘export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; export LANGUAGE=; mdadm –manage ‘/dev/mdXXX’ –add /dev/XXX 2>&1′ with exit code ‘1’: mdadm: Unknown keyword INACTIVE-ARRAY
mdadm: Cannot open /dev/XXX: Device or resource busy in /usr/share/php/openmediavault/system/process.inc:247
Stack trace:
#0 /usr/share/openmediavault/engined/rpc/mdmgmt.inc(419): OMV\System\Process->execute()
#1 [internal function]: Engined\Rpc\MdMgmt->add()
#2 /usr/share/php/openmediavault/rpc/serviceabstract.inc(122): call_user_func_array()
#3 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod()
#4 /usr/sbin/omv-engined(535): OMV\Rpc\Rpc::call()
#5 {main}


You can see here the superblock on the replacement drive is causing an issue with the scripts due to the presence of an inactive array.

The solution is pretty straightforward:

  1. Disconnect the replacement drive and wait for it to spin down.
  2. Reattach it to OMV and wait for it to fully spin up.
  3. Find it in the list of Disks
  4. Use the GUI to perform a Wipe, either Quick or Secure.
  5. The wipe should completely successfully
  6. Navigate to Multiple Device and click Recover
  7. Select your replacement Disk
  8. Click Save to begin the recovery

At this point if you perform another scan of your arrays:

cat /proc/mdstat

You will still see the inactive array in the list. It wont cause any immediate problems to leave it, but you can flush it from the list by rebooting OMV.

Posted in Uncategorized | Leave a comment

Openmediavault GRUB failed to install, unable to identify a filesystem

When performing a manual apt-get upgrade command from the OMV CLI, I ran into this error when it tried to upgrade the grub-pc package.

grub-install: error: unable to identify a filesystem in hostdisk//dev/sdx; safety check can’t be performed.

where x is a device letter (e.g., sda, sdg, etc.)

The solution is pretty simple.

When presented with the Package configuration screen for grub-pc, there is the error:

GRUB failed to install to the following devices:


Do you want to continue anyway? If you do, your computer may not start up properly.

Writing GRUB to boot device failed – continue?

  1. Choose the option for No.
  2. Then find the correct boot device in the list and select it.  Double check that no other devices are selected.
  3. Continue with the install
Posted in Uncategorized | Leave a comment

Windows Backup Fails with Error 0x80780166 and 0x80070001

I was trying to perform a backup of the system C drive to another local storage D drive by using the Create a system image feature.  Each time the system image was attempted, it would result in the same error:

Windows Backup encountered an error when writing data to the backup target. (0x80780166)

Additional Information:
STATUS_WAIT_1 (0x80070001)

The system image had worked many times in the past, but it was now failing.   The only recent change to the system since then was upgrading the storage drive to a larger capacity and all the files had been migrated.

The solution was fairly simple.  I closed the Windows Backup tool and on the storage drive that had the previous backups, I found the folder titled WindowsImageBackup (located in the root of the drive).  I then renamed the folder (e.g., WindowsImageBackup-old).

When I attempted the backup again, it completed successfully.  Then I deleted the renamed folder to free up space.

Posted in Uncategorized | Leave a comment

Error 0x80070643 in Windows Update for KB5034441 (and Guide to Create a Windows RE partition)

This guide is how to resolve error 0x80070643 in Windows Update when trying to install 2024-01 Security Update for Windows 10 Version 22H2 for x64-based Systems (KB5034441).

The issue is related to either insufficient space in the existing recovery partition or the recovery partition does not exist at all as described in the below link. If you did a clean install of Windows 10, then the latter is likely the case.


You can resize an existing recovery partition or create a brand new recovery partition using the steps in this link:


If you are creating a brand new recovery partition, then on step 8  which is to re-enable WinRE (reagentc /enable) you will receive this error:

REAGENTC.EXE: The Windows RE image was not found.

As described in the below link, this error is caused by a missing or corrupted Windows RE image file (Winre.wim) in the folder C:\Windows\System32\Recovery.


To install a new Windows RE image, you will need to extract the file from a Windows 10 install disk or mounted ISO. If you don’t have an install disk or ISO, you can download one using the Media Creation Tool linked below:


On older Windows 10 install disks, the source file we need (install.wim) that contains the Windows RE image is located at X:\x64\Sources. For .wim files you can use the free utility 7-Zip to extract what is needed (skip to Step 6 below).

However if you have a newer Windows 10 install image, such as 22H2, then the location and file described above no longer exist on the install disk.  The newer file (install.esd) is located at X:\Sources\.

If you find you have an .esd file, then it must first be converted to a .wim file using these steps, adapted from the link below.

How to Extract Install.ESD to Install.WIM (Windows 10/8)

Note that in order to complete these steps, you will need adequate free space on your local disk (roughly 2 times the size of the install disk).

  1. Copy install.esd to a temporary location on your local drive.
  2. Open an elevated Command Prompt with Administrator rights to the same temporary location.
  3. Issue the following command to retrieve an index of available versions in the file.
    dism /Get-WimInfo /WimFile:install.esd
  4. You should see an output similar to the following below. Review the list and make note of the index number that corresponds to your version of Windows 10 (e.g., 6 for Windows 10 Pro):Details for image : install.esd

    Index : 1
    Name : Windows 10 Home
    Description : Windows 10 Home

    Index : 2
    Name : Windows 10 Home N
    Description : Windows 10 Home NIndex : 3
    Name : Windows 10 Home Single Language
    Description : Windows 10 Home Single Language

    Index : 4
    Name : Windows 10 Education
    Description : Windows 10 Education

    Index : 5
    Name : Windows 10 Education N
    Description : Windows 10 Education N

    Index : 6
    Name : Windows 10 Pro
    Description : Windows 10 Pro

    Index : 7
    Name : Windows 10 Pro N
    Description : Windows 10 Pro N

  5. Now export the .wim file using the command below. Replace IndexNumber with the number noted earlier (e.g., 6 for Windows 10 Pro).
    dism /export-image /SourceImageFile:install.esd /SourceIndex:IndexNumber /DestinationImageFile:install.wim /Compress:max /CheckIntegrity
  6. Once the export is complete, load 7-Zip file manager and navigate to the location of the newly created install.wim file.

  7. Double click on install.wim to open the archive.
  8. Inside you will see several folders. Navigate to the location:\Windows\System32\Recovery\ which contains Winre.wim

  9. Extract the Winre.wim file to your local Windows installation at the following location: C:\Windows\System32\Recovery

Before we can enable Windows RE, we must first set the location of the image file we just extracted as described in this link:


  1. Using an elevated Command Prompt, set the location of the file we just extracted:
    reagentc /setreimage /path C:\Windows\System32\Recovery
  2. Now issue the command to enable Windows RE:
    reagentc /enable
  3. You should be greeted with: REAGENTC.EXE: Operation Successful. You are now ready to retry the installation of Windows security update KB5034441
  4. Remove/unmount any installation media, close 7-Zip File Manager and delete the files install.esd and install.wim.


Posted in Uncategorized | Leave a comment

Unable to Delete Single Shadow Copy Restore Point with Error: Invalid option value.

I was looking to delete a specific restore point on a Windows 10 machine using the command line.  There are several guides available out on the web. For example:



Also the ofifical Microsoft guide:


You can also reference the built in help for vssadmin using the command line (e.g, type vssadmin delete shadows)

Delete Shadows /For=ForVolumeSpec [/Oldest] [/Quiet]
Delete Shadows /Shadow=ShadowId [/Quiet]
Delete Shadows /All
– For the given ForVolumeSpec deletes all matching shadow copies.
If /Oldest is given, the oldest shadow copy on the volume is deleted
If /All is given, then all shadow copies on all volumes that can be deleted will be deleted. If /Shadow=ShadowId is given, the shadow copy with that Shadow Copy ID will be deleted. Only shadow copies that have the ClientAccessible type can be deleted.
– The Shadow Copy ID can be obtained by using the List Shadows command. When entering a Shadow Copy ID, it must be in the following format:
where the X’s are hexadecimal characters. This ID can be obtained
through the List Shadows command.

Example Usage: vssadmin Delete Shadows /For=C: /Oldest

I was using the /Shadow=ShadowId option, but always received the error:

vssadmin delete shadows /shadow={aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee}

Error: Invalid option value.

What finally solved it for me was to NOT use PowerShell.  Using the identical command in Command Prompt was successful and you should be presented with:

Do you really want to delete 1 shadow copies (Y/N): [N]?

Posted in Uncategorized | Leave a comment

Ubuntu Focal Error NO_PUBKEY B7B3B788A8D3785C When Apt Update for MySQL

I was getting this error on Ubuntu 20.04 LTS with MySQL version 8.0.35.

Err:1 http://repo.mysql.com/apt/ubuntu focal InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY B7B3B788A8D3785C

After some research, I tried several suggestions that I found at the links below, but they did not resolve the issue.





However, finally came across this link which did have a solution:

Below are the steps to quickly fix it:

  1. Download an updated .deb file from the official mysql site:
  2. Install the deb (e.g., mysql-apt-config_0.8.29-1_all.deb):
    sudo dpkg -i <filename>
  3. Then run apt-get update again and the error should not appear.


Posted in Uncategorized | Leave a comment

Windows Store (and other Windows Apps) Crashes and Closes Automatically in Windows 10

Some background: On a Windows 10 machine I had to recreate an existing user profile  due to some corruption. I followed this guide (except for the step related to ProfileGuid in the registry, since it does not exist in Windows 10):


Everything worked great and I was able to log on. However I quickly realized none of the built in Windows Apps worked.  They would open and then very quickly close without any error message window.

Each of these apps could be fixed quite easily using the Start Menu -> type: Apps -> launch Apps & features.  Find the problematic app, click Advanced options. First choose the Terminate button. Then choose the Reset button. The app then worked without crashing instantly.

However this same issue occurred with Microsoft Store, but that app unfortuantely is not in the Apps & features list.

Event viewer did have information for these crashes. For example

Faulting application name: WinStore.App.ex
Faulting module name: KERNELBASE.dll, version: 10.0.19041.3758
Exception code: 0xc000027b
Fault offset: 0x000000000012db22
Faulting application start time: 0x01da427eb19954ed
Faulting application path: C:\Program Files\WindowsApps\Microsoft.WindowsStore_22311.1401.2.0_x64__8wekyb3d8bbwe\WinStore.App.exe
Faulting module path: C:\Windows\System32\KERNELBASE.dll
Faulting package full name: Microsoft.WindowsStore_22311.1401.2.0_x64__8wekyb3d8bbwe
Faulting package-relative application ID: App

I tried to reset Microsoft Store using Start menu -> type: wsreset utility.  However that failed and would generate the error -2147219196 related to PurgeCaches.

I also tried uninstalling and reinstalling Microsoft Store via PowerShell.  Each of these was successful but didn’t fix the problem.

Finally I stumbled on this article:

Microsoft Store missing in Apps & Feature – Microsoft Community

This helped me resolved the issue and you can follow these quick steps:

  1. Uninstall Microsoft Store using PowerShell (admin):
    get-appxpackage *WindowsStore* | remove-appxpackage
  2. Start Menu -> type: Apps -> launch Apps & features
  3. Uninstall Xbox app
  4. Uninstall Xbox Live app
  5. Reinstall Xbox app via this link https://aka.ms/XboxInstaller
  6. Launch Xbox app
  7. At the top you should see a notification that Microsoft Store is needed.
  8. Click it to install Microsoft Store using the Xbox App
  9. Once complete, Microsoft Store should now be functional!
Posted in Uncategorized | Leave a comment

Run-time error ‘713’ on Windows 10

I tried running an old program and received this error message:

Run-time error ‘713’
Class not registered.
You need the following file to be installed on your machine.

Here are the steps to solve it using an official dll file sourced from Microsoft:

  1. Download Microsoft Visual Basic 6.0 Service Pack 6 Cumulative Update from:
  2. Extract the package to a folder using a utility such as 7zip.  Copy msstdfmt.dll to: C:\Windows\SysWOW64
  3. Open a command prompt (cmd.exe) with administrator privileges.
  4. Issue the command:
    regsvr32 c:\windows\syswow64\msstdfmt.dll
  5. Try running the program again


  1. https://support.microsoft.com/en-us/topic/description-of-the-cumulative-update-rollup-for-the-visual-basic-6-0-service-pack-6-runtime-extended-files-e02acc79-217b-fc0a-6edc-540403af2081
  2. https://superuser.com/questions/519841/getting-msstdfmt-dll-missing-when-starting-visual-basic-6-application


Posted in Uncategorized | Leave a comment

EA Origin App Error for Invalid License Missing DLL gfsdk_aftermath_lib.x64.dll

You may receive an error when trying to play a game on the EA App (Origin based games).

We’re sorry, an error has occurred
Invalid license. Reason code = Missing DLL: [gfsdk_aftermath_lib.x64.dll]
Error: 0x45A.

Clicking Exit results in another error:

Easy Anti-Cheat
Untrusted system file (C:\Windows\System32\msvcp140.dll)

Searching for a solution you may come across several threads about the issue on the EA community forums:




The suggested fixes varied from things such as changing video card drivers, rolling back Windows to a previous restore point, reinstalling the game, reinstalling the EA App and reinstalling Visual C++ 2015.

The biggest clue was found in this thread:


The solution?  To install Visual C++ Redistributable for Visual Studio 2015, however you need the “2015-2022” Redistributable and NOT the 2015 Redistributable

Below is the 2015 version (published on 10/07/2015) suggested in one of the forum threads. It may already be on your system and will NOT fix the problem:

This is the 2015-2022 Redistributable that WILL solve the problem and eliminate the errors.  Installing this will replace any previous versions of the 2015 Redistributable that may already be installed on your system.  Install both the x86 and the x64 versions

Note: For reference, the permalinks for the 2015-2022 Redistributable files listed above are sourced from this Microsoft website:

Posted in Uncategorized | Leave a comment

Error Running Thaiphoon Burner on Windows 7

I was trying to run the latest Thaiphoon Burner on Windows 7 and was having no luck. At the time of this guide, the Thaiphoon Burner version was build 0902 Final.

When trying to launch, the first message was:

The kernel mode driver of Thaiphoon Burner is blocked from being installed by Windows operating system or antivirus software. This exception may also occur if you do not have sufficient administrative privileges.

In this case the error message was not relevant, because Windows 7 was a fresh install without a 3rd party antivirus. I was also using the system Administrator account.

After Thaiphoon Burner loaded, a second error message was shown:

Thaiphoon Burner has not detected any SPD EEPROM device! The most possible reasons for this is an unspoported SMBus Controller, your antivirus software or the latest Windows 11 operating system with enabled Smart App Control that blocks Thaiphoon’s drive from being installed.

If this is a permanent error, please disable your antivirus software or refer to the READFIRST.txt file to get more information on this issue.

I reviewed the READFIRST.txt but it did not contain anything about Windows 7, so it was a bit of a dead end.

The next step was to try disabling Windows Defender real-time protection as well as User Account Control.  However, the result was the same.

Then at some point, Windows provided the biggest clue with a message from the Program Compatibility Assistant:

Windows requires a digitally signed driver

A recently installed program tried to install an unsigned driver. This version of Windowws requires all drivers to have a valid digital signature. The driver is unavailable and the program that uses this driver might not work correctly. Uninstall the program or device that uses this driver and check the publisher’s support website to get a digitally signed driver.

Driver: MICSYS IO driver
Service: Thaiphoon Burner Low-level Access Driver
Publisher: MICSYS Technology CO., LTd
Location: C:\Windows\SysWOW64\drivers\TbsbIo64.sys

The solution was to disable the requirement for digitally signed drivers. The steps:

  1. Reboot
  2. Before the Windows logo, press F8
  3. Choose the option for: Disable Driver Signature Enforcement

Once Windows boots with this option enabled, Thaiphoon Burner should now load successfully. Keep in mind this is a temporary solution until the next time the system is restarted.



Posted in Uncategorized | Leave a comment