PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Monday the 8th of February, 2016

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[06:50:10] <dorkmafia> if my server is running with ssl how can I connect to it with my client? mongo --ssl --sslPEMKeyFile (does this pem file need to be on the server or do I generate one?) --sslCAFile (is this the path to the pem file on the server??) -u someuser -p somepass
[10:22:48] <brokenCode> hello
[10:26:27] <djlee> Hi. I have a collection of objects with a location (geopoint) and radius (integer). Is there a way of doing a $near query where the $maxDistance is based on each doc's radius, or do i need to add like a geoCircle to each document first and use an intersect?
[10:30:32] <brokenCode> I am using the Java Driver to interact with mongo but I am getting an the wrong type. Mongo is seeing NumberLong when it should be NumberInt(). How do you force it to a NumberInt
[10:36:08] <brokenCode> lively in here =)
[10:36:38] <djlee> not sure if you replied, my irc client decided to throw a fit
[10:36:40] <djlee> :P
[10:39:42] <brokenCode> yea it cant handle the chat in here !!
[11:20:03] <brokenCode> tum ti tum ti tum ...
[11:20:22] <brokenCode> Echo ..echo..echo....echo..echo....echo..echo..
[11:26:04] <yossarianuk> hi - I am setting up replication - I have 3 nodes (2 db servers and an arbiter)
[11:26:28] <yossarianuk> do I need to copy the keyfile to the arbiter also as well as the 2 databases servers ?
[11:26:33] <Derick> yes
[11:26:57] <yossarianuk> Derick: thanks - also I assume I should also use the same authentication ?
[11:27:02] <Derick> yes
[11:27:07] <yossarianuk> ok - thanks
[11:28:57] <yossarianuk> just wanted to check what I was about to do wasn't horrendously wrong...
[11:55:49] <ams_> I'm running an arbiter with journalling switched off. I find it gets the mongod.lock file hanging around whenever it restarts. Is this expected?
[12:21:27] <yossarianuk> Derick: one last thing (if you are still about) - do I also need to add the same replication lines to mongod.conf ?
[12:21:45] <yossarianuk> i.e - replSetName: rs1
[12:24:37] <yossarianuk> actually don't worry - I can see you do.
[12:40:20] <gzoo> Tell me if I'm sane: I want to copy a mongo db from one host to another directly. Will using tmux/screen and mongodump in it from the target machine to the master machine be fine?
[12:40:49] <gzoo> Or should I use nfs and dump the db 'locally' on server 1 onto the nfs share?
[12:49:52] <mylord> how to .find( a OR b ) ?
[12:50:40] <mylord> got it https://docs.mongodb.org/manual/reference/operator/query/or/
[12:57:42] <Derick> http://pastebin.com/6QhyMHSt « why does "git add <filename>" add *all* changes to the index?!
[15:57:13] <dbackeus> I want to create a unique compound index for two fields, organization_id and slug, but only create the index if slug isn't null
[15:57:45] <dbackeus> can I use a partialFilterExpression for this, if so how would the expression look like?
[15:58:11] <dorkmafia> if my server is running with ssl how can I connect to it with my client? mongo --ssl --sslPEMKeyFile (does this pem file need to be on the server or doif my server is running with ssl how can I connect to it with my client? mongo --ssl --sslPEMKeyFile (does this pem file need to be on the server or doif my server is running with ssl how can I connect to it with my client? mongo --ssl --sslPEMKeyFile (does
[15:58:12] <dorkmafia> this pem file need to be on the server or do I generate one?) --sslCAFile (is this the path to the pem file on the server??) -u someuser -p somepass
[15:58:29] <dorkmafia> oops copy paste fail
[16:01:02] <mylord> How/can I do both $set and $push using 1 update with the official node driver? https://gist.github.com/adaptivedev/96ff5f36b26d4aff0e55
[16:01:12] <mylord> only the $push is working
[16:02:31] <mylord> nvm, got it
[16:03:05] <Ceunincksken> When moving from a standard Mongo to a Sharded Environment, using a hashed '_id' field as the shard key, the insert performance goes down drastic. How's that's possible? Isn't sharding there to allow better performance?
[16:21:28] <StephenLynx> network overhead? CentaurWarchief
[16:21:44] <StephenLynx> he lft :v
[16:21:44] <StephenLynx> nvm
[16:54:16] <queretaro> Hi all, I have a mongod 3.0 instance using MMAPv1 as its storage engine
[16:54:27] <queretaro> there's a collection that grew a lot so I ran 'compact' on it - afterwards, if I do db.collection.stats() I see that the size has decreased a lot, but when running repairDatabase the size gets back to its original size
[16:54:36] <queretaro> am I doing something wrong?
[16:55:00] <queretaro> obviously I am ^^"
[16:55:40] <queretaro> the thing is that disk is getting fuller and fuller, and would like to decrease the size of that collection
[17:15:26] <rkgarcia> :O queretaro
[19:20:14] <Diggsey> how do you get the ID of a document inserted from the mongodb repl?
[19:28:59] <Diggsey> surely it's possible?
[19:30:49] <StephenLynx> repl?
[19:32:12] <uuanton> anyone knows how to setup route 53 point to replica set ? that if primary is down dns resolve to new primary. Thanks
[19:39:13] <GothAlice> Diggsey: If you examine how db.collection.insert works in the REPL (type: "db.collection.insert" without quotes and press enter) you'll see that it injects an ID if one isn't given, but doesn't, ah, record that fact anywhere.
[19:39:55] <GothAlice> Specifically http://s.webcore.io/1F0b2w0o3F1A < this bit. Now, a few lines later a private variable is updated to track that ID, but AFIK it's not accessible from the REPL itself.
[19:40:48] <uuanton> GothAlice I know mongodb has its own dns resolution but what if primary server is down
[19:40:49] <GothAlice> StephenLynx: Read, Evaluate, Print, Loop — the name for a typical "interactive shell".
[19:41:34] <dbackeus> I want to create a unique compound index for two fields, organization_id and slug, but only create the index if slug isn't null. Can I use a partialFilterExpression for this, if so how would the expression look like?
[19:47:37] <StephenLynx> ah
[19:52:19] <GothAlice> uuanton: MongoDB uses standard OS-level name resolution, AFIK. I.e. resolv() or natural resolution via socket construction. What happens if resolution fails is what you'd expect: things stop working. ;P This typically won't matter during runtime; it matters most during initial connection construction / startup, and any time there's a reconnection needed.
[19:52:45] <GothAlice> uuanton: This is why I have a little management script on all my nodes that automatically updates /etc/hosts with the DNS names of nodes as they come online / go offline. No external DNS dependencies.
[19:53:37] <uuanton> thanks
[20:09:27] <energizer> How do I group by one field and then count the number of distinct values in another field?
[20:13:40] <deathanchor> energizer: aggregate or write a code snippet to write aggregated info another location.
[20:50:30] <Diggsey> GothAlice: fancy seeing you here :P thanks - I guess I'll just manually add the ID before calling insert
[22:08:56] <Boomtime> @ams_: yes, when it's shutdown you should find the file is empty