/storage/core/loginsight/var/runtime.log:[ERROR] [com.vmware.loginsight.services.EmbeddedService] [Error when starting service com.vmware.loginsight.analytics.distributed.LogSearchWorkerService]java.io.IOException: Failed to open bucket index at com.vmware.loginsight.ingestion.BucketIndex.openReader(BucketIndex.java:574) ~[ingestion-service.jar:?] at com.vmware.loginsight.ingestion.BucketIndex.getBucketsInfo(BucketIndex.java:459) ~[ingestion-service.jar:?] at com.vmware.loginsight.ingestion.BucketIndex.getValidBucketInfos(BucketIndex.java:199) ~[ingestion-service.jar:?] at com.vmware.loginsight.indexing.FSIndexStore.getReloadedBuckets(FSIndexStore.java:45) ~[ingestion-service.jar:?]
Aria Operations for Logs 8.x
The issue occurs due to corruption in the Cassandra bucket directory on the node, preventing the loginsight service from reading the bucket index.
This type of corruption typically occurs due to unexpected node shutdowns, often resulting from storage / power outages or similar disruptions.
Take a snapshot of all Aria Operations for Logs nodes before proceeding with below resolution.
service loginsight stopmv /storage/core/loginsight/cidata/store /storage/core/loginsight/cidata/store2service loginsight startNote : This will create new store folder with working buckets directory.
Once the bucket directory has been successfully created, follow the steps below:
service loginsight stop#!/usr/bin/env bash
for bucket in $(ls /storage/core/loginsight/cidata/store | grep -v 'generation\|buckets\|strata_write.lock'); do echo y | /usr/lib/loginsight/application/sbin/bucket-index add $bucket --statuses archived; done
cd /tmpchmod +x importer.shnohup ./importer.shps aux | grep importer.shroot@localhost [ ~ ]# ps aux | grep importer
root 1811 0.0 0.0 4124 3032 pts/0 S 15:32 0:00 /bin/bash ./importer.sh
root 1818 0.0 0.0 2452 760 pts/0 S+ 15:32 0:00 grep --color=auto importer
Note: As soon as output of command ps aux | grep importer.sh won't contain line with content importer.sh it means script is completed and you can go ahead and start loginsight service.
service loginsight start