Error: unable to open database file: no such file or directory

I’m not able to get my node online for some reason. It had been working fine so I’m not sure what changed.

2024-08-14T10:21:53-07:00 ERROR failure during run {“Process”: “storagenode”, “error”: “Error opening database on storagenode: database: orders opening file "config/storage/orders.db" failed: unable to open database file: no such file or directory\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openDatabaseWithStat:407\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openDatabase:384\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openExistingDatabase:379\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openDatabases:354\n\tstorj.io/storj/storagenode/storagenodedb.OpenExisting:319\n\tmain.cmdRun:67\n\tmain.newRunCmd.func1:33\n\tstorj.io/common/process.cleanup.func1.4:392\n\tstorj.io/common/process.cleanup.func1:410\n\tgithub.com/spf13/cobra.(*Command).execute:983\n\tgithub.com/spf13/cobra.(*Command).ExecuteC:1115\n\tgithub.com/spf13/cobra.(*Command).Execute:1039\n\tstorj.io/common/process.ExecWithCustomOptions:112\n\tmain.main:34\n\truntime.main:271”, “errorVerbose”: “Error opening database on storagenode: database: orders opening file "config/storage/orders.db" failed: unable to open database file: no such file or directory\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openDatabaseWithStat:407\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openDatabase:384\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openExistingDatabase:379\n\tstorj.io/storj/storagenode/storagenodedb.(*DB).openDatabases:354\n\tstorj.io/storj/storagenode/storagenodedb.OpenExisting:319\n\tmain.cmdRun:67\n\tmain.newRunCmd.func1:33\n\tstorj.io/common/process.cleanup.func1.4:392\n\tstorj.io/common/process.cleanup.func1:410\n\tgithub.com/spf13/cobra.(*Command).execute:983\n\tgithub.com/spf13/cobra.(*Command).ExecuteC:1115\n\tgithub.com/spf13/cobra.(*Command).Execute:1039\n\tstorj.io/common/process.ExecWithCustomOptions:112\n\tmain.main:34\n\truntime.main:271\n\tmain.cmdRun:69\n\tmain.newRunCmd.func1:33\n\tstorj.io/common/process.cleanup.func1.4:392\n\tstorj.io/common/process.cleanup.func1:410\n\tgithub.com/spf13/cobra.(*Command).execute:983\n\tgithub.com/spf13/cobra.(*Command).ExecuteC:1115\n\tgithub.com/spf13/cobra.(*Command).Execute:1039\n\tstorj.io/common/process.ExecWithCustomOptions:112\n\tmain.main:34\n\truntime.main:271”}
Error: Error opening database on storagenode: database: orders opening file “config/storage/orders.db” failed: unable to open database file: no such file or directory

Do you see orders.db file on your disk ?

1 Like

Would that be on the storage disk or in the docker container.

If the storage disk, I do see orders.db in storage/storage/

is your docker configured with db storage in a different location? (app/dbs in a different place, like a ssd)?

if it’s in the regular storage folder… is the folder okay? do you and storj have read/write permission and is it out of space?

Check if its malformed

I have the storj docker running on an SSD and the storage disk is seperate.

so probably the docker command/compose has the wrong path,
or the config.yaml doesn’t have storage2.database-dir: set,
or something happened in the SSD location and it’s not there or not writeable any more (also full disk, etc).

1 Like

Hello @Pandemic,
Welcome back!

This is mean either the path to the storage location is incorrect (it usually shouldn’t include the /storage subfolder as a last element in the path), or you moved databases here, but not set

to that location.

Could you please show a content of the parent folder of the /storage/storage sub path?
Please use ls -l for that location.
Also please show the content of the first storage subfolder and the second.

1 Like