Page 1 of 3

[atomic] Nginx 0.7.64

Posted: Wed Feb 10, 2010 3:49 pm
by scott
Nginx [engine x] is an HTTP(S) server, HTTP(S) reverse proxy and IMAP/POP3 proxy server written by Igor Sysoev.

Changelog:
This is the initial release to the atomic repository, for all platforms

To install:
yum install nginx

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 12, 2010 1:08 pm
by dayo
Nice one.

How do we find out where the various conf files are or I suppose I mean to say where does it install to?

I read some Nginx guide that suggest installing with yum puts things in different locations to when it is compiled from source.

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 12, 2010 1:22 pm
by scott
Meaning we put things in the right place :P You can dump the contents of an rpm with:

rpm -ql <packagename>

This is a purely anecdotal scientifically insignificant test showing a native apache + php hello-world and the same thing with nginx in the loop:

Apache only:
Requests per second: 1977.38 [#/sec] (mean)

Nginx + Apache:
Requests per second: 7310.11 [#/sec] (mean)

Does that mean you will quadruple performance on your system? Probably not, but I hope it does! :P

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 12, 2010 1:34 pm
by dayo
scott wrote:Meaning we put things in the right place
Yes you do indeed.

Imagemagick binaries are put into /usr/bin with yum while compiling from sources sticks them into an unexpected /usr/local/bin. Unfortunately though yum still installs v6.0.x which has been the subject of many vulnerability warnings so I have had to adjust to live with the /usr/local/bin of the compiled source.

Anyway, I digress. I was banging my head on the wall a while back trying to get nginx on my plesk server (http://www.atomicorp.com/forum/viewtopi ... inx#p19020) and had to give up because of how difficult it was to change the default apache port on plesk. V9.3.0 finally makes it workable since they have addressed that issue although they should have put in so that it can be done directly from plesk but mustn't complain too much. half bread is better than none.

P.S. I assume I need to have moved Apache before trying to install nginx.

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 12, 2010 1:42 pm
by scott
You know they backport those fixes right?

Anyway, check this out: http://download1.parallels.com/Plesk/PP ... ion-guide/

There are a few steps to integrate this outside of the nginx config. If I read this correctly you've got to create templates, and jobs in the event manager to automate things. At least there are some existing examples in here. If you get a chance to field this on a live box post your notes here, and I'll see what we can do to make a separate plesk integration module.

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 12, 2010 2:05 pm
by dayo
scott wrote:You know they backport those fixes right?
No I didn't. Just saw the version number and acted on that.

Thanks for the link. I have downloaded the pdf file and the commands there didn't work due to the spacing and stuff.

I'll have a bash at it.

Re: [atomic] Nginx 0.7.64

Posted: Thu Feb 18, 2010 5:46 pm
by dayo
Hi

Are there any plans to add mod_rpaf to the repo?

Re: [atomic] Nginx 0.7.64

Posted: Thu Feb 18, 2010 7:11 pm
by scott
Yup, its on the list.

Re: [atomic] Nginx 0.7.64

Posted: Thu Feb 18, 2010 11:28 pm
by mikeshinn
Are there any plans to add mod_rpaf to the repo?
In fact our plan is to bundle ngix, rpaf, apache and the vhost glue all together in an upcoming version of ASL.

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 19, 2010 4:57 pm
by dayo
Nice to know.

On the nginx install, how do I know which nginx modules are installed and how do I add new ones if I want to … or do I need to compile from source for that?

Thanks

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 19, 2010 5:51 pm
by scott
You shouldnt have to do anything from source. I was able to test that successfully here as-is

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 19, 2010 6:39 pm
by dayo
Hi

Thanks for your replies.

I have installed it and it is proxying everything to apache on one site and serving static content on another fine with the pages feeling a bit snappier in loading. (I'll compile my notes and post later)

I was just looking at some of the additional modules on the nginx site and wondered which ones had been compiled with default install and wondered how to go about adding these modules in I want to.

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 19, 2010 6:44 pm
by scott
Sweet, I was using ab to do performance testing here.

http://www4.atomicorp.com/channels/sour ... nginx.spec <- this is the spec file used for the package. It should answer your questions on the modules used. If you've got any recommendations for changes let me know.

Re: [atomic] Nginx 0.7.64

Posted: Fri Feb 19, 2010 7:04 pm
by dayo
Cool

I'll have a look. One that jumps out of the list is rewrite. This is actually why I ended up proxying everything in one instance as I couldn't use nginx to serve static content as this needed rewriting and I had been trying with the rewrites and getting no joy.

On the other example site, the paths are direct so no rewrites were needed.

Will look more and get back … probably tomorrow.

*PS: Noticed from the docs that rewrite is always compiled except if disabled so I need to figure out why my rewrites weren't working.

Re: [atomic] Nginx 0.7.64

Posted: Mon Feb 22, 2010 1:55 pm
by dayo
Hi

Noticed that nginx doesn't restart if the server is rebooted (which I did just for the hell of it).

Had to run "/sbin/chkconfig nginx on".

Should this be part of the default installation?