Splunk Enterprise

Generate hashes for buckets that were created before data integrity control was enabled

jniedrauer
Engager

After enabling data integrity control for an index, I cannot find a way to generate hashes for existing buckets.

`./splunk generate-hash-files` returns `Error: Cannot generate hash files for the bucket with path=/bucket/path, Reason=Journal has no hashes.`

Rebuilding the buckets with:

`./splunk fsck repair` does not generate hashes for the old buckets.

Is this possible? Or are all buckets that were created before this option was enabled impossible to validate, even after the feature has been enabled?

Labels (1)

jniedrauer
Engager

Interesting. So to be clear, in your experience, there is no way to retroactively create hashes for a journal?

0 Karma

hmallett
Path Finder

It's many years since I had to deal with the details of enableDataIntegrityControl, and the detail in the documentation misses some of the detail that I'm sure I learned years ago.

My memory is that when you enable data integrity control the hashes of the data are written with each slice in the data (this isn't mentioned in the documentation), and a copy of the hashes are stored in files in the raw data for the bucket (this is mentioned in the documentation).

When you run the check-integrity command the hashes from within the data are verified against the hash files. When you run the generate-hash-files command it will generate the hash files from the hashes stored in each slice. It won't create the hashes against each slice. That is only done when a slice is written.

As I say, it was many years since I had to deal with the detail of this, so things may have changed, or I may have misremembered, but that would explain why you don't get the results you're hoping for.

0 Karma
Get Updates on the Splunk Community!

Enterprise Security Content Update (ESCU) | New Releases

In December, the Splunk Threat Research Team had 1 release of new security content via the Enterprise Security ...

Why am I not seeing the finding in Splunk Enterprise Security Analyst Queue?

(This is the first of a series of 2 blogs). Splunk Enterprise Security is a fantastic tool that offers robust ...

Index This | What are the 12 Days of Splunk-mas?

December 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...