./configure --conf-path=PATH does not work
on 2009-05-03 14:14
on 2009-05-04 00:27
> ./configure --conf-path=PATH > does not work I'm sure it will help if you tell Igor what version you are running, what platform you are running it on, what other configure options you used, and what exactly happens.
on 2009-05-04 18:12
nginx-0.6.36 Linux test 2.6.18-53.el5 #1 SMP Wed Oct 10 16:34:19 EDT 2007 x86_64 x86_64 x86_64 GNU/Linux Thanks. 2009/5/4 Jim O. <email@example.com>
on 2009-05-05 12:43
é™ˆæ˜ŒèŒ‚ Wrote: ------------------------------------------------------- > > > > I can confirm that there appears to be a bug or three. I am running Linux 2.6.18-128.1.6.el5 #1 SMP Wed Apr 1 09:10:25 EDT 2009 x86_64 x86_64 x86_64 GNU/Linux I was running nginx 0.7.53 but configured 06.36 with # ./configure ---conf-path=/etc/nginx It compiled properly but after running make install, nginv -V still showed that 0.7.53 was installed with my old configure options. Further, make install copied the config files to /etc, not to /etc/nginx. I then tried to copy objs/nginx to /usr/local/sbin and got an error: # cp objs/nginx /usr/local/sbin cp: overwrite `/usr/local/sbin/nginx'? y cp: cannot create regular file `/usr/local/sbin/nginx': Text file busy I stopped nginx and was able to copy the file and confirmed that now nginx -V showed # nginx -V nginx version: nginx/0.6.36 built by gcc 4.1.2 20080704 (Red Hat 4.1.2-44) configure arguments: --conf-path=/etc/nginx but...etc/nginx, which I had created, was empty. The files were in /etc. I tried the same with # ./configure ---conf-path=/etc/nginx/etc This time the config files were copied to /etc/nginx. Again, make install failed to install the new binary so I did it manually again, and also manually copied the config files to /etc/nginx/etc. Starting nginx it was clear that it was not using /etc/nginx/nginx.conf or /etc/nginx/etc/nginx.conf, but was reading /usr/local/nginx/conf/nginx.conf. I had different numbers of workers in each so I am certain. I tired running configure with a trailing slash at the end of the path and nothing changed. The config files were installed one level up and the binary was not installed. Starting nginx always resulted in it reading nginx.conf from the default location. Posted at Nginx Forum: http://forum.nginx.org/read.php?2,1713,1745#msg-1745
on 2009-05-05 12:54
On Mon, May 04, 2009 at 11:30:12AM -0400, Jim O. wrote: > > 2009/5/4 Jim O. > > > what exactly happens. > > > > > > > > I can confirm that there appears to be a bug or three. > > I am running Linux 2.6.18-128.1.6.el5 #1 SMP Wed Apr 1 09:10:25 EDT 2009 x86_64 x86_64 x86_64 GNU/Linux > > I was running nginx 0.7.53 but configured 06.36 with > > # ./configure ---conf-path=/etc/nginx ./configure --conf-path=/etc/nginx/nginx.conf
on 2009-05-05 16:08
On Mon, May 04, 2009 at 03:55:36PM +0000, Jim O. wrote: > Hits self in head and says "Dumkopf!". > > I always use default location. > > Does that explain why make install failed? What do you mean by failed ? If this: # cp objs/nginx /usr/local/sbin cp: overwrite `/usr/local/sbin/nginx'? y cp: cannot create regular file `/usr/local/sbin/nginx': Text file busy then it's standard unix feature for running process - you need to do mv /usr/local/sbin/nginx /usr/local/sbin/nginx.old cp objs/nginx /usr/local/sbin/
on 2009-05-05 17:30
Igor S. wrote: > What do you mean by failed ? If this: > > # cp objs/nginx /usr/local/sbin > cp: overwrite `/usr/local/sbin/nginx'? y > cp: cannot create regular file `/usr/local/sbin/nginx': Text file busy > > then it's standard unix feature for running process - you need to do > > mv /usr/local/sbin/nginx /usr/local/sbin/nginx.old > cp objs/nginx /usr/local/sbin/ > No. I figured it out. I always install nginx in my config as /usr/local/sbin/nginx. Since I didn't specify in the test config, It was installed as /usr/local/nginx/sbin/nginx. I didn't realize this. I usually configure --sbin-path=/usr/local/sbin/nginx When I saw # whereis nginx nginx: /etc/nginx /usr/local/sbin/nginx /usr/local/sbin/nginx.old /usr/local/nginx it didn't show the binary in /usr/local/nginx/sbin/ So it appeared to me as if the binary had not been installed, because when I ran [root@mercury nginx-0.6.36]# nginx -v nginx version: nginx/0.7.54 I understand why that is. I was evidently having a series of blond moments today. Sorry. I can confirm that when I configured correctly # ./configure --conf-path=/etc/nginx/nginx.conf and run new binary /usr/local/nginx/sbin/nginx that it works as expected.