Windows Web Hosting, Web Technologies, etc
Archive for October 2, 2008
Quickly Configure or Disable ETags in IIS7 or IIS6
Oct 2nd
With the move of my blog to a new server, so comes a few new tweaks. Fortunately, I’m on an Windows 2008 Hosting account and I have had delegation enabled so I can remotely manage all the features in my IIS7 website with the IIS7 manager (but more on that in a later post).
Earlier this year I fired up firebug and the Y!Slow application from Yahoo to really dial in my website’s performance. One of these changes was to disable ETags. On the IIS6 server I was on I found an ISAPI filter that I could load on the site and call it a day. Turns out there’s an even easier way to disable ETags. Before we go disabling ETags though it’s probably a good idea to learn just what they are.
Just what are ETags?
An Entity Tag is a validator which can be used instead of, or in addition to, the Last-Modified header. An entity tag is a quoted string which can be used to identify different versions of a particular resource.
By sending an entity tag you promise the recipient that you will not send the same ETag for the same resource again unless the content is ‘equal’ to what you are sending now (see below for what equality means).
The above was taken from the mod_perl documentation on Issuing Correct HTTP Headers. So basically an ETag is a unique identifier your webserver sends to a web browser and will only change that ETag if the content it’s assigned to is changed.
Here’s how it works in IIS
- Client request static resource (gif for example) for the first time. IIS serve it to client with response code 200. Resource stored in IE cache.
- Client make additional request for the same resource. IIS responds with code 304. Client use resource from IE cache.
- In some point in time, IIS service restarts.
- All subsequent requests from client for the same resource will end up with code 200 and file being downloaded on the wire. Why? What is happening?
- Situation will return to normal when client will clean IE cache.
The above taken from LangleyBen Leon’s blog. So any time the service restarts (and I need to check if this is affected by application pool restarts but I suspect it may be) the ETag is actually reset regardless to whether the content changed or not.
What Yahoo actually recommends is you use the Last-Modified-Date or set an Expires header.
How to disable ETags easily in IIS6 and IIS7
I’ll leave it up to you to decide if you want to disable your ETags or not and up to you to do the necessary research. I have decided to disable ETags and here’s how I’m going to do it. I’m going to add a custom header to web server named ETag with a value of “” (nothing in there). So every item sent will have a blank ETag (and thus mission accomplished).
In IIS7 you do this as follows
First select HTTP Response Headers
Then add an HTTP Response Header as mentioned earlier called ETag with a value of “” (yes, that’s two double quotes):
Next browse your site with Firebug or some other tool and you’ll see the Etags are gone! No ISAPI’s, no use of a metabase editor, just a quick added header.
In IIS6 you would do this as follows:
From within the MMC you select the HTTP Headers tab
Select the Add button and enter a new HTTP Header
Enter Etag and “” and then click ok and close out the MMC saving your changes.
That’s all you need to do to disable your ETags.
Microsoft releases Hyper-V 2008 Server.
Oct 2nd
Microsoft released Hyper-V Server 2008 yesterday and it’s now available for FREE download. This is a bare-metal standalone hypervisor, meaning that you don’t install a host OS on the machine before installing this. You just install this and then create your VM’s and install the OS of choice into your VMs.
I think the best way to think of this is as Server Core but with only one role: Virtualization. Or think Hyper-V without the overhead of a full Host OS. Here’s a few cool facts:
The maximum number of guest instances is 192.
The maximum number of Logical processors supported is 24.
The maximum amount of Memory? I don’t know but I know it supports more than 32GB!
Licensing for Hyper-V Server is free however you’ll have to have a license for each guest instance of Windows you install. The screen cap below shows the different licensing options for Hyper-V:
(my advice: Go datacenter and save on licensing).
Barack Obama listens when Jess Coburns speaks er um tweets..
Oct 2nd
I started this post at the beginning of September and today saw something pretty amazing…
I was adding people to follow on Twitter today (I have yet to figure out what to twit about) and after a few adds and tweets I got this email today:
Finally, a Presidential Candidate that recognizes my brilliance!! Ahh, it’s nice to have followers
Now I just need to find out his gamertag on xbox live so we can play some COD4
.
In all seriousness though I am truly amazed with the way the Presidential candidates have embraced the Internet and are using it to spread their message and the fact that they are using social networking as one of these tools is even more amazing.
Back from the back burner.
As I mentioned earlier I had shelved this post because it wasn’t that interesting.. It’s cool but not really interesting. Anyway, I did start following Barack Obama on twitter because I was curious what the campaign would post. Before I continue, no I don’t really believe Barack is reading my tweets.. He should but he’s probably not.. but he’s probably is subscribed to my blog
. Anyway, Today they tweeted about an official “iPhone App.”!!.
The Barack Obama Phone App
Now this is clever and really shows how technology and the Internet is changing the world. Back in 1988 we had a student project to volunteer for the campaign of a candidate running for election. At that time I opted for Dukakis in his Presidential run. I had 3 jobs:
1. Hang door hangers on all the houses in my neighborhood (after sitting for days in my bedroom my younger sister went out and hung them all out for me).
2. Hold a sign at a rally for Dukakis at a local union office and wave as the Bus carrying Dukakis comes in. Turns out I got to shake his hand be on TV, so for a high school kid this was impressive.
3. I was handed about 20 pages of computer printouts (the crappy old green and white paper used in 9 pin dot matrix printers), a script to read and shown to a phone where I was to sit for hours and make phone calls.
From this experience I learned a few things:
1. Dukakis was a short man but had a solid handshake and made a point to make eye contact, even with some punk high school kid wearing his cool high school mascot jacket. I was impressed.
2. I’m not one for hanging door hangers but my sister will gladly do it for free!
3. People don’t like to be called during dinner time. If you call a stranger’s house about a candidate they don’t care for they will probably rip you a new one and scream vulgarities at you and finally many people will just say “Yeah, we’re voting for him” just to get you off the phone.
4. Politics was not for me.
The reason I mention this is that the Barack Obama campaign continues to impress me with their grasp of the Internet and how they are using it to reach voters. The Iphone app is just pure genius. Instead of setting up a phone pool and trying to get people to come in and make these calls to strangers (that are going to curse them or just say yes for the sake of getting someone off the phone) they are providing a phone app that will allow you to make these calls to your contacts AND provide information upfront on key topics that you’re most likely to get hit with when talking to your friends and contacts about Obama.
This is truly clever. You know I often think back to that first batman movie website. I believe it was the first movie to launch a website to promote their movie. I was amazed with the graphics, the layout, the animation but more importantly excited about what it meant to the entertainment industry and was cool new websites we’d see. So I’m equally excited to see not only what else Obama’s campaign will do with the Internet but how other candidates will continue to raise the bar.
If you wish to pick up the Barack Obama IPhone app you can get it here.
NOTE: I’m not Political. I don’t care who you’re voting for and whether I vote or who I vote for is none of your business. So don’t bother me with political crap.
And a WARNING: Never give the NRCC money as a joke to tease your buddy who thought it was cool he got an award for being such a good republican because you got the award too and you’re a democrat! They’ll never leave you alone and will send you tons of crap awards, pictures, statues, letters, invites, etc. You’d think they’d look at your voter’s registration but I guess not.