高性能分布式文件存储及文件下载解决方案-Nginx支持FastD

2019-10-11  本文已影响0人  李小磊_0867

Nginx支持FastDFS配置

对于Nginx支持FastDFS,只需要在安装Nginx时,安装ngx-fastdfs-module模块即可。

cd /home/fastdfs/fastdfs-nginx-module-1.20/src

将mod_fastdfs.conf拷贝到/etc/fdfs目录中。并对该文件进行编辑:
主要修改:track_server、storage_server_port、group_name、store_path0、base_path
  1. mod_fastdfs.conf文件中tracker_server的端口同tracker.conf中port一致;
  2. mod_fastdfs.conf文件中storage_server_port的端口同storage.conf中port一致;
  3. Fastdfs-nginx-module会用到以下文件,拷贝到了指定位置/etc/fdfs
    • anti-steal.jpg
    • http.conf
    • mime.types
ngx_module_incs="/usr/include/fastdfs /usr/include/fastcommon/"
CORE_INCS="$CORE_INCS /usr/include/fastdfs /usr/include/fastcommon/"
./configure --add-module=/home/fastdfs/fastdfs-nginx-module-1.20/src

安装成功后,即可。安装位置:/usr/local/nginx

cd /usr/local/nginx/conf
vim nginx.conf
./usr/local/nginx/sbin/nginx
wget http://192.168.113.144:9000/M00/00/00/wKhxkF1oHGGAduS4ABZJFe3_-Oc55_big.epub
上一篇 下一篇

猜你喜欢

热点阅读