I am Deborah.
Check out my work
or read my blog.

Ubuntu 15.10, MongoDB and node.js

A short description on how to install MongoDB under Ubuntu 15.10 and how to use it with node.js. The reference is a tutorial using Mac, that's why I wanted to write down the small extra steps you have to take.

Installing MongoDB on Ubuntu 15.10

Download and install packages [source]:
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10
echo "deb http://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/3.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.0.list
sudo apt-get update
sudo apt-get install -y mongodb-org

Make it run with systemd instead of upstart [source]:
sudo mkdir -p /data/db/
sudo nano /lib/systemd/system/mongodb.service

Insert this code:

[Unit]
Description=High-performance, schema-free document-oriented database
After=network.target

[Service]
User=mongodb
ExecStart=/usr/bin/mongod --quiet [Install] WantedBy=multi-user.target

Reload service units:
sudo systemctl daemon-reload
Save and start the service:
sudo service mongodb start
Check whether it runs:
sudo service mongodb status

Create a node.js express application using MongoDB

You need this package first:
sudo apt-get install libkrb5-dev
Afterwards you can follow this guide from the point where he starts to install express and to create the app. With the above preparations everything else worked like he described it – you get a system based on a database model that you can edit on a webpage in no time. Have fun!

Say something

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

Posts from "Blog":

How to print (almost) invisible IR markers using a standard printerQuick, Draw! Generic drawings part 2The Art of CodingImperfect MandalasAutumn LeafsColor Explosion #25 years of KAZOOSH!Color explosionUbuntu 15.10, MongoDB and node.jsKaleidoscope of Fencinggit cheat sheetFractalsofxSortableListCrocket: hairband with jeans buttonWall painting for Marias birthdayLinux / Ubuntu + Serato Vinyl Control System + Pure DataWicket-Bootstrap – Navbar and Pageparameters – setting the active itemLinux Console SnippetsCrawling Traces @German award for multimedia mb21Crawling Traces History ViewerStreaming new.livestream.com with VLC and UbuntuCrawling Traces at Hechtfest / hechtgruenLinks: Data Security, Social Networks and Secure MailingFix: VMware Player crash on Ubuntu 13.04Xubuntu: Fix for Dockbarx bug not starting Thunar or TerminalUbuntu 12.10, libwebsockets and OFSetting up Meteor with Ubuntu 12.10 on an NTFS share partitionWebsite: KAZOOSH!Intermediate IsolinesThe barn door gets coloredSkype on Ubuntu 10.10 or 11.04 64bitElitebook 8440p vs UbuntuKryptografie & Datensicherheit – NotizenRandom Compilation IIRandom Compilation IAll You Can Eat in DresdenWebauftritt: ESE 2010