Windows服务器Azure云编译安装MariaDB教程

www.111cn.net 编辑:future 来源:转载
安装MariaDB数据库最多用于linux系统中了,下文给各位介绍在Windows服务器Azure云编译安装MariaDB教程,希望本文能帮助到各位。
 
试用1元Windows Azure,带宽都是杠杠的。下面演示下Windows Azure下编译安装LNMP环境,系统环境是Ubuntu 14.04 TLS版
软件版本:
数据库:mariadb-10.0.13 Stable
PHP:php-5.5.15 Stable
Nginx:nginx/1.4.6 (Ubuntu)(这里Nginx采用Ubuntu的apt安装方式)
1.新建MySQL用户:
考虑到系统安装,新建的用户不能登录(nologin),编辑 vi /etc/shells 添加 “/usr/sbin/nologin”使系统支持创建nologin用户
useradd -m /app/mysql -s /usr/sbin/nologin -u 555 mysql
2.安装编译环境和安装MariaDB已经PHP依赖包:
apt-get install build-essential
apt-get install libncurses5-dev cmake bison libxml2 libxml2-dev libxslt1-dev libcurl4-openssl-dev libbz2-dev
libpcre3 libpcre3-dev unzip openssl libssl-dev libpng12-dev libfreetype6-dev libjpeg-dev libmcrypt-dev
libldap2-dev libsasl2-dev libboost-dev
3.下载并编译安装MariaDB、PHP
wget http://cn2.php.net/get/php-5.5.15.tar.bz2/from/this/mirror
wget http://mirrors.neusoft.edu.cn/mariadb/mariadb-10.0.13/source/mariadb-10.0.13.tar.gz
1).安装目录分别为:/app/mysql 和 /app/php5
2).cmake . -DCMAKE_INSTALL_PREFIX=/app/mysql/ -DMYSQL_DATADIR=/app/mysql/data/
-DSYSCONFDIR=/app/mysql/etc/ -DMYSQL_UNIX_ADDR=/app/mysql/tmp/mysqld.sock -DMYSQL_TCP_PORT=3336
-DWITH_SSL=system -DWITH_FEDERATED_STORAGE_ENGINE=1 -DWITH_ZLIB=system -DENABLED_LOCAL_INFILE=1
-DDEFAULT_CHARSET=utf8 -DDEFAULT_COLLATION=utf8_general_ci -DMYSQL_USER=mysql
3)../configure --prefix=/app/php5 --with-config-file-path=/app/php5/etc/ --with-mysql=mysqlnd
--with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-mysql-sock=/app/mysql/tmp/mysqld.sock --with-freetype-dir
--with-jpeg-dir --with-png-dir --with-zlib --enable-xml --disable-rpath --enable-bcmath --enable-shmop
--enable-sysvsem --enable-inline-optimization --with-curl --enable-mbregex --enable-mbstring --with-mcrypt
--with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-ldap
--with-ldap-sasl --with-xmlrpc --enable-zip --enable-soap --enable-fpm --with-fpm-user=www-data
--with-fpm-group=www-data --enable-opcache
Ubuntu14.04 编译安装新版本的PHP5.5可能会出现如下错误:
/usr/bin/ld: ext/ldap/.libs/ldap.o: undefined reference to symbol 'ber_strdup@@OPENLDAP_2.4_2'
//usr/lib/x86_64-linux-gnu/liblber-2.4.so.2: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1
遇到这种类似的情况,说明「./configure 」?]抓好一些环境变数值。解决方法,来自老外的一篇文章:
在PHP源码目录下 vi Makefile 找到 EXTRA_LIBS 行,在行末添加 ‘ -llber ‘ 保存退出再次make即可。
到此 Ubuntu编译安装MariaDB就完成了,关于Nginx连接PHP这里就不多说了,下面是此次编译的结果:http://azure0.iloxp.com/tz.php 这只是测试用的,截图留着哈:

