PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Friday the 1st of May, 2015

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[00:03:40] <cheeser> db.getCollection('stats').find()
[00:04:17] <cheeser> also, you might want to rename that collection :)
[00:05:44] <Wulf> cheeser: thanks
[00:06:17] <Wulf> maybe when I'm officially assigned to take over the project
[02:47:49] <tejasmanohar> what operator can i use to make sure array field in results includes a value
[02:47:59] <tejasmanohar> like the members field should include "bob" and members is an array
[02:54:27] <Boomtime> tejasmanohar: you don't need an operator for that, the regular match syntax looks inside arrays
[02:55:15] <Boomtime> .find({a:"hello"}) -> will match this document: { a:["goodbye","hello"] }
[03:15:57] <tejasmanohar> Boomtime: oh
[03:16:11] <tejasmanohar> awesome
[03:16:54] <tejasmanohar> Boomtime: so like Group.find({
[03:16:56] <tejasmanohar> privacy: 0,
[03:16:58] <tejasmanohar> members: req.user._id
[03:17:00] <tejasmanohar> })
[03:17:04] <tejasmanohar> ugh sorry for spacing, assumimng thats the correct vars ^
[03:19:03] <Boomtime> "req.user._id"? - assuming this is some local variable in your code which contains the value you are searching for, then yes, this will be fine
[03:24:54] <tejasmanohar> :)
[03:25:00] <tejasmanohar> exactly- assuming thats correct var
[10:16:51] <inad922> Hi
[10:18:03] <inad922> If I have a cluster with 2 routers, 3 config servers and n shards each of which has a master and a slave node how can I monitor if an instance goes down?
[10:18:23] <inad922> Is there some common method to do this or to monitor the health of the whole cluster in some way?
[10:35:19] <e419> hi, all
[10:53:06] <ixti> hi everyone!
[10:53:38] <ixti> i have pretty strange issue with queries (sometimes)
[10:53:49] <ixti> i have a background index
[10:55:11] <ixti> oh. while trying to explain, realized that i forgot to check one thing that might be the issue...
[10:55:18] <ixti> sorry to flood :D
[10:57:59] <ixti> now i'm really confused...
[11:08:49] <deathanchor> ixti, we all have had one of those days
[11:11:32] <cheeser> "background" only applies to index creation. there's no runtime difference.
[11:14:37] <ixti> am I assuming correct, that if I explicitly specify hint with index I want to use then it will be used?
[11:15:05] <ixti> e.g. I have index: `{ pn: 1, grc: -1 }`
[11:15:53] <ixti> sometimes, when I run query like: `{ pn: { $in: [...] } }` with sort by `{ grc: -1 }`
[11:16:38] <ixti> i'm getting error: failed with error 17144: "Executor error: Overflow sort stage buffered data usage of 33637218 bytes exceeds internal limit of 33554432 bytes"
[11:16:51] <cheeser> a hint is just a suggestion. i don't think it'll force the query engine to use it.
[11:16:59] <inad922> If I have a sharded cluster and I would like to add a new shard is it enough to register the new shard on one router and that will update the config servers or do I need to do this registration on all the routers? I guess not.
[11:17:07] <ixti> cheeser: wow
[11:17:33] <cheeser> no, it forces it. http://docs.mongodb.org/manual/reference/operator/meta/hint/
[11:17:51] <ixti> then I don't understand HOW it can randomly fail
[11:18:01] <ixti> because when i executed that query manually - all was good
[11:19:18] <ixti> but it fails sometimes...
[11:19:30] <ixti> so, that looks reallly strange:
[11:21:00] <ixti> `"$query"=>{"ve"=>true, "grc"=>{:$gt=>200}, "pn"=>{:$in=>[...]}}, "$hint"=>{"pn"=>1, "grc"=>-1}, "$orderby"=>{"grc"=>-1}}` and the error above...
[11:22:00] <deathanchor> could it be this? https://jira.mongodb.org/browse/SERVER-13611
[11:22:53] <deathanchor> are you doing a sort?
[11:24:36] <ixti> deathanchor: yeah. i'm doing sort. and that issue seems really what I experience... but i'm runnnig that on mongo 3.0
[11:25:09] <ixti> ah. and one difference... in that issue it's reversed order of sort field
[11:25:24] <ixti> in my case it matches. so according to that issue - i should have correct behavior :((
[11:26:24] <ixti> although it's linked to another issue which seems to be even more similar to mine :D
[11:26:45] <ixti> deathanchor: thanks for help
[11:26:47] <ixti> :D
[11:26:54] <deathanchor> thank google
[15:36:59] <pjammer> After many many days i can get my replSet to have the two members in a state of Down. Even MMS says they are down; I can mongo blah.host to each one from primary too, I'm at a loss at how to get past this.
[15:37:34] <pjammer> as my primary after 5 mins turns to secondary and then i have to hose the whole AWS volume because i don't know if there is a rs.forget_it_go_back_to_standalone
[15:37:48] <GothAlice> pjammer: Did you select WiredTiger as your storage engine?
[15:38:17] <GothAlice> Rotating rapidly through primaries was a symptom of my own troubles with WT under MMS on under-sized hosts.
[15:38:17] <pjammer> this is 2.4.10
[15:38:20] <GothAlice> Oh.
[15:38:42] <GothAlice> That's… painfully old, and not even maintained any more.
[15:38:42] <pjammer> i was hoping to get a repl set up, then upgrade.
[15:38:46] <GothAlice> Yeah.
[15:38:53] <GothAlice> cheeser: XP
[15:39:00] <cheeser> GothAlice: it's maintained...
[15:39:00] <pjammer> hey we're given the cards we're dealt.
[15:39:09] <cheeser> pjammer: :D
[15:39:11] <GothAlice> cheeser: Why no version in channel topic?
[15:39:15] <GothAlice> Cover your shame! (J/K)
[15:39:24] <cheeser> dunno
[15:39:31] <GothAlice> That's… confusing.
[15:39:49] <pjammer> but seriously it's been 4 days of Unknown status; then i got it to finally say Down.
[15:39:51] <cheeser> i believe the official line is current + last 2 minor versions
[15:40:08] <cheeser> there are still folks on 1.8, though, so...
[15:40:43] <pjammer> what should i do. i literally have no clue anymore.
[15:41:02] <pjammer> figuratively if we're pedantic.
[15:41:27] <cheeser> you're trying to create a new 2 member replSet?
[15:41:32] <pjammer> yes
[15:41:36] <pjammer> 2.4.10 standalone
[15:41:49] <pjammer> all have replSet=rs0
[15:41:49] <pjammer> mms sees them
[15:42:09] <cheeser> if it's new you can just kill them and delete the data dirs and start over
[15:42:14] <pjammer> i can mongo blah.host.com or ip-internalhost to all 6 combos of boxes
[15:42:22] <pjammer> it's 300GB db
[15:42:23] <GothAlice> pjammer: I'm not sure about 2.4 any more, but in 2.6+ at least, downgrading a replica set is relatively easy. Spin up arbiters if you need to get a node back up as primary, remove the nodes, then restart mongod without the --replSet option / config.
[15:43:21] <pjammer> how do you spin them up if you can't access rs.status()
[15:43:25] <pjammer> or rs.add()
[15:44:16] <pjammer> and on every member logs says: [rsStart] replSet can't get local.system.replset config from self or any seed (EMPTYCONFIG)
[15:44:28] <pjammer> yet the connection is accepted from primary
[15:44:31] <GothAlice> Oh, if the config is empty, yeah, just drop the --replSet option/config.
[15:44:40] <GothAlice> Those nodes will go back to standalone.
[15:45:31] <pjammer> so when the docs mention spin up 2 standalones, i am NOT to put the replSet=rs0 line in those member's when i first start?
[15:45:49] <pjammer> i thought/read that all 3 configs were the same. /etc/mongodb.conf
[15:46:11] <pjammer> I'll try it. got nothing else to lose.
[15:46:57] <pjammer> Maybe i should ask how you both would migrate a standalone with 300GB /data directory in an AWS EBS volume to a repl set
[15:47:14] <pjammer> i'm following the tutorials
[15:47:29] <pjammer> even the youtube ones look the same but none of them do it with production data
[18:34:01] <Ramone> hey all... any node.js users in here? Is there a way to validate mongo objectids as a type? eg this is false: mongo.ObjectID.isValid(mongo.ObjectID())
[19:41:18] <davidnknight> Anyone had issues with mongo error 'provided setName for Replicaset Connection does not match setName found in server seedlist'
[19:45:23] <deathanchor> happens when the command line (or startup option) for replsetname doesn't match the name in teh rs.config()
[19:45:53] <davidnknight> Yes, it seems to be parsing it incorrectly.
[19:45:58] <davidnknight> I'm using Mongoose.
[19:46:21] <davidnknight> [1] server in replset set-5543ac2a97841f8d4400131b is not part of the specified setName set-5543ac2a97841f8d4400131b,mongodb://capital.3.mongolayer.com:10188/testdb
[19:47:04] <davidnknight> mongodbUri = 'mongodb://capital.2.mongolayer.com:10188,capital.3.mongolayer.com:10188/testdb?replicaSet=set-5543ac2a97841f8d4400131b';
[19:47:32] <davidnknight> It looks to me like it's getting the replica set name wrong?
[19:51:04] <davidnknight> Any ideas deathanchor, or anyone else?
[20:56:40] <BLZbubba> testing
[20:56:45] <BLZbubba> hi guys i am using mongodb-org-server-3.0.2 with wiredtiger. Is there a way in mongod.conf to tell mongod to use O_DIRECT for everything?
[22:54:31] <hemmi> Hey there guys. Is mongodb a suitable store for a flat list of key-value pairs?
[22:55:35] <cheeser> it'll work sure. it's not really meant to be a pure k/v store.
[23:36:32] <Omego2K> hey, this might be a very stupid question, but if I have a field whose type can be an array or string how can one project the array portion to one field and the string portion to another?
[23:46:17] <cheeser> you can't, i don't think.
[23:58:22] <hemmi> cheeser: do you have any recomendations for an alternative?