Saturday, October 17, 2009

FIXED: Windows could not start the Subversion Apache on Local Computer

The Error:

Windows could not start the CollabNet Subversion Apache on Local
Computer. For more information, review the System Event Log. If this is
a non-Microsoft service, contact the service vendor, and refer to
service-specific error code 1.



The Fix:
Open the file C:\Program Files\CollabNet\Subversion Server\httpd\conf in notepad. If you installed to a different directory or you're not installing Apache via/ CollabNet navigate to [Root of Apache Install]\httpd\conf and open in Notepad.

find the following lines near the top of the file.

#
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the
# 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
Listen 80


Change the red line to a port number you're not using. If you don't know one, pick an oddball and change until it works.
#Listen 12.34.56.78:80 (this is a comment, leave it alone)
Listen 31337

The Why:
I ran into this error while installing the Apache 2.2 server on my local Windows Vista Machine during the CollabNet Subversion install process. The error reared its ugly head when I tried to actually run the Apache service that was installed. The problem, which I'll freely admit, is I've installed so many software applications for Windows I am prone to accept the default install settings and fix things later if need be. Obviously, when you're trying to port the Apache server to Windows a little more care may be needed than when you're installing a simple Windows application. This little issue popped up because I accepted the default value of Port 80 to use with the Apache server. Oops. Needless to say, as an Asp.Net developer I already have that port in use.

The Event Logs provided the real information I needed to solve the issue.

Error in System Log: 
The CollabNet Subversion Apache service terminated with service-specific error 1 (0x1).

Information in System Log: 
The CollabNet Subversion Apache service entered the stopped state.

Error in the Application Log:
The Apache service named  reported the following error:
>>> (OS 10013)An attempt was made to access a socket in a way forbidden by its access permissions.  : make_sock: could not bind to address 0.0.0.0:80

Eureka! Yes, that would cause a problem. It's times like these when I'd like to perform some aerodynamics testing on my laptop...
  .

5 comments:

AVK said...

Thank you so much!

Dave said...

Glad I could help AVK! Drove me crazy :)

onkar sutar said...

I changed port but still get same error, but when i install subversion server on other drive i works

Amani Phoenix said...

Nice post

Miah Charley said...

Very well written