6

I'm trying to run sonarQube

Installing through cmd as Admin: InstallNTService.bat

StartSonar.bat

    --> Wrapper Started as Console 
   Launching a JVM...
    Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
   Copyright 1999-2006 Tanuki Software, Inc.  All Rights Reserved.

     2016.03.25 21:09:40 INFO  app[o.s.a.AppFileSystem] Cleaning or creating temp directory C:\sonarqube-5.4\temp

 WrapperSimpleApp: Encountered an error running main:java.lang.RuntimeException: Failed to reset file system
    java.lang.RuntimeException: Failed to reset file system
at org.sonar.process.monitor.Monitor.resetFileSystem(Monitor.java:125)
at org.sonar.process.monitor.Monitor.startProcesses(Monitor.java:105)
at org.sonar.process.monitor.Monitor.start(Monitor.java:99)
at org.sonar.application.App.start(App.java:51)
at org.sonar.application.App.main(App.java:110)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
at java.lang.Thread.run(Unknown Source)
  Caused by: java.nio.file.AccessDeniedException: C:\sonarqube-5.4\temp\jffi837955644087697080.tmp
at sun.nio.fs.WindowsException.translateToIOException(Unknown Source)
at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source)
at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source)
at java.nio.file.Files.delete(Unknown Source)
at org.sonar.process.FileUtils$CleanDirectoryFileVisitor.visitFile(FileUtils.java:151)
at org.sonar.process.FileUtils$CleanDirectoryFileVisitor.visitFile(FileUtils.java:135)
at java.nio.file.Files.walkFileTree(Unknown Source)
at org.sonar.process.FileUtils.cleanDirectoryImpl(FileUtils.java:123)
at org.sonar.process.FileUtils.cleanDirectory(FileUtils.java:60)
at org.sonar.application.AppFileSystem.createOrCleanDirectory(AppFileSystem.java:116)
at org.sonar.application.AppFileSystem.reset(AppFileSystem.java:73)
at org.sonar.process.monitor.Monitor.resetFileSystem(Monitor.java:122)
... 10 more
 <-- Wrapper Stopped

I' getting these errors:

  1. WrapperSimpleApp: Encountered an error running main:java.lang.RuntimeException: Failed to reset file system java.lang.RuntimeException: Failed to reset file system

  2. Caused by: java.nio.file.AccessDeniedException: C:\sonarqube-5.4\temp\jffi837955644087697080.tmp

Please Assist.

G. Ann - SonarSource Team
  • 22,346
  • 4
  • 40
  • 76
John Miller
  • 513
  • 2
  • 8
  • 23

5 Answers5

12

Kill the Java process and try deleting the temp folder contents again. Worked for me.

joelc
  • 2,687
  • 5
  • 40
  • 60
6

The user that is running SonarQube (look at the user details in the windows services screen) must have R/W rights on several sub-directories in C:\Sonarqube-6.X. We assigned R/W rights to the whole C:\Sonarqube-6.X directory tree. Before retrying you can delete the temp directory safely. It is also essential that you unblocked the SonarQube zip-file after download and before unzipping.

Jeroen Heier
  • 3,520
  • 15
  • 31
  • 32
0

I had the same issue, but was unable to delete the temp directory because it was locked. I restarted my computer and fired up sonarQube and it started without a problem. I'm guessing when I last closed my SonarQube session some resource was still holding onto the temp folder and wouldn't release but I couldn't find a sonarqube process to kill off in the task manager.

ninjasense
  • 13,756
  • 19
  • 75
  • 92
0

You can follow below steps...Its work form me.

1: Stop the running sonar cmd window.

2: open Task manager and kill "Java Process" then manually delete temp folder.

3: Run Again

Thanks Vinod

0

i aslo got the same problem use the command source ~/.bash_profile (2times) then go and execute sonarqn

  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Dec 20 '22 at 09:02