Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm setting up mongod to run in an /etc/init.d script. This may be a nitpick, but is there a way to avoid this?

# service mongod start
Starting mongod:
forked process: 19820
all output going to /log/location/mongod.log

Instead, I just want to see:

# service mongod start
Staring mongod:              [SUCCESS]
share|improve this question
up vote 2 down vote accepted

You might be able to change the line in your init.d script to something like this:

/path/to/mongod > /dev/null 2>/dev/null

That should suppress the output from mongod and just leave you with the output from the script. (the [SUCCESS] message)

share|improve this answer

mongod does take a --quiet flag; have you tried using that?

share|improve this answer
yes, quiet only makes the log quieter – Brian Hicks Oct 12 '11 at 14:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.