Lancia
07-22-2001, 05:24 PM
I've been hearing about how much bandwidth "mod_gzip" can save on UNIX servers. It sounds great, but I'm curious as to how it works. Can anyone fill me in?
Thanks! :)
Thanks! :)
![]() | View Full Version : How does mod_gzip work? Lancia 07-22-2001, 05:24 PM I've been hearing about how much bandwidth "mod_gzip" can save on UNIX servers. It sounds great, but I'm curious as to how it works. Can anyone fill me in? Thanks! :) JTY 07-22-2001, 06:06 PM mod_gzip is an Apache module that implements gzip compression on data transferred to browsers which support it. Eagle 07-22-2001, 06:10 PM Is it a pain to install? Does it increate the load of the CPU (due to compressing).... But what will it improve? Traffic? Speed? CPU load? What browser supports it? What if a browser DOESNT support it? sbrad 07-22-2001, 06:11 PM I'm glad someone asked this...so it saves bandwidth but doesn't cause problems like slow downloads? I assume what ever is compressed is de-compressed by the browser? How much bandwidth can this save on? (SH)Saeed 07-22-2001, 06:17 PM Well, does it take long for you to un-gzip 50 kb on your server? Nope, it takes like 0.01 sec or something. So if this 50kb turns into 30kb gzipped, a 56k modem user would save about 10 seconds, and a cable user would probably save 2-3 seconds. Not only will it save you download time, it will also save you bandwidth (which we all know costs a lot). Offcourse, it depends on what kind of site you have, the compression works specially good with Text/HTML (i.e. message boards) and not image galleries where the images are already as compressed as possible. davidb 07-22-2001, 06:18 PM I myself had some problems with it. But generally what I hear is that it can save you a lot of bandwidth depending on what is mainly being transferd. For example I dont think you can compress images any more, so if your site is mainly that it wont do all that much. But I also heard its not too hard on the cpu. Eagle 07-22-2001, 06:21 PM What browser supports it? What if a browser DOESNT support it? Also, is it recommended to do this for say... A RaQ server, not a RaQ in particular, but a server that hosts a lot of shared accounts... Furton 07-22-2001, 06:30 PM How hard is it too install this mod on Apache? (SH)Saeed 07-22-2001, 06:31 PM Originally posted by Eagle What browser supports it? What if a browser DOESNT support it? Also, is it recommended to do this for say... A RaQ server, not a RaQ in particular, but a server that hosts a lot of shared accounts... Here is the official mod_gzip FAQ page where you can find answer to most of your questions: http://www.remotecommunications.com/apache/mod_gzip/mod_gzip_faq.htm I would install mod_gzip on my servers where I had tons of users since it does not really do any harm. If the browser is compatible, it will gzip the files, if not, it won't! I think it's a really good thing to have installed and helps you and your users to keep the bandwidth usage lower. It might even make your connection seem faster ;) Eagle 07-22-2001, 06:34 PM Is it hard to install on: - Apache - RaQ4? Also, are there any "NO!'s" for installing this? (SH)Saeed 07-22-2001, 06:35 PM Originally posted by Furton How hard is it too install this mod on Apache? You simply copy the module file to your apache module directory, add it to your httpd.conf file and restart aoache, just like any other modules. Go to the FAQ link I posted above for more information. Eagle 07-22-2001, 06:37 PM Originally posted by Eagle are there any "NO!'s" for installing this? What about this? I will be mainly using this for killer machines and RaQ servers (virtual accounts) Lancia 07-22-2001, 06:37 PM That is a great FAQ, zolbian, thank you! :) (SH)Saeed 07-22-2001, 06:39 PM Originally posted by Eagle Is it hard to install on: - Apache - RaQ4? Also, are there any "NO!'s" for installing this? RaQ4 uses Apache, so there shouldn't be any problems. I believe this is a very usefull thing for a shared server. However, if you had a dedicated for your own picture gallery site, then it might not do much good. I would also be interested if anyone had any reasons why mod_gzip should not be installed on any server. From what I've seen, this is a very popular module. sbrad 07-22-2001, 06:39 PM Great link, Zolbian. Thanks! Tim Greer 07-22-2001, 06:40 PM mod_gzip is obviously told what files and type's of file contents to compress. Also, compression on files is better than the difference between 50 and 30 KB. Text files compress very well, as do CGI's, HTML and PHP files are usually compressed between 40 to 70 or 80%. Remember that bandwidth and time take up resources too, such as disktime and CPU, and mod_gzip, by compressing the files, helps save these resources. There's no reason why anyone and everyone shouldn't be using it by default, if you ask me. As per another person's question, it wasn't difficult to install, but I've also done it mroe than a few times and have installed more Apache modules than I can recall. Also, if a user's browser doesn't support it, then mod_gzip never compresses it. It checks this before it compresses it. Also, you can do a neat little trick of precompressing these files by gzipping them and having both the gzip and regular versions, do a little comfiguration, so instead of compressing the files, it just reads if the user's browser supports gzip and sends them that file and saves a bit of time there. (SH)Saeed 07-22-2001, 06:42 PM Originally posted by sbrad Great link, Zolbian. Thanks! You're welcome ;) sbrad 07-22-2001, 06:42 PM Also, you can do a neat little trick of precompressing these files by gzipping them and having both the gzip and regular versions, do a little comfiguration, so instead of compressing the files, it just reads if the user's browser supports gzip and sends them that file and saves a bit of time there. Hey, cool. I have some pretty large html files on a site, and that might come in handy. Is that pretty well documented, or are we going to have to make you start another thread on it?:D Eagle 07-22-2001, 06:52 PM HOLY $][iT!!! GUYS!!! INSTALL THIS!!! Man this improves speed! SnoTurtle 07-22-2001, 06:58 PM My index page on my forum went from 72k in size, down to 8k, most threads also droped from 60k avg down to 5k + images. Well worth the install, should save me a boatload of money on bandwidth, and keep my visitors on the site longer, fast site = happy customers. Now if i could just get my server online... hmm :) Eagle 07-22-2001, 07:01 PM Originally posted by SnoTurtle fast site = happy customers. Installing this on all my servers now :) Zolbian DA MAN! :D sbrad 07-22-2001, 07:08 PM I just installed it on my Raq4r, but when I go to http://www.my-site.com/mod_gzip_command_version I get a stinkin' 404. How do I find out if it's working properly or not? (SH)Saeed 07-22-2001, 07:08 PM Hehe, I'm glad I could help. :D Eagle 07-22-2001, 07:10 PM Originally posted by sbrad I just installed it on my Raq4r, but when I go to http://www.my-site.com/mod_gzip_command_version I get a stinkin' 404. How do I find out if it's working properly or not? Hmm contact me on herps@ewsnl.com I'm willing to take a look at it I got it to work on our RaQ's.... sbrad 07-22-2001, 08:45 PM Well, it's working now, and it's already saved me 200GB! Nah... Anyway, a big thanks to Leslie (Eagle) for fixing it for me. This guy is a big fat huge lifesaver, and really smart to boot. Not many people would have gone out of their way to help a competitor like that. As a side note, in case no one's ever thought about it...the name Leslie can be used for a dude, too. I never woulda thunk it.:eek: Eagle 07-22-2001, 08:47 PM Originally posted by sbrad As a side note, in case no one's ever thought about it...the name Leslie can be used for a dude, too. I never woulda thunk it.:eek: LoL And thank you for the credits :D :blush: Lancia 07-22-2001, 09:07 PM Installing this on all my servers now Zolbian DA MAN! Hey, what about the guy who started this thread in the first place? ;) :stickout Eagle 07-22-2001, 09:09 PM Lanchia DA MAN! :stickout :D :stickout sbrad 07-22-2001, 09:09 PM Hey, what about the guy who started this thread in the first place? Lancia da other man! DaveC# 07-23-2001, 08:24 AM I would also be interested if anyone had any reasons why mod_gzip should not be installed on any server. From what I've seen, this is a very popular module. There are a couple of issues 1) Non HTTP1.1 compliant proxies. If your users are connecting to your site via a non http 1.1 compliant proxy on their ISP they will be left with old versions of your pages 2) On servers that are overloaded with perl cycles on the cpu MOD_GZIP can create lots of little .wrk files in your TMP dir and apache will fall over I would also use zlib if you are using php for gzip compression |