[01:14:30] <fabianhjr> Hey, I think I met someone from MongoDB Linux Distribution team in MHacks. By the offchance he is here: Hi.
[01:16:29] <fabianhjr> The other thing, does someone know of an #elixir-lang adapter for Ecto/Phoenix even if it is experimental? I was only able to find a simple interface to call mongo from with elixir-mongo ( https://github.com/checkiz/elixir-mongo) but it hasn't been updated recently and it does not integrate with Ecto Models.
[01:33:56] <Boomtime> morenoh149: remove the upsert:true condition, you cannot possibly mean that
[01:40:55] <toter> Hi everybody... The following code is doing absolutely what I want, but it's taking 63 seconds to do it. I know there's a foreach loop inside a foreach loop that needs to be removed, but I can't find a way to make it work. Code: http://viper-7.com/XV6kmX
[01:44:27] <dimon222> probably if you collect all your find operations in bulk ordered collection and send it in bulk - it will be faster
[01:44:43] <dimon222> but i definitely believe that additional check for empty and etc - not a good choice for php
[01:44:54] <dimon222> more like python or something
[01:46:14] <dimon222> so i meant this stuff http://docs.mongodb.org/manual/reference/method/js-bulk/
[01:46:23] <dimon222> not sure about implementation in php, but should be somewhere
[01:54:23] <Jonno_FTW> is there a convenient way to update a nested document?
[02:37:03] <joeyjones> Jonno_FTW: You may also want to check the size of your indexes.
[02:37:25] <Jonno_FTW> I haven't set indexes yet, i'm at the design stage
[02:58:47] <xissburg> If I have a Question collection and it has a pointer to an Approval collection that has the date this question was approved, is it possible to build a query that will return questions sorted by the approval date?
[03:08:32] <Boomtime> xissburg: no, you are asking about a join
[03:09:08] <Boomtime> if you want to know the date a question was approved, the question should have that information, otherwise you are doing two queries
[03:09:43] <xissburg> Yeah, I think I will drop the Approval and will add two fields to the Question itself
[03:09:56] <xissburg> I just need the user who approved and date
[07:09:08] <Arvind> Can you guys please help to resolve this
[07:13:10] <Boomtime> Arvind: the error appears to be in your own code, have you followed the stack trace?
[07:14:12] <Boomtime> also, your question appears to be pure Node.js - have you asked in #nodejs ?
[07:27:25] <Arvind> Boomtime: No, I did not asked to nodejs. My main issue is that I am refering another collection as array to document field and I am not passing the reference object. May be that is the issue but I saved data before like this many times but Now I am getting error
[09:41:38] <Andre-B> does mongod --repair has any kind of progress? so I can see how long it will take?
[09:51:09] <aaearon> im using pymongo and trying to pop a value from one of my documentś arrays. pop is returning the value from the array but not removing it. am i missing something obvious?
[10:07:50] <ekristen> one of my replic’s is crashing
[10:07:54] <ekristen> Tue Jan 20 09:56:45.492 [repl writer worker 1] getFile(): n=16000 — Tue Jan 20 09:56:45.492 [repl writer worker 1] Assertion: 10295:getFile(): bad file number value (corrupt db?): run repair
[10:08:06] <ekristen> I could use some advice on how to fix it
[10:12:37] <Andre-B> ekristen: did you try repairing the db?
[10:13:17] <ekristen> Andre-B: so this is happening on a replica, so I was going to ask if that was the right move or not — well on a secondary at the moment, my primary and my other secondary in the set seem to be ok
[11:29:30] <ekristen> the primary logs are fine so are the other secondary
[11:30:03] <ekristen> but the secondary that crashed, I cna’t get it to re-sync, I tried deleting the entire dbpath to let it resync from scratch, but fails with that error message
[11:30:14] <ekristen> there is next to no information available on google for that error message either :/
[11:37:47] <ekristen> Tue Jan 20 11:35:10.049 [initandlisten] exception in initAndListen: 15924 getFile(): bad file number value 16000 (corrupt db?): run repair, terminating
[11:38:02] <ekristen> that is what my secondary crashed with, now my primary crashed with that
[11:40:25] <ekristen> ok how can I force my secondary to take over as primary
[11:43:26] <joannac_> tell me exactly what you're typing
[11:44:03] <ekristen> I http://docs.mongodb.org/manual/tutorial/force-member-to-be-primary/ <— I did the first part, but did {force: true} as an option to rs.reconfig
[12:01:22] <arussel> no documentation can beat a well named function
[13:01:10] <kaushikdr> I need some help with nginx-gridfs module. I've followed this https://github.com/mdirolf/nginx-gridfs and then when I start the nginx server it gives 'nginx: [emerg] unknown directive "gridfs" in /etc/nginx/nginx.conf'
[13:52:33] <tusbar> hey, is something wrong with this text index? http://paste.awesom.eu/V6ZQ I never get any result using using { $text { $search: 'foo' } } (mongod 2.6.7)
[13:56:29] <tusbar> (with http://paste.awesom.eu/uJBw as sample data)
[14:17:39] <tusbar> ok nevermind getting results with 4 chars :D
[14:35:14] <hhburs> good morning everyone. does anyone know if it is possible to determine if a collection is using power of 2 allocations?
[14:44:26] <hhburs> i found it, db.collection.stats(), userFlag = 1 -> usePowerOf2Sizes is enabled
[14:50:39] <Bish> hi, how can i make a query where i ask for "give me all objects where field1<field2"
[14:50:59] <Bish> i tried {field:{"gt":"$other_fild"}}
[14:51:09] <cheeser> you can't do that with find()
[14:51:14] <cheeser> aggregation can do that, though.
[14:51:23] <Bish> oh thats where i got that syntax from, okay thank you
[15:12:50] <winem_> do I understand the docs right that it is a matter of personal preferences if you use db.coll.find({ x : { $gt : "1", $regex : "2" }}) or if you build the query with or?
[15:13:39] <winem_> sorry, talking abount $and, not $or...
[15:14:14] <winem_> and the version without $and should be a bit more performant. is this right or is there any situation where you MUST use $and?
[15:19:37] <winem_> oh ok, I see... it looks to be important in case of queries like db.scores.find( { score : { $gt : 50 }, score : { $lt : 60 }}) because the 2nd condition takes priority and "overwrites" the first one... please let me know if I'm wrong
[15:35:33] <c7hb7e> if i run the following upsert query, which operator is applied first? $setOnInsert or $addToSet? db.myCollection.update({ "$setOnInsert": { "tags": ["public"] }, "$addToSet": { "tags": { "$each": ["tag1", "tag2"] } } })
[17:17:23] <winem_> hi, I have some strange behaviour I can't understand... I guess I'm just confused, because I did partial updates a lot of times before. why does the update in this pastie http://pastie.org/private/cmijtrzi1ymlepmyqytpq has no effect?
[17:17:47] <winem_> the query matches one record, but it's not updated...
[17:19:48] <winem_> guess it will take most of you about a sec to find the error...
[17:21:03] <sekyms> dumb question: What is preferred 'start_time' or startTime
[17:43:28] <winem_> ok, I have no idea why it didn't work.. it works now...
[18:25:41] <Tyler_> Would you guys separate your user document from the billing info?
[19:06:45] <dman777_alter> does anyone use elasticsearch-river-mongodb? If I wanted to span the shards across 2 servers would this plugin be ok with it?
[19:52:01] <harttho> Is there an upsert equiv for using $inc to set a field that hasn't been set yet?
[19:53:05] <harttho> nevermind: If the field does not exist, $inc creates the field and sets the field to the specified value.
[20:45:57] <kcjd> Hello. Thanks in advance for any help given. I'm attempting to set up mongo, Using osx, downloaded using homebrew. When I run the command mongo --version, it returns $ db version v2.6.7, and does not specify Mongo Shell version.
[20:47:35] <kcjd> I can run mongod, but if I open another terminal window and run mongo it fails with "Unable to lock file: .. Is a mongod instance already running?"
[20:55:38] <cheeser> kcjd: mongod is the server. mongo is the client.
[21:34:17] <blizzow> I'm trying to do a mongorestore into a sharded cluster with a couple 150GB bson files and a few 80GB bson files. I'm only getting 1000-2000 inserts/second. I'm running multiple restores against different mongos instances to try and parallelize and speed up the restore, but that's not helping. I added -noobjcheck --noIndexRestore --noOptions and it's still super slow. The mongo replica sets are running with 64GB RAM, 32GB swap, and
[22:12:46] <Tyler_> If you're doing a bunch of database calls with .then, you're still doing nested database calls
[22:12:52] <Tyler_> how do you avoid making 100 nested calls?
[22:45:56] <nnyk_> I would think having 100 nested calls shows a problematic design afaik