|
As of v3.6, you can make the command return the epoch by passing fullMetadata = true:
> db.adminCommand({ getShardVersion: 'test.user', fullMetadata: true })
|
{
|
"configServer" : "...",
|
"inShardedMode" : false,
|
"mine" : Timestamp(0, 0),
|
"global" : Timestamp(1, 0),
|
"metadata" : {
|
"collVersion" : Timestamp(1, 0),
|
"collVersionEpoch" : ObjectId("5a305788bbad589bfcc5f216"),
|
"shardVersion" : Timestamp(1, 0),
|
"shardVersionEpoch" : ObjectId("5a305788bbad589bfcc5f216"),
|
"keyPattern" : {
|
"x" : 1
|
},
|
"chunks" : [
|
[
|
{
|
"x" : { "$minKey" : 1 }
|
},
|
{
|
"x" : { "$maxKey" : 1 }
|
}
|
]
|
],
|
"pending" : [ ]
|
},
|
"ok" : 1,
|
"$configServerState" : {
|
"opTime" : {
|
"ts" : Timestamp(1513117635, 3),
|
"t" : NumberLong(1)
|
}
|
}
|
}
|
|