Skip to content

emka.web.id

menulis pengetahuan – merekam peradaban

Menu
  • Home
  • Tutorial
  • Search
Menu

Installing MongoDB Under Linux

Posted on January 7, 2012

The UNIX-based operating systems are extremely popular choices at the moment for hosting services, including web services, mail services, and, of course, database services. In this chapter, we’ll walk you through how to get MongoDB running on a popular Linux distribution: Ubuntu.

To make things simple (or perhaps more complicated, depending on your point of view), you have two ways of installing MongoDB under Ubuntu: you can install the packages automatically through socalled repositories, or you can install it manually. The next couple sections will walk you through both options.

Installing MongoDB Through the Repositories

Repositories are basically online directories filled with software. Every package contains information about the version number, prerequisites, and possible incompatibilities. This information is useful when you need to install a software package that requires another piece of software to be installed first because the prerequisites can be installed at the same time.

The default repositories available in Ubuntu (and other Debian-based distributions) contain MongoDB, but they may be out-of-date versions of the software. Therefore, let’s tell aptitude (the software you use to install software from repositories) to look at a custom repository. To do this, you need to add the following line to your repository-list (/etc/apt/sources.list):

deb http://downloads.mongodb.org/distros/ubuntu (version.number) 10gen

In the preceding line, version.number represents the distribution version. Let’s say your Ubuntu is version 10.4 (also called Ubuntu Lucid); in that case, the full line would look like this:

deb http://downloads.mongodb.org/distros/ubuntu 10.4 10gen

Next, you need to tell aptitude that it contains new repositories; you can do so using aptitude’s update command:

$ sudo aptitude update

The preceding line made aptitude aware of your manually added repository. This means you can now tell aptitude to install the software itself. You do this by typing the following command in the shell:

$sudo aptitude install mongodb-stable

As you may have guessed, the preceding line installs the current stable (production) version from MongoDB. If you wish to install the unstable (development) version from MongoDB, type in the following command instead:

$ sudo aptitude install mongodb-unstable

And this command installs the nightly build:

$ sudo aptitude install mongodb-snapshot

That’s all there is to it. At this point, MongoDB has been installed and is (almost) ready to use!

Installing MongoDB Manually

Next, we’ll cover how to install MongoDB manually. Given how easy it is to install MongoDB with aptitude automatically, you might wonder why you would want to install the software manually. For starters, not all Linux distributions use aptitude. Sure, a bunch of them do (including primarily the ones that are based on Debian Linux), but some don’t. Also, the packaging remains a work in progress, so it might be the case that there are versions not yet available through the repositories. It’s also possible that the version of MongoDB you want to use isn’t included in the repository (you might want to install an older version automatically). Installing the software manually also gives you the ability to run multiple versions of MongoDB at the same time.

Pages: 1 2

