Hello all, I would like to ask regarding the Cassandra error as shown below:
It seems that the DMA has trouble offloading files to Cassandra cluster due to the database being in locked.
When I checked the offload folder on the server, there is still the issue of sqlite data not being offloaded due to the database being locked.
Using a 3rd party tool like DB Browser still shows that the sqlite file created by DataMiner is indeed locked:
Is there any procedure am I missing to fix this error? Thank you for the help.
Hi Min,
In this context locked means that some other process is using the database, and locking it to prevent other processes from interfering with the data. Could you please verify that no other process is connecting to this database? There could be some leftover connection from other processes, easiest way to make sure no one is connecting would be to restart the machine, although if the connection is being made on startup it might not help in your case. Another thing that you could do is change the port of Cassandra in cassandra.yaml and in db.xml in DataMiner. This way even if connection exists, it will stop working since you "moved the location" of Cassandra and you should be able to connect to it.
Edit:
This concept is not present in Cassandra, but is present in SQLite which is the source of your error. You could try stopping all DMA processes and then trying to access the database using 3rd party software, to verify if DMA is in fact source of the lock.
Cheers
Hi Edib, the sqlite files were moved to a different folder location. A 3rd party tool is then used to try to open the files. Attempt to open the sqlite3-wal files resulted in a request for a password to de-crypt the file. Attempt to open the sqlite3 file was successful. So there is no ‘lock’ error observed. This probably indicates that DataMiner was locking the file. But if DataMiner is reporting that the file is locked upon boot up, could that possibly suggest that multiple processes within DataMiner are operating on that file simultaneously?
Hi Bing,
Base on this document ‘https://docs.dataminer.services/user-guide/Advanced_Functionality/DataMiner_Systems/About_DataMiner_Systems/DataMiner_processes.html?q=processes’ multiple DataMiner processes communicate with database (SLDataGateway, SLDataMiner, SLElement for legacy databases, and SLAnalytics) although they all seem to be doing different things, and locking each other shouldn’t happen. Could you take a look at it and see if you can find anything useful? I’m afraid that I don’t have any other ideas.
Another note is that base on ‘https://docs.dataminer.services/user-guide/Advanced_Functionality/Databases/Optional_database_configurations/Offload_database.html?q=offload’ Cassandra can’t be used for offloading, I might be wrong just thought I’d make sure you are aware of it as well.
Hello Edib, I believe there is no process using those files and even after we did the DMA restart, the files were still being there and not being offloaded as well.