Monday, 12 October 2015

IIS7 and Apache on the same server

Ok so you want both IIS and Apache on the same machine. The problem is that IIS is rather greedy and takes up any IP addresses that you have on the machine so that Apache can not have a lock on any IP address, even if you specify IP's in the IIS management console. If you type in netstat -an and you see 0.0.0.0:80 it means that IIS has got hole of everything.
1) Added or make sure your machine has two ip’s
2) Open a command prompt
3) Type netsh
4) Type http
5) Type sho iplisten.  It should be blank6) Type add iplisten ipaddress=192.168.0.90
You should get IP address successfully added7) Type sho iplisten again
It should sho 192.168.0.90 in the list8) Type exit to get out of netsh
9) Type type netstat -an.  See if you notice 192.168.0.90:80 in the list.  If you see 0.0.0.0:80, do an iisreset
10) Download and install Apache (actually I installed Xamp)
11) Do a default install,
12) Open httpd.conf and adjust the ip listen to 192.168.0.91:80
# Listen: Allows you to bind Apache to specific IP addresses and/or# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses (0.0.0.0)
#
#Listen 12.34.56.78:80
#Was 80
#Change to
Listen 192.168.0.91:80

12) Restart the Apache service.
13) Type netstat -an
14) You should see 192.168.0.90:80 and 192.168.0.91:80.  Open a browser and test both IP’s to see if IIS7 and Apache come up.
15) Reboot the server to see if it works after that.
16) Turn off Apache, browse IIS, turn of IIS, browse Apache. Test it every which way to see if it works.
I got this from http://iislogs.com/steveschofield/2007/07/07/iis7-post-44-iis7-and-apache-on-the-same-machine/ and I am repeating it here so I know where to find it in the future.

Why Dogs Never Die!

Dogs never die.

They don't know how to. They get tired, and very old, and their bones hurt. Of course they don't die.

If they did they would not want to always go for a walk, even long after their old bones say "No, nor not a good idea. Let’s not go for a walk." Nope, dogs always want to go for a walk. They might take one step before their aging tendons collapse them into a heap on the floor, but that’s what dogs are. They walk.

It’s not that they dislike your company. On the contrary, a walk with you is all there is. Their boss, and the cacophonous symphony of odour that the world is. Cat poop, another dog's mark, a rotting chicken bone (exultation), and you. That’s what makes their world perfect, and in a perfect world death has no place.

However, dogs get very very sleepy. That’s the thing, you see. They don't teach you that at the fancy university where they explain about quarks, gluttons, and Keynesian economics. They know so much they forget that dogs never die. It’s a shame, really. Dogs have so much to offer and people just talk a lot.

When you think your dog has died, it has just fallen asleep in your heart. And by the way, it is wagging its tail madly, you see, and that’s why your chest hurts so much and you cry all the time.

Who would not cry with a happy dog wagging its tail in their chest?

Ouch! Wap wap wap wap wap, that hurts. But they only wag when they wake up. That’s when they say "Thanks Boss! Thanks for a warm place to sleep and always next to your heart, the best place.”
When they first fall asleep, they wake up all the time, and that’s why, of course, you cry all the time. Wap, wap, wap. After a while they sleep more (remember, a dog while is not a human while. You take your dog for walk; it’s a day full of adventure in an hour. Then you come home and its a week, well one of your days, but a week, really, before the dog gets another walk. No WONDER they love walks.)

Anyway, like I was saying they fall asleep In your heart, and when they wake up, they wag their tall. After a few dog years, they sleep for longer naps, and you would too.

They were a GOOD DOG all their life, and you both know lt. It gets tiring being a good dog all the time, particularly when you get old and your bones hurt and you fall on your face and don't want to go outside to pee when it is raining but do anyway, because you are a good dog.

So understand, after they have been sleeping in your heart, they will sleep longer and longer. But don't get fooled. They are not "dead." There's no such thing, really. They are sleeping in your heart, and they will wake up usually when you're not expecting it. Is just who they are.

I feel sorry for people who don't have dogs sleeping in their heart. You've missed so much. Excuse me I have to go cry now.

I don't know where or when I found it but it is so good that I had to repeat it.