Terbaru

  • Ini Arti Kode Error FP26EV dan FP27EV di Aplikasi BriMO Serta Cara Mengatasinya!
  • Cara Jadi Clipper Modal Ngedit Video di TryBuzzer, Cocok Banget Buat Pemula!
  • Cara Pakai Beb6 Wifi Password Untuk Cek Jaringan di Sekitar Kalian
  • Inilah Review Lengkap Apakah Turbo VPN Extension Aman
  • Apa itu Toko Biru? Ini Istilah Olshop yang Perlu Kamu Tahu
  • Adswerve Inc Penipu? Ini Fakta di Balik Konsultan Digital Terkemuka Dunia!
  • Sering Ditelepon 08111? Simak Apakah Ini Penipuan atau Marketing Resmi Telkomsel
  • Inilah Cara Daftar dan Login Subsidi Tepat LPG 3 kg di Merchant Apps MyPertamina!
  • Akademi Crypto Penipu?
  • Belum Tahu Arti Paket Sedang Transit di TikTok Shop? Ternyata Ini Maksudnya Biar Kalian Nggak Panik!
  • Akun Paylater Tiba-tiba Diblokir? Jangan Panik, Gini Cara Mengatasinya Biar Lancar Jaya!
  • HP Vivo Sering Mati Sendiri Padahal Baterai Masih Banyak? Ini Penyebab dan Solusinya!
  • Inilah Cara Mengatasi BNI Mobile Banking Transaksi Tidak Dapat Dilanjutkan dan Penjelasan Kode Errornya!
  • Inilah Daftar Lengkap Tempat OVO PayLater Bisa Digunakan
  • Gini Caranya Biar Nggak Mati Topik Pas Lagi Main RP Role Play
  • Gini Caranya Atasi Kontak yang Sudah Dihapus Tapi Masih Ada di WA, Dijamin Ampuh!
  • Cara Mengatasi DJP Online Error 403 atau 405 dengan Mudah
  • Sering Lihat Kata Puqi di TikTok? Jangan Asal Tulis, Ternyata Ini Artinya!
  • Apa Itu HP Refurbished?
  • Cara Backup WhatsappGB Tanpa Hilangkan Chat
  • Belum Tahu? Ini Trik Dapat Battle Emote Ejen Ali Mobile Legends Gratis Permanen!
  • Kelebihan dan Kekurangan Paypal Indonesia 2026
  • Inilah Fungsi Web Browser Terbaru yang Bikin Internetan Kalian Jauh Lebih Aman!
  • Ini Cara Pinjaman Online Bank Mandiri Langsung Cair via Livin Tanpa Ribet
  • Gagal Tukar Pengguna Dapodik? Jangan Panik, Ini Trik Ampuh Buat Jenjang PAUD dan SD!
  • Game Terasa Berat Padahal HP Bagus? Ini Trik Setting WebView yang Jarang Orang Tahu!
  • Cara Simpan Video FreeReels ke Galeri Tanpa Watermark, Dijamin Aman dan Resmi!
  • Capek Mancing Terus? Coba Trik AFK Fish It Roblox 2026 Ini, 100% Gratis Tanpa Langganan!
  • Profil Andy Dahananto, Pilot Pesawat ATR Indonesia Air Yang Jatuh di Maros, Sulawesi Selatan
  • Update Pencarian Pesawat IAT: Suara Ledakan di Maros Bikin Geger, Ini Fakta Terbarunya!
  • Grain DataLoader Python Library Explained for Beginners
  • Controlling Ansible with AI: The New MCP Server Explained for Beginners
  • Is Your Headset Safe? The Scary Truth Bluetooth Vulnerability WhisperPair
  • Dockhand Explained, Manage Docker Containers for Beginners
  • Claude Co-Work Explained: How AI Can Control Your Computer to Finish Tasks
  • Begini Teknik KV Caching dan Hemat Memori GPU saat Menjalankan LLM
  • Apa itu State Space Models (SSM) dalam AI?
  • Begini Cara Mencegah Output Agen AI Melenceng Menggunakan Task Guardrails di CrewAI
  • Tutorial AI Lengkap Strategi Indexing RAG
  • Cara Membuat AI Voice Agent Cerdas untuk Layanan Pelanggan Menggunakan Vapi
  • Apa itu ToneShell? Backdoor atau Malware Biasa?
  • Apa itu Parrot OS 7? Ini Review dan Update Terbesarnya
  • Clipper Malware? Ini Pengertian dan Bahaya yang Mengintai Kalian
  • Kronologi Serangan Gentlemen Ransomware di Oltenia Energy
  • Apa itu CVE-2020-12812? Ini Penjelasan Celah Keamanan Fortinet FortiOS 2FA yang Masih Bahaya
Beli Pemotong Rumput dengan Baterai IRONHOOF 588V Mesin Potong Rumput 88V disini https://s.shopee.co.id/70DBGTHtuJ
Beli Morning Star Kursi Gaming/Kantor disini: https://s.shopee.co.id/805iTUOPRV

©2026 emka.web.id | Design: Newspaperly WordPress Theme