Bug 224166

Summary: www/nginx-full won't start with missing http.conf error
Product: Ports & Packages Reporter: Paul Suh <psuh>
Component: Individual Port(s)Assignee: Bartek Rutkowski <robak>
Status: New ---    
Severity: Affects Some People CC: m
Priority: ---    
Version: Latest   
Hardware: amd64   
OS: Any   

Description Paul Suh 2017-12-07 22:50:30 UTC
Installed latest nginx-full-1.12.2_2,2 via pkg. 

Error in /var/log/nginx/error.log: 

[2017-12-07 17:24:56] ERROR - file: ini_file_reader.c, line: 631, include file "http.conf" not exists, line: "#include http.conf"
[2017-12-07 17:24:56] ERROR - file: /wrkdirs/usr/ports/www/nginx-full/work/fastdfs-nginx-module-5a8110f/src/common.c, line: 155, load conf file "/usr/local/etc/fdfs/mod_fastdfs.conf" fail, ret code: 2

This appears to be coming from the fastdfs-nginx-module. My GoogleFu turned up this link with the fix, but I can't locate the http.conf file. 

http://blog.csdn.net/freewebsys/article/details/45150941

I couldn't find a valid http.conf file in the file system, so as a test I created an empty one by doing

touch /usr/local/etc/fdfs/http.conf

This led to a further error at which point I give up. 

[2017-12-07 17:42:22] ERROR - file: client_func.c, line: 112, conf file "/usr/local/etc/fdfs/mod_fastdfs.conf", host "tracker" is invalid

From the output of nginx -V, it appears that the fdfs module is compiled in, with no way to disable or not load it.
Comment 1 Mikhail Emelchenkov 2018-01-18 18:44:17 UTC
I just installed the package and did exactly the same what you wrote there: touched http.conf file. To workaround further, edit mod_fastdfs.conf and set parameter "load_fdfs_parameters_from_tracker" to "false". Then nginx starts OK.