WWW.DBVERSITY.COM
WWW.DBVERSITY.COM
Menu
  • Home
  • About us
  • Discussions
  • Login / Register
Welcome to the world of Database Technologies
Browse: Home » dbversity » Page 14

Shard key can not exceed 128 characters ?

February 16, 2016 · by dbversity · in MongoDB

Shard key can not exceed 128 characters, if you try so Mongo doesn’t create an Index for that Shard key and as a result such sharded collection without index for sharding key will case performance degradation.   mongos> use sharding_test;…

$setOnInsert with a shard key – not possible ?

February 16, 2016 · by dbversity · in MongoDB

Having the collection empty, when trying to do an upsert using $setOnInsert on a shard key I get the following error: Can’t modify shard key’s value. field: card: 1.0 collection: vizvid.total_video_views mongos> db.dbversity.status() { “sharded” : true, “ns” : “dbfry.dbversity”,…

The Top Five Sites for Hiring Software Engineers

February 12, 2016 · by dbversity · in Generic

Sick of spending weeks looking for the right software engineer? Thankfully, there are dozens of websites that will do it for you for a small commission. Don’t worry about the money — the investment will pay off when your project…

Full text search in MongoDB

January 27, 2016 · by dbversity · in MongoDB

This is a custom implementation created by the MongoDB developers as a specific index type, and is due to be launched as an experimental feature in MongoDB 2.4. It has features such as: Full text search as an index type…

MongoDB Fragmentation best practices.

January 27, 2016 · by dbversity · in MongoDB

Q – Does data file fragmentation in MongoDB reduce the amount of data cached in memory Yes, the memory mapping approach used by MongoDB maps files directly to memory. If there is fragmentation in these files, this will be mapped…

[MongoDB]: Querying multiple collections with a JavaScript

January 18, 2016 · by dbversity · in MongoDB

Imagine “my_newimage_db” database as multiple collections (say month as collection name in our example below) and what if I would like to search a value of a field and check whether which collection has a value for it. For this…

MongoDB Triggers ?!!

January 14, 2016 · by dbversity · in MongoDB

1) Equivalent to RDBMS triggers in MongoDB ? There is no direct functionality available in MongoDB equivalent to triggers. However, we can achieve similar results using couple of solutions: (a) MongoDB’s “Tailable Cursors” Tailable cursors are conceptually equivalent to the…

MongoDB Monitoring script

January 7, 2016 · by dbversity · in MongoDB

#!/bin/bash from=”Alerts@dbversity.com” to=”dbversity@gmail.com” subject=”MongoDB Monitoring Alerts : Long running queries and No. of Open connections” echo ” Hello Team,” > /tmp/email_body.txt echo ” ” >> /tmp/email_body.txt echo “There are long running queries on the MongoDB server, please find attached txt…

How to drain a MongoDB Shard

January 6, 2016 · by dbversity · in MongoDB

use dbversity db.dbfry.ensureIndex( { user_id : 1 }, { unique : true }) sh.enableSharding(“dbversity”) sh.shardCollection(“dbversity.dbfry”, {“user_id”:1}) sh.startBalancer() sh.getBalancerState() sh.isBalancerRunning() use dbversity for(var i = 1; i <= 100000 ; i++){db.dbfry.insert({“user_id” : i , “name” : “bulk-inserts”, ” Iteration: ” :…

Command to know Shard distribution from mongos/router

January 6, 2016 · by dbversity · in MongoDB

mongos> sh.status() — Sharding Status — sharding version: { “_id” : 1, “minCompatibleVersion” : 5, “currentVersion” : 6, “clusterId” : ObjectId(“568d598d58c8ebe6f4ccaf19”) } shards: { “_id” : “rs1”, “host” : “rs1/dbversity.com:27010,dbversity.com:27011” } { “_id” : “rs2”, “host” : “rs2/dbversity.com:27020,dbversity.com:27021” } {…

← Previous 1 … 13 14 15 … 49 Next →

Categories

Categories

Copyright © 2025 WWW.DBVERSITY.COM

Powered by WordPress and Origin