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. 团队项目--关于QQ项目的运行和总结

    目前为止该QQ项目实现如下功能:添加好友到好友列表,可以把好友在不同分类中移动,同时支持离线查找添加好友,离线更换头像,离线发送消息,保存所有好友聊天记录,发送窗口抖动,查看对方信息,更改/添加信息等 ...

  2. overlay-3

    if(typeof Shadowbox=="undefined"){ throw"Unable to load Shadowbox, no base library ad ...

  3. BZOJ-3669 魔法森林 Link-Cut-Tree

    意识到背模版的重要性了,记住了原理和操作,然后手打模版残了..颓我时间...... 3669: [Noi2014]魔法森林 Time Limit: 30 Sec Memory Limit: 512 M ...

  4. startx启动过程分析

    http://blog.csdn.net/hustwarhd/article/details/3069066 JiananHe 09/19/2008 目录 xinit 1.1      功能 1.2  ...

  5. Python之MySQL

    本文我们为大家介绍 Python3 使用 PyMySQL 连接数据库,并实现简单的增删改查. 什么是 PyMySQL? PyMySQL 是在 Python3.x 版本中用于连接 MySQL 服务器的一 ...

  6. codeforce626D (概率)

    D. Jerry's Protest time limit per test 2 seconds memory limit per test 256 megabytes input standard ...

  7. Memcache和Redis

  8. DOM 元素 属性和方法

    console.dir() namespaceURI: "http://www.w3.org/1999/xhtml" nextElementSibling: null nextSi ...

  9. hdu 1202 The calculation of GPA

    感觉本题没有什么好解释的,已知公式,直接编程即可. 1.统计所有 科目的学分 得到总学分 2.统计所有 成绩对应的绩点*对应的学分即可(如果成绩==-1直接continue,不进行统计),得到总绩点. ...

  10. 利用dedecms autoindex让文章列表加上序列号

    有些时候我们在制作模板的需要在文章标题前面加上序列号,可以通过织梦自带的autoindex属性来实现,实现方法很简单,只需要在序号递增的地方加上 这段代码就行,[field:global runphp ...