PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Saturday the 2nd of November, 2013

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[00:44:38] <rafaelhbarros> is there a way to add a replicaset member with pymongo?
[05:04:39] <a13x212> anyone awake :)
[05:11:27] <joannac> yes
[05:15:27] <a13x212> trying to add a new member to a replica set, so i stopped mongo on the secondary and copied the data directory to the new member
[05:16:15] <a13x212> rs.add doesn't add the member and don't see any errors in the logs
[05:51:24] <joannac> did you start the mongod process on the secondary?
[05:51:32] <joannac> you can't add a member that isn't up
[05:53:02] <a13x212> yes i did
[06:35:33] <a13x212> eeerrr, i was using double quotes instead of single quotes
[10:44:37] <zymogens> Hi. I have a document with a field called subscribers. It contains an array of up to 5,000 Object_ids in it. Can I do a query to bring back all the documents in that collection and just get back a true value for that field if a certain id is in it rather than getting the 5,000 Object_ids. Hope that makes sense? Thanks.
[10:45:22] <Derick> a "true value" ?
[10:45:34] <Derick> what do you mean by that?
[10:45:54] <zymogens> Just that if a certain id is in that array. It would just say true...
[10:45:56] <wereHamster> instead of { subscribers: [ ... 5000 elements ] } he wants to get { subscribers: true }
[10:46:01] <zymogens> yes
[10:46:16] <zymogens> I just want to know if a certain user is in the array
[10:46:17] <wereHamster> probably map/reduce (with hjust a map) would work?
[10:46:31] <zymogens> ok. thanks for that. will take a look into it.
[10:46:34] <wereHamster> that way the data is processed on the server instead of hte client
[10:46:46] <zymogens> excellent... that sounds like what I want.
[10:46:59] <wereHamster> alternatively, just omit the subscribers field form the document
[10:47:35] <zymogens> could do that, but I am hoping to get back every document... and just know which ones a user had already subscribed too.
[10:47:38] <wereHamster> eg. find({ subscribers: <objectid> }, { _id: 1 }) to just get the document ids of documents which have that subscriber
[10:48:00] <wereHamster> ah well, m/r it is then
[10:48:08] <zymogens> thanks wereHamster
[11:54:48] <Aeveus> MongoDB generated ~40 2GB files in one day, which triggered a couple hard disk alerts, does anyone have any idea why this is?
[11:55:28] <Aeveus> All in /var/lib/mongodb/ called test.0, test.1 -> test.40
[11:55:36] <joannac> growth of data?
[11:56:57] <Aeveus> Now checking
[11:57:33] <Derick> joannac: i thought you went to bed :-)
[11:59:31] <Aeveus> Is the result returned by stats() in bytes? If so then I get why I've got that many files. :')
[11:59:52] <Derick> mongodb limits filesizes to 2GB
[11:59:56] <Derick> and just creates more
[12:00:04] <Aeveus> My bad, didn't really expect this level of growth.
[12:00:07] <Derick> what does db.stats() show?
[12:00:17] <Aeveus> A size of 131GB
[12:00:31] <Derick> "objects" : 155,
[12:00:32] <Derick> ?
[12:00:37] <Derick> avgObjSize?
[12:00:59] <Aeveus> "count" : 38935,
[12:00:59] <Aeveus> "size" : 131948448256,
[12:00:59] <Aeveus> "avgObjSize" : 3388941.7813278
[12:00:59] <Aeveus> "storageSize" : 134103784528,
[12:01:09] <Derick> wtf do you store in one document?!
[12:01:13] <Derick> 3mb each?
[12:01:14] <Derick> :)
[12:01:21] <Aeveus> :')
[12:01:31] <Aeveus> This is the database storing game logs for theaigames.com
[12:01:47] <Aeveus> I really wasn't expecting engine output to be 3MB for each game
[12:09:56] <cina> how can I enable remote access to my mongod server (I'm on OSX)?
[12:10:15] <cina> (both server and client on OSX)
[12:11:51] <cina> I'm getting "Error: couldn't connect to server 192.168.1.23:27017 at src/mongo/shell/mongo.js:147"
[12:15:29] <Derick> cina: firewall in the way?
[12:15:33] <Derick> does it run?
[12:15:38] <Derick> ps ax | grep mongo
[12:15:40] <Derick> will tell you
[13:06:15] <cina> Derick: it is running
[13:06:50] <cina> I can connect to it locally (localhost:27017) but I cannot do it from another computer in LAN (using 192.168.1.23:27017)
[13:08:39] <Derick> can you run "netstat -a -n | grep 27017" on the box where mongod runs at?
[13:10:21] <cina> tcp4 0 0 127.0.0.1.27017 *.* LISTEN
[13:11:02] <cina> ffffff800b401000 stream 0 0 ffffff80176c53e0 0 0 0 /tmp/mongodb-27017.sock
[13:11:10] <cina> (sorry about the formatting)
[13:12:16] <Derick> k, on your other machine
[13:12:31] <Derick> can you do a "telnet 192.168.1.23 27017" ?
[13:14:23] <cina> telnet: connect to address 192.168.1.23: Connection refused
[13:14:31] <cina> Unable to connect to remote host
[13:14:32] <Derick> what about "ping 192.168.1.23" ?
[13:14:50] <cina> it does ping
[13:15:05] <Derick> which box are you trying to connect from - what OS does that run?
[13:15:23] <cina> both boxes are OSX
[13:15:28] <cina> mongodb installed with homebrew
[13:15:34] <Derick> hmm, you know how to check firewall rules on OSX?
[13:16:54] <cina> no... I'm new to OSX
[13:17:23] <Derick> then this is your chance to learn! I've no idea either
[13:17:29] <Derick> and I don't have OSX
[13:18:55] <cina> Derick: thanks anyways :)
[13:30:09] <cina> btw I found out both boxes have firewall disabled
[13:30:49] <cina> could it be a problem with our LAN?
[13:33:27] <Derick> or a hub/switch that doesn't allow it
[13:33:30] <Derick> I dunno
[13:44:48] <cina> yeah
[19:08:57] <Katafalkas> is there a way to tell mongo which CPU to use for writes and which for reads ?
[19:23:58] <ssx> hey folks
[19:24:24] <ssx> is there something which can graph mongodbs performance for read/writes etc?
[19:25:28] <ssx> scrap that, quick google pointed me at mms ;)
[20:03:26] <pzuraq> so question
[20:03:45] <pzuraq> Does mongo not have a schema in the traditional sense?
[20:04:00] <pzuraq> you can just push objects to it and be done with it?
[20:05:03] <acalbaza> quick question, has 2.6 released?
[20:14:43] <cheeser> pzuraq: yep!
[20:14:45] <cheeser> acalbaza: no
[20:16:32] <pzuraq> that sounds almost too awesome
[20:17:24] <cheeser> it get awesomer. mongodb is free! :D
[20:26:46] <pzuraq> cheeser: Well there are a fair few of free dbs
[20:29:43] <cheeser> i was being facetious. :)
[20:30:56] <pzuraq> ah
[20:31:00] <pzuraq> :)
[23:12:29] <omnidan> I have an admin user with roles ['userAdminAnyDatabase', 'clusterAdmin', 'readWriteAnyDatabase', 'dbAdminAnyDatabase'] but genghis can't use it, what could be wrong?
[23:15:56] <omnidan> nevermind, seems to work now, was probably just a genghis bug because I reloaded it and it worked
[23:27:06] <flatr0ze> ello
[23:27:15] <flatr0ze> a QQ here: how do I make mongo/Meteor return/insert things the way I put them in? I insert ' " ' and get ' " ' back... this screws up my hashing functions. Thanks!
[23:28:39] <flatr0ze> ah, nvm, it's me stupid... I filter that by hand on insert