Created
April 2, 2015 21:57
-
-
Save danared/f0209fd650402af8a381 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ mongo --port 27018 | |
MongoDB shell version: 2.6.7 | |
connecting to: 127.0.0.1:27018/test | |
shard01:PRIMARY> show collections | |
mycollection | |
system.indexes | |
shard01:PRIMARY> db.mycollection.find() | |
{ "_id" : 1, "data" : "hello" } | |
{ "_id" : 3, "data" : "hello" } | |
{ "_id" : 5, "data" : "hello" } | |
{ "_id" : 7, "data" : "hello" } | |
{ "_id" : 9, "data" : "hello" } | |
{ "_id" : 11, "data" : "hello" } | |
shard01:PRIMARY> use local | |
switched to db local | |
shard01:PRIMARY> show collections | |
me | |
oplog.rs | |
slaves | |
startup_log | |
system.indexes | |
system.replset | |
shard01:PRIMARY> db.oplog.rs.find().pretty() | |
{ | |
"ts" : Timestamp(1422998530, 1), | |
"h" : NumberLong(0), | |
"v" : 2, | |
"op" : "n", | |
"ns" : "", | |
"o" : { | |
"msg" : "initiating set" | |
} | |
} | |
{ | |
"ts" : Timestamp(1422998574, 1), | |
"h" : NumberLong("-6781014703318499311"), | |
"v" : 2, | |
"op" : "i", | |
"ns" : "test.mycollection", | |
"o" : { | |
"_id" : 1, | |
"data" : "hello" | |
} | |
} | |
{ | |
"ts" : Timestamp(1422998579, 1), | |
"h" : NumberLong("-217362260421471244"), | |
"v" : 2, | |
"op" : "i", | |
"ns" : "test.mycollection", | |
"o" : { | |
"_id" : 3, | |
"data" : "hello" | |
} | |
} | |
{ | |
"ts" : Timestamp(1422998584, 1), | |
"h" : NumberLong("7215322058367374253"), | |
"v" : 2, | |
"op" : "i", | |
"ns" : "test.mycollection", | |
"o" : { | |
"_id" : 5, | |
"data" : "hello" | |
} | |
} | |
{ | |
"ts" : Timestamp(1422998588, 1), | |
"h" : NumberLong("-5372877897993278968"), | |
"v" : 2, | |
"op" : "i", | |
"ns" : "test.mycollection", | |
"o" : { | |
"_id" : 7, | |
"data" : "hello" | |
} | |
} | |
{ | |
"ts" : Timestamp(1422998591, 1), | |
"h" : NumberLong("-243188455606213719"), | |
"v" : 2, | |
"op" : "i", | |
"ns" : "test.mycollection", | |
"o" : { | |
"_id" : 9, | |
"data" : "hello" | |
} | |
} | |
{ | |
"ts" : Timestamp(1422998597, 1), | |
"h" : NumberLong("5040618552262309692"), | |
"v" : 2, | |
"op" : "i", | |
"ns" : "test.mycollection", | |
"o" : { | |
"_id" : 11, | |
"data" : "hello" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment