- 论坛徽章:
- 2
|
回复 12# fashchina
我安装的版本信息:FastDFS_v5.03.tar.gz , fastdfs-nginx-module_v1.15.tar.gz , nginx-1.4.7.tar.gz , libfastcommon-master.zip,
这些都成功安装后,我在linux创建一个目录为data,然后将storage和tracker存储目录都指定为/data这个目录
测试上传文件:/usr/bin/fdfs_upload_file /etc/fdfs/client.conf /etc/fdfs/client.conf
成功返回如下信息:group1/M00/00/00/wKgH7VTxa4uAftqwAAAFptd1tno98.conf
cd /usr/local/nginx/conf/
vi nginx.conf
添加:
location /group1/M00{
alias /data/data;
ngx_fastdfs_module;
}
cd /etc/fdfs/
vi mod_fastdfs.conf
##include http.conf 找到这个在前面加一个#,因为我安装的fastDFS版本没有http.conf这个配置文件,所以加个#说明不引用这个配置文件
url_have_group_name = true ,location /group1/M00这里我指定了分组group1,所以这里要设置为true
nginx开启:/usr/local/nginx/sbin/nginx,网页输入192.168.7.237,看看能否正常访问nginx首页
打开网页输入:192.168.7.237/group1/M00/00/00/wKgH7VTxa4uAftqwAAAFptd1tno98.conf,就可以访问了
我配置的就这些了,没有设置权限的什么
|
|