简体   繁体   中英

MongoDB background indexing

If I execute a text index in the background on MongoDB. Will this continue to execute even when I log out of the server?

db.test.ensureIndex({"name" : "text", "lastName" : "text"}, { background: true })

The mongo shell does not have to remain open once an index creation operation has been launched. The build will continue even if the shell is closed.

Index creation on the DB is one time operation. You can confirm this by logging out off the shell and logging back in and query the indexes: db.test.getIndexes()

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM