hello,i am a linux system administrator ,and i have problem now,the nginx as picture server,the bandwidth is higher than apache in the same condition.For example,established connections is 3000,apache's bandwidth is about 4MB,but the nginx is about 7MB,i am sure the two servers run the same services,and in the same datacenter .what should i do,maybe i should modify config files,but i don't know what should i do.Could you help me,thanks!
on 14.08.2008 09:35
on 14.08.2008 09:50
On Thu, Aug 14, 2008 at 03:28:05PM +0800, cq wei wrote: > hello,i am a linux system administrator ,and i have problem now,the nginx as > picture server,the bandwidth > is higher than apache in the same condition.For example,established > connections is 3000,apache's bandwidth is about 4MB,but the nginx is about > 7MB,i am sure the two servers run the same services,and in the same > datacenter .what should i do,maybe i should modify config files,but i don't > know what should i do.Could you help me,thanks! did you have things like mod_expire enabled on apache?
on 14.08.2008 10:04
My god you are annoying. Wait for a reply like everybody else!
on 14.08.2008 11:40
Hi cq wei, On Don 14.08.2008 15:28, cq wei wrote: >hello,i am a linux system administrator ,and i have problem now,the >nginx as picture server,the bandwidth is higher than apache in the same >condition.For example,established connections is 3000,apache's >bandwidth is about 4MB,but the nginx is about 7MB,i am sure the two >servers run the same services,and in the same datacenter .what should i >do,maybe i should modify config files,but i don't know what should i >do.Could you help me,thanks! Does you mean that with 3000 R/s you deliver 4MB with Apache and 7MB with nginx? Are you sure that the requests are the same, the data which are deliverd and the r/s also? BR Aleks
on 14.08.2008 12:03
Also, look at gzip compression, you might want to have to turn that on in nginx (in case you have it in apache). I don't see any other way to have such a big difference without 1. difference with compression 2. difference with request ammount 3. difference with request caching, mod_expires (as mentioned before by almir) Lp
on 14.08.2008 13:08
I agree with you. 2008-08-14 Chancey 发件人: Tit Petric 发送时间: 2008-08-14 18:01:20 收件人: nginx 抄送: 主题: Re: trouble Also, look at gzip compression, you might want to have to turn that on in nginx (in case you have it in apache). I don't see any other way to have such a big difference without 1. difference with compression 2. difference with request ammount 3. difference with request caching, mod_expires (as mentioned before by almir) Lp
on 14.08.2008 16:54
I am sure,others have asked me the same question.So,I think that the problem is in config file. 2008/8/14 Aleksandar Lazic <al-nginx@none.at>
on 14.08.2008 18:33
On Thu, Aug 14, 2008 at 22:49:42, cq wei said... > I am sure,others have asked me the same question.So,I think that the > problem is in config file. I really don't see what difference the web server would make here. You should do some research and compare individual requests, rather than talking about vague large numbers, especially when you cannot guarantee that *exactly* the same requests were made to both servers. Right now, there are too many variables to know what's really going on.
on 15.08.2008 03:33
Maybe apache handled only 4MBps of traffic and nginx can handle much more? On Fri, 15 Aug 2008 09:06:38 +0800, "cq wei" <weichenqi@gmail.com> wrote: >> >>>> condition.For example,established connections is 3000,apache's >>> Are you sure that the requests are the same, the data which are >> Igor Clark • POKE • 10 Redchurch Street • E2 7DD • +44 (0)20 > 7749 5355 • >> www.pokelondon.com >> >> >> >> -- iDEV, podjetje za spletne storitve, d.o.o. Tomaž Marhat, CEO Brda 15A SI-2383 � martno pri Slovenj Gradcu SLOVENIA - EU Web: http://idev.si/ VAT #: SI43028195 Company ID #: 2346265 Mobile #: +386 70 819 789
on 15.08.2008 04:03
I use httpwatch to test a same image in apache and nginx.The result is
size
apache 457
nginx 699
I think that is where the question arises.
2008/8/15 iDEV d. o. o. <info@idev.si>
on 15.08.2008 04:31
I'm not sure if apache compresses images, but it is possible. And nginx does not compresses content by default. Maybe there's the diffrence.
on 15.08.2008 05:41
Do the test.I find use gzip is the same as not in nginx. 2008/8/15 iDEV d. o. o. <info@idev.si>
on 15.08.2008 07:01
On Fri, Aug 15, 2008 at 09:56:06AM +0800, walt wrote: > I use httpwatch to test a same image in apache and nginx.The result is > size > apache 457 > nginx 699 > I think that is where the question arises. What is this size ? Size of the image or size of image + HTTP header size ? What the size of the image itself ?
on 15.08.2008 07:30
I am not very sure,the image is 27.88KB itself. 2008/8/15 Igor Sysoev <is@rambler-co.ru>
on 15.08.2008 07:36
On Fri, Aug 15, 2008 at 01:24:45PM +0800, walt wrote:
> I am not very sure,the image is 27.88KB itself.
Then I do not understand what 457 and 699 mean.
on 15.08.2008 07:51
So do I,but why apache's is smaller than nginx,this is ture. 2008/8/15 Igor Sysoev <is@rambler-co.ru>
on 15.08.2008 08:05
Igor Sysoev wrote: >>>> I use httpwatch to test a same image in apache and nginx.The result is >>> http://sysoev.ru/en/ >>> >>> > Maybe I don't understand this whole discussion, but why doesn't someone just tcpdump both transactions and _see_ what the difference is? I can't imagine a system admin would take a week to hypothesize about config files when they could just dump the transactions to determine what is going on. Chaz
on 15.08.2008 08:10
On Fri, Aug 15, 2008 at 01:46:07PM +0800, walt wrote:
> So do I,but why apache's is smaller than nginx,this is ture.
Until you say what is 457 and 699 exactly the discussion will be
helpless.
Try tcpdump as it was suggested. Try debug log.
on 15.08.2008 08:46
By the way,I want to ask a question,is nginx as image server is better than apache?If you do test,plase tell me! 2008/8/15 Igor Sysoev <is@rambler-co.ru>
on 15.08.2008 09:49
Of course, i have tested . There are many examples of the Internet . I think now is the era of nginx . Apache is so heavy 2008-08-15 Chancey 发件人: walt 发送时间: 2008-08-15 14:44:40 收件人: nginx 抄送: 主题: Re: trouble By the way,I want to ask a question,is nginx as image server is better than apache?If you do test,plase tell me! 2008/8/15 Igor Sysoev <is@rambler-co.ru> On Fri, Aug 15, 2008 at 01:46:07PM +0800, walt wrote: > So do I,but why apache's is smaller than nginx,this is ture. Until you say what is 457 and 699 exactly the discussion will be helpless. Try tcpdump as it was suggested. Try debug log. > > > > On Fri, Aug 15, 2008 at 09:56:06AM +0800, walt wrote: > > > > What the size of the image itself ? > > http://sysoev.ru/en/ > > > > -- Igor Sysoev http://sysoev.ru/en/
on 15.08.2008 21:33
what on earth does better mean? thats an awfully general question.