user3675188
user3675188

Reputation: 7409

How could I change the location of journal files

It seems the journal files still sotred at /var/lib/mongodb/journal even I pointed the location to /workspace/datastore

How could I save journal files in other places Because the root disk is almose full.

    ls
    prealloc.0  prealloc.1  prealloc.2
    pwd 
    /var/lib/mongodb/journal



systemLog:
    destination: file
    path: "/var/log/mongodb/mongodb.log"
    quiet: false
    logAppend: true
net:
    port: 27017
    bindIp: 0.0.0.0

storage:
    dbPath: /workspace/datastore
    engine: wiredTiger

Upvotes: 2

Views: 2987

Answers (1)

zangw
zangw

Reputation: 48356

Quoting here

You can create a symbolic link to point the journal directory at a different file-system / block device.

More details is Mongodb Journal.

Another option is limiting the size of Journal file, here is one discussion

Is it safe to delete the journal file of mongodb?

Upvotes: 1

Related Questions