在Ubuntu系統(tǒng)中安裝MariaDB數(shù)據(jù)庫(kù)的教程
MariaDB是一個(gè)開(kāi)源數(shù)據(jù)庫(kù)且100%與MySQL兼容,目標(biāo)是替代MySQL數(shù)據(jù)庫(kù)。
MariaDB的背景 :
2008年,MySQL被后來(lái)被Oracle在2010年收購(gòu)的Sun Microsystems收購(gòu)了。 最初被Sun公司的收購(gòu)由于符合項(xiàng)目的需要而受到MySQL社區(qū)的歡呼,但是這種情緒并沒(méi)有持續(xù)太久,接下來(lái)被Oracle的收購(gòu),不幸期望遠(yuǎn)遠(yuǎn)低于預(yù)期。許多MySql的開(kāi)發(fā)者離開(kāi)了Sun和Oracle公司開(kāi)始新的項(xiàng)目。在他們中間就有MySQL的創(chuàng)建者以及項(xiàng)目長(zhǎng)期技術(shù)帶頭人之一的Michael ‘Monty' Widenius。Monty和他的團(tuán)隊(duì)創(chuàng)建了MySQL的一個(gè)fork版本并且命名它為MariaDB。
本篇我們會(huì)討論如何在Ubuntu上安裝MariaDB。默認(rèn)上MariaDB的包并沒(méi)有在Ubuntu倉(cāng)庫(kù)中。要安裝MariaDB,我們首先要設(shè)置MariaDB倉(cāng)庫(kù)。
設(shè)置 MariaDB 倉(cāng)庫(kù)
$ sudo apt-get install software-properties-common $ sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xcbcb082a1bb943db $ sudo add-apt-repository 'deb http://sfo1.mirrors.digitalocean.com/mariadb/repo/10.0/ubuntu trusty main'
安裝 MariaDB :
$ sudo apt-get update $ sudo apt-get install mariadb-server
在安裝中,你會(huì)被要求設(shè)置MariaDB的root密碼。

從命令行連接到MariaDB :
linuxtechi@mail:~$ mysql -uroot -p Enter password: Welcome to the MariaDB monitor. Commands end with ; or \g. Your MariaDB connection id is 40 Server version: 10.0.14-MariaDB-1~trusty-log mariadb.org binary distribution Copyright (c) 2000, 2014, Oracle, SkySQL Ab and others. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. MariaDB [(none)]>
MariaDB 服務(wù)
$ sudo /etc/init.d/mysql stop $ sudo /etc/init.d/mysql start
版權(quán)聲明:本站文章來(lái)源標(biāo)注為YINGSOO的內(nèi)容版權(quán)均為本站所有,歡迎引用、轉(zhuǎn)載,請(qǐng)保持原文完整并注明來(lái)源及原文鏈接。禁止復(fù)制或仿造本網(wǎng)站,禁止在非maisonbaluchon.cn所屬的服務(wù)器上建立鏡像,否則將依法追究法律責(zé)任。本站部分內(nèi)容來(lái)源于網(wǎng)友推薦、互聯(lián)網(wǎng)收集整理而來(lái),僅供學(xué)習(xí)參考,不代表本站立場(chǎng),如有內(nèi)容涉嫌侵權(quán),請(qǐng)聯(lián)系alex-e#qq.com處理。
關(guān)注官方微信