PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Sunday the 23rd of March, 2014

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[00:05:04] <user20938> do the ids of replica set members need to be consistent across all replica configs? i.e. if i do rs.initiate(config) on multiple nodes, do the contents of config need to match across all nodes?
[00:08:36] <joannac> yes
[00:08:45] <joannac> don't do rs.initiate() on more than one node
[00:10:09] <user20938> that's news to me
[00:10:38] <user20938> how do you tell other nodes to expect to be part of a replication set - just the conf setting?
[00:10:46] <joannac> yes
[00:10:57] <joannac> once one node has the cof setting, it'll talk to the others
[00:11:00] <joannac> conf*
[00:11:19] <user20938> what is the outcome of doing rs.initiate on multiple nodes? what if there is network partition initially?
[00:11:32] <user20938> i guess the latter question is an issue regardless
[00:11:43] <joannac> you'll never get them back into a replica set without manually resetting the conf
[00:12:12] <user20938> hmm
[00:12:22] <joannac> most likely it would just fail
[00:12:42] <joannac> I think there's code in rs.initiate() that will fail if there's already something in system.replset
[00:20:18] <joannac> yeah, you can't race it, assuming no network partition
[00:20:21] <joannac> I just tried
[00:21:37] <user20938> did mongo just shutdown or did it gracefully stabilize?
[00:22:08] <user20938> im just a bit surprised - im looking @ the ansible-example for deploying a mongo cluster and it seems like it does rs.initiate on all the nodes and appears to work
[00:22:15] <user20938> https://github.com/ansible/ansible-examples/blob/master/mongodb/roles/mongod/templates/repset_init.j2
[00:23:10] <user20938> might be a synchronous thing actually..
[00:23:29] <joannac> um, no
[00:23:35] <joannac> that has one rs.initiate()
[00:23:44] <joannac> and then rs.add() for each other member
[00:24:11] <user20938> that is run on every host in the cluster
[00:26:09] <joannac> hrm
[00:26:17] <joannac> well, you'll end up with a lot of errors
[03:15:28] <wangbus> hey wondering if anyone can help me out
[03:16:24] <wangbus> mongo vs couch in performance when only appending data.
[03:37:37] <thowe> So, do you have to specify your own _id if you want to use it as the reference field? I've just started looking at this, but I haven't seen how to created a related document. Can you just say parent : ObjectId("4c2209f9f3924d31102bd84a") ? Is that the thing to do?
[11:16:53] <whizzo> hi
[11:52:19] <KeyboardNotFound> I can't connect to mongo, I have this error: Error: couldn't connect to server 127.0.0.1:27017 src/mongo/shell/mongo.js:91
[11:52:34] <joannac> are you sure you have a mongod running?
[11:53:24] <KeyboardNotFound> joannac, probably I don't, how to start it ?
[11:54:11] <joannac> erm
[11:54:21] <joannac> how did you start it before?
[11:54:38] <KeyboardNotFound> joannac, I didn't start, koding.com do that for me
[11:56:17] <joannac> try sudo service mongodb start
[11:56:36] <joannac> otherwise, talk to your hosting provider
[12:30:56] <bawNg> Would it be a good idea to use about 30 000 dynamically created collections instead of a single collection containing billions of tiny documents?
[12:31:46] <bawNg> Aggregation gets very slow even with less than 400 million of these tiny documents, each containing 4 integers
[12:39:45] <kali> how are you going to aggregate over 30000 collections ?
[12:41:14] <KeyboardNotFound> When I try to start mongod, I have this error :ERROR: dbpath (/data/db/) does not exist.
[12:53:09] <mylord> how would i add bot3 to this document? http://hastebin.com/lagufurita
[12:55:40] <mylord> do i find users, then insert? can someone give me the syntax for that pls?
[15:08:50] <nvlbg> hi
[15:08:58] <nvlbg> anyone with mongoose background here?
[16:55:57] <mcr> are there any kind of caches (on disk) on mongodb clients for things like where the chunks are? After reworking a shard/RS, but keeping the same port for mongos, we see our web front end trying to contact replication sets which no longer exist.
[16:56:16] <mcr> (The client is Perl/DBIx/Catalyst)
[17:13:47] <traplin> i am having trouble with the following update code: http://pastebin.com/L8fLjb54 , it won't update at all, and just returns undefined
[17:30:49] <Voyage> I never worked with non-rdbms. If I have user table with (id PK, name, phone). and user_address table (with user_id FK, address, picture_path). How to get the name and addreess for a user?
[17:39:53] <Voyage> when to use non RDBMS? what are their uses?
[18:06:41] <mcr> Voyage, there are many different reasons. I'd say that the selling point for MongoDB isn't that it's non-RDBMS (it's noSQL, not that it's non-relational, per se), but rather it was designed to horizonally scale and support mapreduce well. Full SQL support implies many linearities on operations which make it impossible to horizontally scale.
[18:08:22] <Voyage> mcr, what is horizontal scalling?
[18:13:12] <mcr> the ability to grow bigger by adding more machines, vs vertical scaling, which means to make one machine bigger. ask wikipedia.
[18:15:46] <traplin> i have an array of values, that i want to be added to an array called 'comments', is the following code correct: https://gist.github.com/sarcasmguy/9727150
[18:19:31] <bawNg> kali: I would aggregate over each collection separately and then aggregate over each result in the application
[18:21:24] <traplin> i basically want to have 'comments', being an array, hold array of new comments, each with those characteristics (date description etc)
[18:24:59] <traplin> anyone?
[18:26:44] <Voyage> mcr, thanks
[18:26:57] <Voyage> mcr, and RDBMS horizontally scale too?
[18:29:31] <bawNg> I need to store stats (3 integers) recorded from ~30000 servers every ~15 seconds, which adds up to billions of documents fairly quickly. If all documents are stored in a single collection, each document including a server number, aggregation becomes really slow with less than a billion documents. Aggregating over a single servers documents would be surely be a lot faster if the application dynamically created a collection for each server? The server
[18:29:31] <bawNg> number also wouldn't need to be stored in each document
[18:30:50] <bawNg> Does anyone have any reason why I should not dynamically create ~30000 collections or any general advice for saving large amounts of tiny documents efficiently?
[18:49:53] <traplin> could anyone help me with pushing to an array?
[19:00:54] <mcr> Voyage, there are RDBMS which have features to help you scale, but they don't do it very well, and doing things like sharding is mostly up to your application.
[19:01:56] <mcr> so far, I think that PostgresQL does a much better job of managing ram when the db doesn't fit into ram than mongo. That doesn't mean it's is faster for all operations, but it might be faster for some, and slower for others.
[19:08:14] <Voyage> hm
[19:08:16] <Voyage> mcr, thanks
[19:15:13] <traplin> mcr: could you help me in adding an array to a document? i am having a lot of trouble
[19:16:28] <Jadenn> is there anyway to get mongo to return a multidimensional array with find()?
[19:22:16] <mcr> traplin, not sure I understand the problem, nor would I claim to be any kind of an expert. What is your client language?
[19:22:39] <traplin> well i am using javascript, but its just updating of the mongodb
[19:22:43] <traplin> here is the code i am using
[19:23:17] <traplin> mcr: https://gist.github.com/sarcasmguy/9727150
[19:23:34] <traplin> i am tying to push an object to an array of objects
[19:28:38] <traplin> mcr: never mind! i got it!
[20:52:15] <shaisnir> Hi all! :) I'm using Gridfs-stream to handle files in mongodb but I really don't get the "pipe" function. I'm trying to fetch an image from the db and all I get in return is... well... I don't even know what it is
[20:52:48] <shaisnir> var readstream = global.gfs.createReadStream(options);
[20:52:48] <shaisnir> readstream.pipe(req.file);
[20:52:48] <shaisnir> next();
[20:52:57] <shaisnir> What am I doing wrong?
[22:44:25] <edsiper> MongoDB/BSON question: the old documentation mentions a "document" data type that dont exists in the new BSON spec, whats the equivalent ?
[23:43:09] <LoneSoldier728> has no method map what does that refer to? I am thinking there is something with the $in
[23:43:10] <LoneSoldier728> http://pastebin.com/CDr4KWGH