[SERVER-24295] mongod service pid is different in /var/run/mongo and actual running service pid Created: 26/May/16  Updated: 22/Jul/16  Resolved: 22/Jul/16

Status: Closed
Project: Core Server
Component/s: Admin, Packaging
Affects Version/s: 3.0.6
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Tejaskumar Assignee: Kelsey Schubert
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: HTML File mongod     File mongod.conf    
Issue Links:
Duplicate
duplicates SERVER-23830 On RHEL7/Centos7 mongod can't stop if... Closed
Participants:

 Description   

MongoDB v3.0.6 CentOS -6.5
**********************

  • Mongod service goes into unstable state after successive start/stop operation.
  • Very easy way to reproduce this issue is start already running service mongod in linux with /etc/init.d/mongod start
  • Now, situation will be that if you check with ps -fax then service will be running with PID as below,

26138 ? Sl 0:07 /usr/bin/mongod -f /etc/mongod.conf

And if you check PID in /var/run/mongod
cat /var/run/mongo/mongod.pid
21106

  • In this case if you try to restart mongod with /etc/init.d/mongod restart
    output will be as follow
    Stopping mongod: [ OK ]
    Starting mongod: [FAILED]

But in actual mongod service is already running with other PID.

I guess this BUG is in init script of mongo.

As I am new to JIRA, let me know if any other logs or information is required to debug this issue.



 Comments   
Comment by Kelsey Schubert [ 22/Jul/16 ]

Hi tejaskumar.kasundra@gmail.com,

Sorry for the delay getting back to you. I believe this issue duplicate of SERVER-23830, which has been backported to the upcoming release, MongoDB 3.0.13. Please let us if this fix does not resolve the issue for you and we will continue to investigate.

Thank you,
Thomas

Comment by Tejaskumar [ 26/May/16 ]

Hi Ramon,

Thanks for quick reply. Pleaes find attached files as requested by you.
/etc/mongod.conf

Comment by Tejaskumar [ 26/May/16 ]

/etc/init.d/mongod
There is customization is done from my side to avoid this issue.

Comment by Ramon Fernandez Marina [ 26/May/16 ]

Can you please post the contents of your /etc/mongod.conf file as well as your /etc/init.d/mongod script?

Thanks,
Ramón.

Comment by Tejaskumar [ 26/May/16 ]

Same issue is also observed for Mongos and Mongoconfig service when operating mongo incluster mode.

Generated at Thu Feb 08 04:05:56 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.