How can I delete a disks error history

Currently reading
How can I delete a disks error history

2
2
NAS
1812+
Operating system
  1. Windows
I have an 1821+ running DSM 6.2.4, it is loaded with Seagate Ironwolf 12TB drives in a RAID 5 configuration.
I run monthly extended smart tests and this picked up a problem with one of my disks and reported that is failing, resulting in the raid array being abnormal.

I pulled the drive and put it into my PC and ran Seatools on it which also showed an error, but then I ran the Seatools Fix tool on the drive which appears to have repaired it and Seatools no longer produces errors for it. But when I plug it back into the NAS it remembers the old error and still shows the drive as failing. The RAID array is now degraded as it is no longer using that disk.
I then did a full erase of the disk and I still get the historical errors being displayed in the NAS and I can't seem to add the drive back to the RAID array.

Is there anyway of scrubbing the drive health/error history from the NAS so that the drive will look healthy?
If it is easier I am happy to delete the health/error history for all drives.

Or better still, can I delete any history from the NAS that this drive had ever been installed?
Again, I would be happy to purge all history on all drives if it is easier but I would like to keep the RAID array and it's data intact.

I would want to avoid a factory reset of my NAS but I do have backups of all the data if that becomes necessary.

I did pose this question on the offical Synology Community forums and got the response that I could
  • edit the Synology database file that stores this information
  • edit the drive ID number
But they couldn't detail how to do either there.
I have read that it is possible to edit the drive to change it's serial number, but I don't want to do that as it is only 3 months old and would mess with the warranty.

Thank You
 
Solution
See posts towards the end of Reset drive "critical" state
I have no direct experience of doing this; ymmv etc. Note that it's possible that Synology may have renamed or changed the location of the HDD db in question since this thread was made.

Before doing step4, I'd recommend making a backup of the original drive db just in case you need to restore:
cp /var/log/synolog/.SYNODISKDB /var/log/synolog/.SYNODISKDB.original
Would love to know how to do it.
I have an old disconnect error count on a drive since… 5 years ! due to a disk not correctly inserted. Never found a safe way to reset the error.
 
Upvote 0
many versions ago it was :
  • SSH to your DiskStation
  • change directory to <root>/var/log
  • edit/delete disk_log.xml

But not sure if it is still there....
 
Upvote 0
Last edited:
See posts towards the end of Reset drive "critical" state
I have no direct experience of doing this; ymmv etc. Note that it's possible that Synology may have renamed or changed the location of the HDD db in question since this thread was made.

Before doing step4, I'd recommend making a backup of the original drive db just in case you need to restore:
cp /var/log/synolog/.SYNODISKDB /var/log/synolog/.SYNODISKDB.original
 
Upvote 0
Solution
That looks to be the right database. Following from @Fortran with the linked post and backing up the database to ...original. You can get a listing of the data in the database with this sqlite3 command. I've converted the time date in each entry to human-readable and added it as a new column at the beginning.
Bash:
sudo cp /var/log/synolog/.SYNODISKDB /var/log/synolog/.SYNODISKDB.original

sudo sqlite3 /var/log/synolog/.SYNODISKDB
.headers on
select strftime('%Y-%m-%d %H:%M:%S', datetime(time, 'unixepoch')),* from logs;
.exit
 
Upvote 0
Hello everyone
Thank you all for taking the time to reply with the information.

Though as well as editing the .SYNODISKDB file I edited the .SYNODISKHEALTHDB file in case some information was in there.

This disk is back in my NAS with a Normal allocation status and specified as being healthy
I am in the process of repairing the RAID array after which I will do another extended test and hopefully all will be well.
 
Upvote 0

Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.

Similar threads

Hi, This code will delete oldest data or recently data? I also want to delete oldest data to newest...
Replies
2
Views
4,138
It is a windows issue. Try to clear the network logins en clear DNS Go to windows credentials manager and...
Replies
1
Views
369
Thanks for the uber fast reply. No, I didn't mix the bays up. 2-4 were 8 TB drives and 1 was the oldest...
Replies
2
Views
3,510

Welcome to SynoForum.com!

SynoForum.com is an unofficial Synology forum for NAS owners and enthusiasts.

Registration is free, easy and fast!

Back
Top