zoukankan      html  css  js  c++  java
  • ubuntu tengine 安装

    参考文章:http://wangyan.org/blog/install-openssl-from-source.html

    http://www1.site90.com/Linux/405.html

    http://tengine.taobao.org/book/appendix_c.html#nginxlinux    TENGINE官方说明文档

    http://www.openssl.org/source/openssl-1.0.1e.tar.gz   opensssl下载地址

    http://zlib.net/zlib-1.2.8.tar.gz       zlib下载地址

    http://ftp.exim.llorien.org/pcre/pcre-8.33.tar.gz   pcre下载地址1

    ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.33.tar.gz    pcre下载地址2

    需要安装g++ 用来编译

    sudo apt-get install g++

    要先装openssl,pcre,zlib, 记住 tengine的config时的路径都是解压后的路径,而不是安装路径

    默认用户 nobody

    默认用户组 nobody

    配置过程

    cd tengine(你的解压后的安装路径)
    
    ./configure --prefix=/usr/local/nginx   --with-zlib=/usr/local/zlib --with-openssl=/usr/local/openssl  --with-pcre=/usr/local/pcre
    
    make
    
    make install

    #####上面的3个路径写上比较好

    安装完以后,给网站路径改权限

    #ubuntu下原来是这样更改,用户属组

    #如果没有nobody用户组就加上
    groupadd nobody
    #更改nobody用户的所属组
    gpasswd -a nobody nobody


    #改权限,不让运行页面时可能会提示没权限
    chmod nobody:nobody
    /usr/local/nginx/html

    #启动 tengine
    /usr/local/nginx/sbin/nginx -s start


       不出意外的话, 用 web 浏览器 打开 localhost/   , 应该可以看到welcome tengine....字样

     让tengine支持php

         location ~ .php$ {
                #把root注释
            #root html; fastcgi_pass
    127.0.0.1:9000; fastcgi_index index.php; #fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
    # /usr/local/nginx/html是nginx的document_root,我把这个路径直接先写在这了,不然运行PHP 会提示FILE NOT found
    fastcgi_param SCRIPT_FILENAME
    /usr/local/nginx/html$fastcgi_script_name; include fastcgi_params; }
    PHP程序员 人在北京 如有需要,可以站内联系我!!!
  • 相关阅读:
    Fortran编译器之一GUN Fortran安装(Windows XP)
    c++动态绑定的技术实现
    c++标准库比较
    java array
    java常用的基础容器
    mac sublime text 3 add ctags plugin
    git fetch
    查看远程分支的log
    git删除分支
    detached HEAD state
  • 原文地址:https://www.cnblogs.com/flex_fly/p/3159360.html
Copyright © 2011-2022 走看看