error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status的更多相关文章

  1. GLFW3出error adding symbols: DSO missing from command line解决

    背景:使用OpenGL的GLFW3.1库的时候,使用其中一些代码 报error adding symbols: DSO missing from command line 因为使用的是Qcreator ...

  2. qt opencv编译错误 /usr/local/lib/libopencv_imgcodecs.so.3.1:-1: error: error adding symbols: DSO missing from command line

    转载自:http://tbfungeek.github.io/2016/03/05/Opencv-%E5%AE%89%E8%A3%85%E8%BF%87%E7%A8%8B%E4%B8%AD%E5%87 ...

  3. error adding symbols:DSO missing from command line

    编译时加上-lz,如果是使用eclipse,则在添加库z

  4. gcc编译错误:DSO missing from command line

    在用gcc 编译连接的时候,可能会遇到类似以下的错误: /usr/bin/ld: test_desktop_utils-test-desktop-utils.o: undefined referenc ...

  5. DSO missing from command line

    最近项目正经历着一次更新,一系列编译工具都进行了大版本的升级,随时而来的是,原本正常编译的代码出现了大量的warning,最终编译失败,其 中一个问题困扰了比较长的时间,虽然fix的方法不难,但是一直 ...

  6. error: ld returned 1 exit status 和 error:undefined reference

    undefined reference 往往是链接时出现错误,无法解析引用.这篇文章总结的很好undefined reference问题总结 error: ld returned 1 exit sta ...

  7. Arduino上“Collect2.exe: error: ld returned 5 exit status”错误的解决方法

    1.运行环境 Windows xp; Arduino1.6.11 IDE. 2.问题 在Arduino编译时,经常出现如下的错误: collect2.exe: error: ld returned 5 ...

  8. moc_XXXX.o:(.data.rel.ro._ZTI12CalculatorUI[_ZTI12CalculatorUI]+0x10): undefined reference to `typeinfo for QWidget' collect2: error: ld returned 1 exit status make: *** [Makefile:144: myCalculator]

    main.cpp:(.text.startup+0x22): undefined reference to `QApplication::QApplication(int&, char**, ...

  9. Dev C++编写C/C++程序 出现[Error] ld returned 1 exit status报错分析及解决

    debug系列第一弹,不知道大家写程序的时候是不是都遇到过如题的报错. 我本人是经常遇到这行熟悉的令人不知所措的报错,可能是我太笨了 有时候百度无果也差不到原因,那就汇总一下目前我遇到的情况吧--持续 ...

随机推荐

  1. JavaIO中的Reader和writer

    1.reader package com.io.Reader; import java.io.BufferedReader; import java.io.FileInputStream; impor ...

  2. 扩展KMP

    刘雅琼论文 http://wenku.baidu.com/view/8e9ebefb0242a8956bece4b3.html 论文讲的非常详细. 给定母串S,子串T,n=strlen(S),m=st ...

  3. BZOJ-1206 虚拟内存 Hash+离散化+Priority_Queue

    闻说HNOI每年都有一道Hash. 1206: [HNOI2005]虚拟内存 Time Limit: 50 Sec Memory Limit: 162 MB Submit: 330 Solved: 2 ...

  4. easyVS

    easyVS 详细说明点这里

  5. [NOIP2010] 提高组 洛谷P1514 引水入城

    题目描述 在一个遥远的国度,一侧是风景秀美的湖泊,另一侧则是漫无边际的沙漠.该国的行政区划十分特殊,刚好构成一个N 行M 列的矩形,如上图所示,其中每个格子都代表一座城市,每座城市都有一个海拔高度. ...

  6. Ubuntu学习总结-01 用VMware 8安装Ubuntu 12.04详细过程

    1 Ubuntu 下载地址 http://www.ubuntu.com/download/desktop 2 安装Ubuntu 转载用VMware 8安装Ubuntu 12.04详细过程 http:/ ...

  7. 浏览器查看cookie

    今天总结下,教你怎样查看一些浏览器的Cookie,比如IE.Firefox.Chrome的Cookies等.下面分块介绍,以后会关注一些没有讲到的浏览器获取Cookie的方法. 1.Firefox浏览 ...

  8. 让Windows 7内置Administrator 用户也能使用指纹登录

    前言 这周末重装了个系统,之前用windows 8 现在8.1预览版出来了,琢磨着是不是给升级玩玩.装上后感觉变化不大,后来一折腾,就换回windows 7 了(64位旗舰版).将安装时创建的用户删除 ...

  9. sqlmap注入检测

    1.列出可利用数据库: sqlmap  -u  url  --dbs 2.列出某个数据库中表: sqlmap  -u  url   --tables  -D  south sqlmap  -u  ur ...

  10. Database Password Hashes

    SQL Server 2000:- SELECT password from master.dbo.sysxlogins where name=’sa’ 0×010034767D5C0CFA5FDCA ...