PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Friday the 12th of September, 2014

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[00:41:19] <^conner> does mongo have a public CI system?
[02:45:18] <skot> whois ^conner
[02:45:54] <skot> sorry, meant to ask what you are looking for wrt CI
[05:59:42] <mms_> I am getting json posted from web app and it has unix timestamp. server is nodejs and when I store that json to mongodb its stored as Number32 but not date. what to do so I can store it as date or how to convert it to date in mongodb aggregate query.
[06:02:48] <joannac> new Date(timestamp)
[06:03:16] <joannac> or whatever your language of choice has for converting timestamps to dates
[06:14:02] <bramgg> How can I enduce a connection error with mongoose for testing purposes?
[09:42:40] <Zelest> We ran out of diskspace last night.. and mongod crashed/shutdown..
[09:43:02] <Zelest> Did the application react to this? Did we have any downtime? Was our operation interupted? Not at all! :D
[09:43:08] <Zelest> Thanks MongoDB for being so awesome!
[13:57:18] <kaveera> hi
[13:58:05] <M4rius> so you _are_ chatty!
[13:58:46] <kaveera> for a little while, yes!!
[13:58:58] <kaveera> i have a question in mongodb
[13:59:03] <kaveera> need some help
[14:35:16] <saml> https://gist.github.com/saml/201aaf92464cb2a4826d how does sorting like this work?
[14:41:02] <skot> saml: http://docs.mongodb.org/manual/reference/method/cursor.sort/
[14:41:12] <saml> thanks skot
[14:45:43] <saml> is bson object smaller than bson array?
[14:46:30] <saml> i wonder if i should use {foo:[[1,1],[1,2]]} or {foo:[{season:1,episode:1}, {season:1,episode:2}]}
[14:47:02] <cheeser> magic numbers--
[14:47:24] <saml> or i can do {foo: [1001, 1002]}
[14:47:32] <saml> season*1000+episode
[14:47:33] <Derick> saml: just numbers is really smaller, but what cheeser says...
[14:47:41] <Derick> you can then not query on just season
[14:47:45] <Derick> I'd pick:
[14:48:00] <Derick> {foo:[{s:1,ep:1}, {s:1,ep:2}]}
[14:48:03] <Derick> or something
[14:48:38] <saml> actual doc is like {episode:'8-7',season:3, episodes:[8,7]} currently
[14:48:48] <saml> but i need to sort by season as well
[14:49:22] <saml> .sort({season:1,episodes:1}) I guess i can do this
[14:49:58] <saml> but i was wondering if i should just calculate integer, order at insertion and remove episodes field
[14:50:32] <saml> {episode:'8-7',season:3,order:[3007,3008]}
[14:50:42] <saml> assumming therhe is no more than 1000 episodes per season
[14:50:53] <Derick> no magic numbers
[14:51:05] <saml> yah
[15:02:17] <oRiCLe> can somebody help me with my aggregate command: http://collabedit.com/89per
[15:25:05] <cbuckley> hi there
[15:25:25] <cbuckley> are there any docs on the mongo site about alowing mms service into private aws vpc subnets?
[15:25:42] <cbuckley> took a look but having trouble finding anything
[15:56:04] <jordana> mmap flushes are taking 40 seconds /sigh
[15:56:16] <jordana> on a production secondary
[17:49:31] <testerbit> Does aggregate support $match then $group and then $match the $group results?
[17:50:06] <cheeser> cbuckley: still around?
[17:55:01] <cbuckley> yep
[17:55:45] <cheeser> what problems are you seeing exactly?
[18:02:43] <^conner> skot, I finally found it... a link to buildbot from a post on a mailing list. Really hard to find!
[18:03:57] <skot> ^conner: we have left buildbot and are on an interim CI system, mci.10gen.com (for now) for the server.
[18:05:37] <joneshf-laptop_> with a monoguri, is it still valid if you give a connection string option with an unrecognized name? http://docs.mongodb.org/manual/reference/connection-string/#connections-connection-options
[18:05:47] <cbuckley> cheeser: no problem
[18:06:07] <cbuckley> i am setting up a new web cluster with vpc, never used vpc before
[18:06:18] <cbuckley> and will have private subnet for our mongo replica sets
[18:06:23] <joneshf-laptop_> like if my mongouri were: `mongodb://localhost:27017/?foo=3` would that be valid?
[18:06:54] <cbuckley> so was looking for documentation on best practices, if there is any affect on mms (such as reaching the munin-node daemon, doing backups, etc)
[18:07:17] <^conner> skot, the dates on buildbot look current. Eg., http://buildbot.mongodb.org/builders/V2.4%20Linux%20RHEL%2064-bit
[18:07:36] <skot> only for old version (2.4 and before)
[18:08:31] <^conner> skot, gotcha - mind if I a why you migrated away from buildbot? Buildbot claims mongodb as a user which is why I was curious
[18:09:20] <skot> email the mongodb-dev list to get some comments, I'm unfortunately busy atm, or you can try me later :)
[18:09:47] <^conner> skot, roger. thanks for the pointer!
[18:13:28] <cheeser> cbuckley: you shouldn't have a problem with the mms agents. they just need to be on the machine.
[18:36:29] <totokaka> I was looking through my system to find out what folders are taking up space, and I found that I have both a /var/lib/mongo and a /var/lib/mongodb which takes up 3.2GB and 3.3GB, and contains the same files. I did a failed install of mongo earlier. mongo is owned by mongod:mongod while mongodb is owned by mongodb:root. Can I delete one of them?
[18:37:42] <jchamberlain> hey all
[18:39:06] <jchamberlain> using something like $project, is there a way to return the results of a query as key => val instead of an array of documents?
[18:41:23] <jchamberlain> the result would be something like {"540e3af0906abf5ff70041bd": "value from the first doc", "540e3af0906abf5ff70041c8": "value from the second"}
[19:11:23] <testerbit> What is wrong with this query inside of aggregate: {$match: {"scores.type":{$not:/quiz/i}}}
[19:12:10] <testerbit> get the following error: bad query: BadValue $not cannot be empty
[19:13:27] <cbuckley> cheeser: ok thanks
[19:18:56] <felixjet_> can someone give me a hand please?
[19:19:16] <felixjet_> on this update: db.posts.update({}, { $set: { 'published_at': XXXXX } }, { upsert: false, multi: true })
[19:19:29] <felixjet_> how i can make XXXX = created_at for every document?
[19:19:49] <cheeser> you can't with update()
[19:19:54] <felixjet_> i want to copy the field created_at and the value contained, into published_at
[19:19:57] <felixjet_> how i can do it?
[19:20:12] <cheeser> you'll have to find(), iterate the cursor, update the documents returned, save them back.
[19:22:11] <felixjet_> meh
[20:22:46] <broguinn> I'm trying to figure out how to use mapReduce to group whole documents by certain properties. If I have a collection books and want to group by three properties, how do I add a document to the existing value?
[20:24:46] <broguinn> I looked at this example (http://cookbook.mongodb.org/patterns/unique_items_map_reduce/) but I don't want a count, I want the actual grouped documents in the reduce.
[20:56:25] <bramgg> Hi
[21:03:07] <jblancett> can anyone explain to me why I can insert values with mongo --eval but all find queries return blank results?
[21:05:35] <jblancett> for example I can do `mongo foo --eval 'db.bar.insert({_id: 0})'`, then `mongo foo --eval 'db.bar.find()'` returns no results but running the same command in shell does return the expected results
[21:05:39] <blizzow> I'm having difficulty with the java driver connecting to a replica set. The URI is something like this: mongodb://myhost1,myhost2/replicasetname . I get errors saying it's unable to find master. If I reduce this to one host (either myhost1 or myhost2) it works. Anyone know what could be tripping me up here? I see some people asking about it in google but no answers.
[21:15:39] <skot> jblancett: --eval 'printjson(db.bar.find().toArray())', find returns a cursor which needs to be iterated...
[21:16:34] <skot> blizzow: do you have a valid primary in that replica set? I'm guessing not, but best to include the log output along the way if you are unsure.
[21:17:03] <skot> Also keep in mind that the client needs to be able to connect to all the hosts in the replica set config to ask if they are the primary, and update its internal state.
[21:18:51] <skot> There will be logging in the logs on client indicating any problems during discovery. If you only use one host you aren't connecting to a replica set, just a specific member and no discovery is done.
[21:19:35] <blizzow> skot: I think we figured it out. We initiated the replicaset and the primary used a weird hostname rather than our DNS name for the replset member. I removed the primary and re-added it to the replica set.
[21:19:45] <blizzow> Seems to have gotten me past that error....
[21:20:07] <skot> Yes, the client and server must be able to resolve and connect all configured host names.
[21:20:51] <skot> The list you connect with is just for discovery, and is not authoritative -- that is what the replica set config is for.
[21:21:07] <blizzow> When I re-added the old primary, it came back as a higher ID. Is it okay to force the old one back in as ID 0 and then promote it?
[21:25:28] <skot> I don't know why you would. If you want it to have a higher priority to be elected primary then change the priority. You cannot "promote" it so much as stepdown the current primary.
[23:26:37] <kas84> hi guys
[23:26:37] <kas84> I’m getting this error message in my logs: “command: update { $msg: "query not recording (too large)" }”
[23:26:37] <kas84> anybody knows what is it about?
[23:27:05] <kas84> I’m running a 2.6.3 mongodb instance