[SERVER-13860] mongodump different behavior on dbpath dump Created: 07/May/14  Updated: 10/Dec/14  Resolved: 08/May/14

Status: Closed
Project: Core Server
Component/s: Tools
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: zlob Assignee: Thomas Rueckstiess
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

I have ReplicaSet and try to automate backup process.
There are secondary replica instance on host1:27017 and arbiter on host1:27018.
Process looks like:
1. stop mongod(host1:27017)
2. mongodump --dbpath /data/mongodb --out /tmp/backup --journal --directoryperdb
3. start mongod(host1:27017)
4. work with dump

If I run script from user shell It's work perfectly. But when I put It into cron, I don't receive any dumps and got "If you are running a mongod on the same path you should connect to that instead of direct data file access". All that time where was mongod.lock file in data directory.

Question is "why where are 2 different behavior in same environment?"



 Comments   
Comment by zlob [ 08/May/14 ]

Hi, can be closed, where was different environments. Thanks for reply.

Comment by Thomas Rueckstiess [ 07/May/14 ]

Hi,

If the mongod.lock file was present, it means the mongod process was still running. That would also explain the error message you are seeing. Can you double-check if the cron job is able to stop the mongod?

Thanks,
Thomas

Comment by zlob [ 07/May/14 ]

version 2.6.0

Generated at Thu Feb 08 03:33:07 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.