Solved: An attempt was made to access a socket in a way forbidden by its access permissions windows 10. OS10013, AH00072

Summary Solution

Shut down IIS

net stop was /y

which may unblock port 80.
Alternatively you can have your version of Apache listen on a different port – such as “8080”.


You are trying to start apache and getting an error

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

OS 10013



  • Check if port 80 is being used by any other process – “netstat -o”
  • Shut down IIS from the commadn line: “net stop was /y”

Alternative solution:

  • Edit the /Apache24/conf/httpd.conf file and change the port from 80 to 8080

Changing the port to another one



Posted in Apache, Error Messages, Windows 10 | Tagged , , , | Leave a comment

Setting up Apache 2.4 in Windows 10


The aim is to setup a simple webserver under windows 10, and not get lost in the Apache documentation as a first timer – so I’ll document what happens here.

Summary steps

  • Download the 64-bit version from Apache Haus.
  • Extract it to a directory (e.g. c:\dev\) – which gives c:\dev\Apache24.
  • Edit the c:\dev\Apache24\conf\httpd.conf file to reflect the correct path (line 39).
  • Run httpd.exe from the command prompt.


Use these if the pages/links change, so that you can re-create the steps.


When you find the download link on the Apache homepage there is a link to “Files for Microsoft Windows” – which will get us close to where we want to get to. However – even this directs us to one of five options, and from there you are at a home page and feels like you are starting all over again.

I picked a random one (Apache Haus) and downloaded the 64-bit version.


The file is a zip file in your downloads folder.

The default would be to extract the files to a c:\Apache24 folder – and this is what the documentation expects.

The default expects paths of c:\Apache24 where I have paths of c:\dev\Apache24 after the zip file is extracted to c:\dev.


The primary file to use when configuring for the first launch is the c:\dev\Apache24\conf\httpd.conf file.

Edit this and change line 38 to use the new folder location:

Define SRVROOT "/dev/Apache24"
ServerRoot "${SRVROOT}"

Save the changes.


Open up a command prompt and navigate to the c:\dev\Apache24\bin directory

Run httpd.exe:


If there are no errors/warnings then the cursor sits on the next file.


Just open a browser and type in


You should see content if it works.







Posted in Apache | Tagged , , , , | Leave a comment

ServerRoot must be a valid directory

Error Message

Syntax error on line 39 of c:……. .conf/httpd.conf: ServerRoot must be a valid directory.

ServerRoot must be a valid directory

What I am trying to do

I am trying to run a new install of Apache under Windows 10.


Edit the \Apache24\conf\httpd.conf file.
At line 39 and ensure that the path to the folder where your installation is. (i.e. where you unzipped the downloaded file).


Before – when we had an error

In my case, I extracted the downloaded file to the c:\dev directory so the change needed is highlighted below.

After the edit

How to test

Now try to run Apache again – by running the httpd.exe command from the command prompt. If you get a cursor sitting on the next line with no error, then you are okay, and can test it by opening a browser and going to: http://localhost


  • The default installation of Apache (2.4 in my example) expects that it is installed in the c:\Apache24 directory.
  • If you download the file and don’t extract it from the root of the c:\ drive then you will see this error.
  • The SRVROOT shows “/Apache24” as the folder – whereas on Windows you would normally expect to see “c:\Apache24” for a folder.

Request to visitors

Click “Like” if this helped and I’ll post more like this that may help you, or others in the future.
Feedback welcomed on style/format etc.

Posted in Error Messages, Syntax error | Tagged , , , , , | Leave a comment

TDD by Beck – Chapter 14 on GitHub

The code for Chapter 14 of TDD by Beck is now on GitHub


CH14: Change

Significant techniques are introduced here...though I had issues with Java 6 indicating that some methods (assertEquals(Object{}, Object[]) is deprecated.

* Added a Bank parameter
* Saw that the number 2 was duplicated in code and tests - so refactored it out from it as part of the rate
* A test for the ArrayEquals showed an assumption that did not work - so drove the direction of the solution....which was a separate class as a comparator (Pari)
* Wrote that (without tests!!!) as it was part of a refactorying.
* When there was an error - it forced a new test testIdentityRate() - which isolated the problem.
Posted in TDD | Leave a comment

TDD by Beck – Chapter 13 code on GitHub

The code for Chapter 13 of Beck has been added to GitHub with the following commit message:

Ch 13: Make It

There was data duplication initially, because we had a test that was passing because of a hardcoded response in the reduce method of the Bank class. It was returning 10 – so when a test was written for the Bank reduce, and written in a way that it had a different value expected, it caused us to be forced to correct the situation.

We started to work forward to find the implementation – breaking tests as we went, and refactoring by introducing the Sum class, until it passed at some level.

It passed – though the code had some casts that were pretty unappealing – and ths seemed to call out for polymorphism as the solution. As a result, the method “reduce (String paramName)” was introduced into the Money class, so that it could be put into the Interface class Expression. This lead to a cleaner implementation of the Bank’s reduce method.

Posted in TDD, Uncategorized | Leave a comment

TDD by Beck – CH 12 code on GitHub

The code for Chapter 12 of TDD by Beck is now on GitHub.

CH 12 - Addition, Finally

In this chapter, we take a big test - which is addition cross-currencies, and reduce it to a simpler case of addition in a single currency.

Wiht that - we have a metaphor - Expressions - which are currency independent - think of them like a wallet.  Operations result in expressions - and if we think of the multiple ways that a currency combination in a wallet can have the same value - we introduce a "bank" as a way of converting to a single currency value at the end.

This means - Expression will operation on Money.
Then create a bank.
Have the bank reduce the value to USD (for example)
Posted in TDD, Uncategorized | Leave a comment

TDD by Beck – Chapter 11 code on Git

The code for Chapter 11 (“The root of all Evil”) of TDD by Beck is now available on GitHub.

The commit notes on Git are as follows:


The intent is to remove the Dollar/Franc duplication.
Removed Dollar - and checked for references to Franc.
There were some - though the tests were sufficiently covered elsewhere that it was not worth keeping the testDifferentClassEquality.
At the same time the "testFrancMultiplication" - can be removed - though I would advocate keeping it, personally.

Beck says that no system confidence is lost if you remove it - and as the system is relatively well understood, that is okay, in more complex cases, this may not always be the case.
 Redundant code is important to remove at the same time - keeps things clean and limited to what you need, and what you want to spend time reviewing.
Posted in TDD, Uncategorized | Leave a comment