fastdfs 入門安裝過程

1、準備須要的安裝包:java

       1.fastdfs_V5.05.tar.gznginx

       2.libfastcommon.tar.gzspa

       3.nginxrest

       4.pcre日誌

       5.zlibcode

       6.nginx_fastdfs_mod進程

2、安裝libfastcommonssl

./make.sh  
 ./make.sh install

建立軟連接:openssl

ln -s /usr/lib64/libfastcommon.so /usr/local/lib/libfastcommon.so
  ln -s /usr/lib64/libfastcommon.so /usr/lib/libfastcommon.so
  ln -s /usr/lib64/libfdfsclient.so /usr/local/lib/libfdfsclient.so
  ln -s /usr/lib64/libfdfsclient.so /usr/lib/libfdfsclient.so

3、安裝fastdfs.*.gz it

./make.sh
./make.sh install

4、配置tracker

主要修改bind_address、port、basepath
啓動tracker:
fdfs_trackerd /etc/fdfs/tracker.conf restart

5、配置storage同上

6、安裝配置nginx

./configure \
--prefix=/usr/local/nginx \
--sbin-path=/usr/local/nginx/nginx \
--conf-path=/usr/local/nginx/nginx.conf \
--pid-path=/usr/local/nginx/nginx.pid \
--error-log-path=/home/tanghao/nginx/logs/error.log \
--with-pcre=/home/tanghao/filetemp/pcre-8.38 \
--with-zlib=/home/tanghao/filetemp/zlib-1.2.8 \
--with-http_dav_module \
--with-http_flv_module \
--with-http_stub_status_module \
--with-http_ssl_module \
--with-openssl=/home/tanghao/filetemp/openssl-1.0.2f  \
--add-module=/home/tanghao/filetemp/fastdfs-nginx-module/src

這裏糾結了好久,不知道爲何,編譯安裝完nginx後,啓動nginx時只出現了一個master進程,沒有worker,感到很是奇怪。

7、拷貝配置文件,fastdfs/conf中的mine和http文件,拷貝到/etc/fdfs目錄下。

8、fastdfs的軟連接還要配置M00的。

9、我須要查一下,爲爲何只有master,沒有worker...

 

 

找到問題緣由了,一時心急忘記看nginx的error日誌了,緣由是由於訪問fastdfs的目錄問題,在nginx.conf前面加上user root;就好了。

相關文章
相關標籤/搜索