Working with Rockmongo

Advertisements


Rockmongo is a MongoDB administration tool using which you can manage your server, databases, collections, documents, indexes and a lot more. It provides a very user-friendly way for reading, writing and creating documents. It is similar to PHPMyAdmin tool for PHP and MySQL.

Downloading Rockmongo

You can download the latest version of Rockmongo from here: http://rockmongo.com/downloads

Installing Rockmongo:

Once downloaded, you can unzip the package in your server root folder and rename the extracted folder to rockmongo. Open any web browser and access the index.php page from the folder rockmongo. Enter admin/admin as username/password respectively.

Working with Rockmongo

We will now be looking at some basic operations that you can perform with Rockmongo.

Creating New Database:

To create a new database, click on Databases tab. Click Create New Database. On the next screen, provide the name of the new database and click on Create. You will see a new database getting added in the left panel.

Creating New Collection:

To create a new collection inside a database, click on that database from left panel. Click on the New Collection link on top. Provide the required name of the collection. Do not worry about the other fields of Is Capped, Size and Max. Click on Create. A new collection will be created and you will be able to see it in the left panel.

Creating New Document:

To create a new document, click on the collection under which you want to add documents. When you click on a collection you will be able to see all the documents within that collection listed there. To create a new document, click on the Insert link at the top. You can enter the document's data either in JSON or array format and click on Save.

Export/Import Data:

To import/export data of any collection, click on that collection and then click on Export/Import link on the top panel. Follow the next instructions to export your data in zip format and then import the same zip file to import back data.



Advertisements
Advertisements