File History may have been working all these years correctly. But, of late, you may have noticed that File History backups stopped working even though the File History settings page says the feature is turned on.
To make it work again, users may attempt to clean up old versions of File History backups to free up the disk space. However, doing so may cause the error “The parameter is incorrect.” Here’s the full error message verbatim:
File History Cleanup Could not clean up File History data The parameter is incorrect.
The Event Viewer may show the following entry for each failed File History Backup attempt:
Log Name: Microsoft-Windows-FileHistory-Engine/BackupLog Source: Microsoft-Windows-FileHistory-Core Date: 1/21/2022 12:41:49 PM Event ID: 200 Task Category: None Level: Error Keywords: User: SYSTEM Computer: OptiPlex-9020 Description: Unable to start a backup cycle for configuration C:\Users\Ramesh\AppData\Local\Microsoft\Windows\FileHistory\Configuration\Config
Also, when you attempt to view or restore the previously backed up File History data, the page may show the message “No file history was found” and suggests that the user clicks on the “Configure File History settings link”. This may happen even though the data is still intact in the File History storage drive.
In some cases, the File History applet in the Control Panel may show “Unknown error” and “File History doesn’t recognize this drive”.
The File History backup failure (and the “The parameter is incorrect” error) is caused by the incorrect data in the File History configuration (
For instance, if you rename your computer, the File History configuration would still reference the old computer name. This blocks the File History application from querying the File History configuration. Thus, the user will be unable to view or restore the previously backed up data, although the files are intact in the File History storage drive.
Fix File History “The parameter is incorrect” Error
You can fix the File History error “The parameter is incorrect” by renaming the File History configuration XML files
config2.xml. Alternately, you can fix the contents of the XML file(s) manually (preferred option) so that your earlier File History customizations are preserved.
Step 1: Update the Configuration File
If you’ve renamed your computer earlier, edit the File History configuration files using Notepad and update the computer name accordingly in the XML file.
Note: If you have NOT renamed the computer and yet the “The parameter is incorrect” error occurs, follow the steps listed under the “Still does not work” section in this article.
- Open File Explorer and navigate to this folder:
(Copy the above path and paste it in Explorer address bar and hit Enter)
- Rename the file named
- Open the file
- Update the computer name in the XML file.
Around six months back, I renamed my computer to
OptiPlex-9020from the previous name
DESKTOP-JKJ4G5Qand that’s when File History stopped working. All I had to do was change the
<PCName>data accordingly in the XML file.
<?xml version="1.0" encoding="UTF-8"?> <DataProtectionUserConfig SchemaVersion="1"> <UserName>ramesh</UserName> <FriendlyName>Ramesh Srinivasan</FriendlyName> <PCName>DESKTOP-JKJ4G5Q</PCName> to the following: <?xml version="1.0" encoding="UTF-8"?> <DataProtectionUserConfig SchemaVersion="1"> <UserName>ramesh</UserName> <FriendlyName>Ramesh Srinivasan</FriendlyName> <PCName>OptiPlex-9020</PCName>Hint: To quickly find your computer name, open a Command Prompt window and type the command “
hostname“. Alternately, press the WinKey + Pause|Break key to open the About page in the Settings dialog directly. It shows the name (“device name”) of your computer.
- Delete the line that starts with the tag
<UserId>line. This is important!
- Save the XML file and close Notepad.
Step 2: Reconfigure File History
- Launch the Services MMC console by running
services.mscvia the Start/Run dialog.
- Right-click “File History Service” and click Restart.
- Close the Services console.
- Now, open the File History page in the Control Panel to reconfigure File History.
- Click on the “Turn on” button.
- Enable the checkbox “I want to use a previous backup on this File History drive” if you need access to the previously backed up data. Of course, this assumes that you’re still using the same drive for File History backup and got it connected already.
- Select the existing backup from the list. Don’t bother even if it shows the old computer name in that list view box below.
- Once done, click on the “Advanced settings” link in the left pane.
- Select the “Save copies of files” and “Keep saved versions” options accordingly.
(If you need to clean up older versions of File History data, you can do so. You should no longer see the “The parameter is incorrect” error now.)
- Click on the Save changes button.
If updating the computer name in the
Config1.xml manually doesn’t work, then follow these steps:
- Rename the files
- Restart File History Service via the Services MMC.
Now, File History will regenerate fresh copies of
Config2.xml(which is a replica of
Config1.xml). However, your customizations, such as the “excluded folders” list, backup retention period (days/months/years) data, are lost. You’ll need to reconfigure the File History Backup options via Settings → Update & Security → Backup → Backup using File History → More options.
- Reconfigure File History Backup Options (Include/Exclude folders/Backup retention) via Settings.
- If you need to change the storage device, you need to reconfigure File History via Control Panel.
The File History backup feature on your computer should be good to go!
And yes, as you can see above, you should be able to view or restore your older File History backups as well.
One small request: If you liked this post, please share this?One "tiny" share from you would seriously help a lot with the growth of this blog. Some great suggestions:
- Pin it!
- Share it to your favorite blog + Facebook, Reddit
- Tweet it!