Search code examples
javafitnesse

FitNesse throws FileNotFoundException, even with available port


I downloaded the FitNesse standalone jar (Release 20150424) and tried to install it with the following command:

java -jar fitnesse-standalone.jar -v -p 8081

However I keep getting an exception. I am running the command from C:\Program Files\Fitnesse (the directory where fitnesse-standalone.jar is located).

I have java 7 JRE installed:

c:\Program Files\Fitnesse>java -version

java version "1.7.0_51"Java(TM) SE Runtime Environment (build 1.7.0_51-b13) Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

But each time I run the command, I get the same exception:

c:\Program Files\Fitnesse>java -jar fitnesse-standalone.jar -p 8081
May 31, 2015 1:00:37 AM fitnesse.ConfigurationParameter loadProperties
INFO: No configuration file found (C:\Program Files\Fitnesse\plugins.properties)

Bootstrapping FitNesse, the fully integrated standalone wiki and acceptance testing framework.
root page: fitnesse.wiki.fs.FileSystemPage at .\FitNesseRoot#latest
logger: none
authenticator: fitnesse.authentication.PromiscuousAuthenticator
page factory: fitnesse.html.template.PageFactory
page theme: bootstrap
Starting FitNesse on port: 8081
java.io.FileNotFoundException: .\FitNesseRoot\updateList (The system cannot find the path specified)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(Unknown Source)
    at java.io.FileOutputStream.<init>(Unknown Source)
    at fitnesse.updates.FileUpdate.copyResource(FileUpdate.java:42)
    at fitnesse.updates.FileUpdate.doUpdate(FileUpdate.java:28)
    at fitnesse.updates.UpdaterImplementation.getUpdateFilesFromJarFile(UpdaterImplementation.java:74)
    at fitnesse.updates.UpdaterImplementation.createUpdateAndDoNotCopyOverLists(UpdaterImplementation.java:65)
    at fitnesse.updates.UpdaterImplementation.<init>(UpdaterImplementation.java:22)
    at fitnesseMain.FitNesseMain.update(FitNesseMain.java:80)
    at fitnesseMain.FitNesseMain.launchFitNesse(FitNesseMain.java:69)
    at fitnesseMain.FitNesseMain.launchFitNesse(FitNesseMain.java:54)
    at fitnesseMain.FitNesseMain.main(FitNesseMain.java:34)

I know that this is essentially the same question as was asked here, but the solution from that question is not working in my case. I am running the command from the directory where the .jar file is located. I have also checked netstat to see if any web servers are already running and there is nothing using port 80, 8080, or 8081.

I am running on 64 bit version of Windows 7.

Why am I getting this exception?


Solution

  • I believe your running into problems because the installation is below c:\Program Files. I do not think by default you are allowed to create files there, you need to run as administrator.

    Can you try:

    • move the jar to a different location (for instance C:\FitNesse\), and start from there
    • or starting from command prompt running as administrator