Generate mongod.conf for tarball installtion

0 votes

Hi There,

I have installed mongodb using tgz package on centos 7.5. While starting up the mongodb i have mentioned custom location for dbpath and logpath along with --fork option. Now i want to generate mongodb.conf file from mongodb console because i dont see mongodb.conf file in /etc/mongodb.conf or dbpath or where extracted tar package or in /usr/local/etc/ location. Could you suggest here how to generate mongodb.conf file auto from mongo console.

command used to start mongodb - mongod --dbpath --logpath --fork

May 23 in Database by Kailas
• 120 points

recategorized May 25 by Gitika 41 views

1 answer to this question.

0 votes

Hi,@kailas,

To run a mangod process as a daemon (i.e.fork), and write its output to a log file, use the --fork and --logpath options. You must create the log directory; however, mangod will create the log file if it does not exist.

The following command starts mongod as a daemon and records log output to /var/log/mongodb/mongod.log.

mongod --fork --logpath /var/log/mongodb/mongod.log

I hope this will be helpful

answered May 26 by Gitika
• 29,690 points

Related Questions In Database

0 votes
1 answer

Using Real Time flume Data for Analysis

By using MorphlineSolrSink we can extract, transform ...READ MORE

answered Jul 17, 2018 in Database by kurt_cobain
• 9,310 points
110 views
0 votes
1 answer

Which one is suitable for real time big database- Primary Key or Unique Index?

What is a unique index? A unique index ...READ MORE

answered Oct 12, 2018 in Database by Frankie
• 9,810 points
84 views
0 votes
1 answer

Which operator is used in the query for pattern matching?

LIKE operator is used for pattern matching, ...READ MORE

answered Oct 15, 2018 in Database by DataKing99
• 8,150 points
444 views
0 votes
1 answer

How to schedule a job for SQL query to run daily?

down voteaccepted Expand the SQL Server Agent node ...READ MORE

answered Oct 25, 2018 in Database by Frankie
• 9,810 points
286 views
0 votes
2 answers
0 votes
1 answer

Hadoop MapReduce vs MongoDB MapReduce

Hadoop vs MongoDB MR: 1) Hadoop's MR can ...READ MORE

answered Mar 26, 2018 in Big Data Hadoop by nitinrawat895
• 10,920 points
316 views
0 votes
1 answer

How can we send data from MongoDB to Hadoop?

The MongoDB Connector for Hadoop reads data ...READ MORE

answered Mar 26, 2018 in Big Data Hadoop by nitinrawat895
• 10,920 points
404 views
0 votes
0 answers

How can I add a connection between Mongodb and Tableau

What I want? Parse the XML to JSON ...READ MORE

May 17, 2018 in Tableau by ghost
• 1,790 points
229 views
0 votes
2 answers

How do I integrate Kdb+ and hadoop?

 kdb+ could be installed on every Hadoop ...READ MORE

answered Aug 6, 2018 in Big Data Hadoop by Abhi
• 3,680 points
515 views
0 votes
1 answer

How to design data warehouse for support whole business?

Hi, @There, So here are a few steps ...READ MORE

answered 5 days ago in Database by Gitika
• 29,690 points
28 views