【nginx】【fastdfs】報錯ERROR - file: /root/fastdfs-nginx-module/src//common.c, line: 709,頁面400錯誤

場景:在搭建fastdfs後,配置完nginx及對應的fastdfs-nginx-module模塊後,於是訪問nginx,發現成功了。

但當我訪問文件的路徑時,報400錯誤。

搭建FastDFS文件服務器後,配置fastdfs-nginx-module模塊時,查看nginx中logs文件夾下error文件發現

ERROR - file: /root/fastdfs-nginx-module/src//common.c, line: 709, expect parameter token or ts in url, uri: /group1/M00/00/00/wKiWtV1H4eKAKE4YAAABAE3E6HQ3627.gif

所以我的nginx配置是這樣的

問題就出在ngx_fastdfs_module這個引用模塊內。

通過排查發現,發現與/etc/fdfs/http.conf文件中token有關

於是我的文件是這樣的

此處應該改爲http.anti_steal-check_token=false或空

檢查防盜鏈系統

vi /etc/fdfs/http.conf

http.anti_steal.check_token=false

再次重啓nginx

/usr/local/nginx/sbin/nginx -s reload

刷新頁面

訪問成功!

 

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章