Following a windows update for windows 7, my localhost setup no longer works. I've uninstalled and reinstalled both php and apache. Different versions of each. Same result.
Things go fine until I add these lines to httpd.conf
# For PHP 5 do something like this:
LoadModule php5_module "c:/php/php5apache2.dll"
AddType application/x-httpd-php .php
# configure the path to php.ini
PHPIniDir "C:/php"
Then apache hangs and cannot be started. An attempt results in "operation failed!".
However, when I remove those lines above, apache works again.
What gives?
I've tried with php 5.3 and apache 2.2.14
and with php 5.3.1 and apache 2.0.63
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
Maybe IIS was reset to port 80? IIS competes with Apache and often when Apache refuses to start without any explanation it's because IIS is already running on port 80.
In XP Set IIS port number this way...
Start --> Settings --> Control Panel --> Administrative Tools --> Computer Management --> Services & Applications --> IIS --> Web Sites --> (right click on) Default Web Site --> Properties --> Web Site (tab, is default) --> TCP Port
As far as accessing it in Windows 7, no clue! After M$ messed up with Vista and made 7 nothing more then Vista++ I decided to go Linux and will be doing so very soon.
I tried apache on a non-standard port (81). It works fine, until I add in the lines in my first post to get php working with apache. Then it hangs. Error log reveals the same as before.
(OS 5)Access is denied. : Failed to open the Apache2 Service
I google'd the crap out of that earlier and couldn't find anything that applied to or would help my situation.
I would do a system restore on my computer, but the latest update is [Critical] so I suppose I'd have to install it eventually and that would be annoying.
Looks like I will be trying out a switch to ubuntu again. Maybe I could stick to it this time.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
IIS has two services (at least in XP) that you could disable and then try to start Apache again on port 80; they are 'IIS Admin' and 'World Wide Web Publishing'.
Why did you switch back from Ubuntu to Windows? I'm trying to learn as much as I can about Ubuntu before I finally switch though with emulators the screen is always stuck at 800x600 which makes it a pain to do anything with.
I switched back because windows was my comfort zone. And as a software developer, the comfort zone aided the speed of production. This time I'm just going to hit the learning curve hard. Before I tried to do everything from command line. This time I'm going to use the desktop environment and ease my way in.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
The console isn't friendly to production environments, a program has to have a GUI to minimize time interacting and increase time producing to be truly useful. Advanced Find & Replace is much faster then grep in the console not only by my interactions with it's GUI but also how fast it executes, I don't know why though. Did you find many Linux compliments to Windows apps you use for production?
Did you disable the two services in Windows / get Apache running?
There aren't any services by those names. I also couldn't find any services mentioning IIS. There is 'WinHTTP Web Proxy Auto-Discovery Service', which is the closest thing I could find to a mention of HTTP or a web server. This however, is already disabled.
I used Eclipse for my PHP development. It worked fine but was rather bloated.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
I think IIS uses inetinfo.exe, see if it's listed in the Windows Task Manager. Have you tried starting/stopping IIS manually or changing it's port number? I don't think it's included in the Home version of XP so it may or may not be included with certain "flavors" of 7, not sure.
Try looking in msconfig by hiding non-Microsoft services, you may be able to pick something out that way too.
I had the RC of Windows 7 working but after updating VirtualBox it corrupted half the OS's I had, hooray for not testing software before releasing it!
I decided to "netstat -an" from the prompt. Nothing is on port 80 (or 81, since that's what my webserver is set to now). So the port is not the problem.
I then did a search for "IIS" on my PC and it turned up nothing. I don't recall ever having IIS, though it may have been on previous versions of windows and I did not notice it.
Task manager services does not reveal "inetinfo", and the only thing that mentions http or webserver again is the http proxy auto-discovery service, which is disabled.
It's weird though. Apache *works great!* until I decide to add in the php module. hmm
I would mention i'm running amdx64, but it worked fine up till this update.
Oh well, I'm backing up to external hdd now and I have (k)ubuntu burned to cd already. I'm kind of excited about the switchover. However, I wish I could solve this problem for anyone else who may experience the same thing.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
I always keep a copy of a directory when I highly customize something. As far as Apache is concerned I simply use XAMPP and keep copies of php.ini and of httpd.conf.
I presume you've tried reinstalling PHP from scratch? I'll very likely start moving away from XAMPP when I finally move to Ubuntu.
I've uninstalled php and apache several times. Even using different versions of each (of course loading the correct apache module for php each time).
I keep getting that (OS 5)... apache error.
Redid my httpd.conf and php.ini configurations, but again the error doesn't surface until the php module is loaded into the apache http.conf file.
I've made sure php was in my $PATH environment variable, and copy needed dlls to all sorts of directories to make sure they are available. I've checked paths in httpd.conf lots of times and everything is correct as far as I can see.
It's just mind boggling how an update can break something that's working.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
Here is a shot in the dark; run as admin? Did you change anything with Windows such as starting to use a different user? You could try system restore or when windows boots pres F8 and choose "last good known configuration" or whatever. Maybe try smacking the computer case? When searching on search engines are you using quotes? I'm searching using...
I am right now strugling with the same issues you posted about a couple of weeks ago so I was wondering whether you found the solution. I'd greatly appreciate an answer. c u.
bibiki, maybe start a new thread and post some useful information as it's unlikely any other members here are living with you and can walk up to your computer.