S
S
Sergey2014-11-15 04:33:13
MongoDB
Sergey, 2014-11-15 04:33:13

How to optimize mongo for loads?

In general, when indexing a site, search robots create loads, so much so that the database freezes and pages start to crash on a timeout. How to deal with it? Do not ban the same search engines for indexing.
UPD , it turns out, it's not about loads, because. I go to the console and try to make a simple request, for example, this:

db.articles.find({title:'crimea'})

and that's it, the process hangs, it searches and does not find the article in any way.
Could this be due to the fact that the database has become simply large and it is already difficult for Mongo to quickly take and find an article? What to do in this case and how to be? The database is a copy of Wikipedia, so there is really a lot of data.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
Puma Thailand, 2014-11-15
@opium

indexes in mongo, optimize queries and logic
+ set time when to index only at night
+ set indexing intensity

L
lega, 2014-11-15
@lega

Is there an index on the title field?db.articles.ensureIndex({title: 1})

title:'crimea'
Is this the exact value of the field, or do you want to search by part of the title (full text search)?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question