Starting SonarQube Error java.nio.file.FileSystemException

Hello , I was trying to launch SonarQube and it throwing this error as shown below .
Can somebody please help me out ?

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)
    openjdk version “11.0.6” 2020-01-14
    OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.6+10)
    OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.6+10, mixed mode)
    SonarQube 7.9.x LTS (July 2019)
    sonar-scanner-cli-4.4.0.2170-windows

  • what are you trying to achieve
    Installing in WIndows 10 for project

    E:\Projectku\ProjectTDW\web-api>sonar-scanner.bat -D"sonar.projectKey=Testing" -D"sonar.sources=." -D"sonar.host.url=http://localhost:9000" -D"sonar.login=006d8018b8ae46cc4fe262fd1aa4eba4de092ce0"
    INFO: Scanner configuration file: E:\Projectku\SonarQube\sonar-scanner-4.4.0.2170-windows\bin…\conf\sonar-scanner.properties
    INFO: Project root configuration file: NONE
    INFO: SonarScanner 4.4.0.2170
    INFO: Java 11.0.3 AdoptOpenJDK (64-bit)
    INFO: Windows 10 10.0 amd64
    INFO: User cache: C:\Users\User.sonar\cache
    INFO: Scanner configuration file: E:\Projectku\SonarQube\sonar-scanner-4.4.0.2170-windows\bin…\conf\sonar-scanner.properties
    INFO: Project root configuration file: NONE
    INFO: Analyzing on SonarQube server 7.9.4
    INFO: Default locale: “en_ID”, source code encoding: “windows-1252” (analysis is platform dependent)
    INFO: Load global settings
    INFO: Load global settings (done) | time=75ms
    INFO: Server id: BF41A1F2-AXO9tU5Av6OFuzhssCY0
    INFO: User cache: C:\Users\User.sonar\cache
    INFO: Load/download plugins
    INFO: Load plugins index
    INFO: Load plugins index (done) | time=53ms
    INFO: Load/download plugins (done) | time=115ms
    INFO: Process project properties
    INFO: Execute project builders
    INFO: Execute project builders (done) | time=4ms
    INFO: Project key: Testing
    INFO: Base dir: E:\Projectku\ProjectTDW\web-api
    INFO: Working dir: E:\Projectku\ProjectTDW\web-api.scannerwork
    INFO: Load project settings for component key: ‘Testing’
    INFO: Load project settings for component key: ‘Testing’ (done) | time=16ms
    INFO: Load quality profiles
    INFO: Load quality profiles (done) | time=60ms
    INFO: Load active rules
    INFO: Load active rules (done) | time=2039ms
    INFO: Indexing files…
    INFO: Project configuration:
    INFO: Load project repositories
    INFO: Load project repositories (done) | time=17ms
    INFO: ------------------------------------------------------------------------
    INFO: EXECUTION FAILURE
    INFO: ------------------------------------------------------------------------
    INFO: Total time: 5.909s
    INFO: Final Memory: 7M/37M
    INFO: ------------------------------------------------------------------------
    ERROR: Error during SonarScanner execution
    java.lang.IllegalStateException: Failed to index files
    at org.sonar.scanner.scan.filesystem.ProjectFileIndexer.indexFiles(ProjectFileIndexer.java:203)
    at org.sonar.scanner.scan.filesystem.ProjectFileIndexer.index(ProjectFileIndexer.java:159)
    at org.sonar.scanner.scan.filesystem.ProjectFileIndexer.indexModulesRecursively(ProjectFileIndexer.java:138)
    at org.sonar.scanner.scan.filesystem.ProjectFileIndexer.index(ProjectFileIndexer.java:105)
    at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:353)
    at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
    at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
    at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(GlobalContainer.java:141)
    at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
    at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
    at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:73)
    at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:67)
    at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.base/java.lang.reflect.Method.invoke(Unknown Source)
    at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
    at com.sun.proxy.$Proxy0.execute(Unknown Source)
    at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:189)
    at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:138)
    at org.sonarsource.scanner.cli.Main.execute(Main.java:112)
    at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
    at org.sonarsource.scanner.cli.Main.main(Main.java:61)
    Caused by: java.nio.file.FileSystemException: E:\Projectku\ProjectTDW\web-api\node_modules.bin\acorn: The file cannot be accessed by the system.

          at java.base/sun.nio.fs.WindowsException.translateToIOException(Unknown Source)
          at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
          at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)
          at java.base/sun.nio.fs.WindowsFileSystemProvider.isHidden(Unknown Source)
          at java.base/java.nio.file.Files.isHidden(Unknown Source)
          at org.sonar.scanner.scan.filesystem.ProjectFileIndexer$IndexFileVisitor.visitFile(ProjectFileIndexer.java:241)
          at org.sonar.scanner.scan.filesystem.ProjectFileIndexer$IndexFileVisitor.visitFile(ProjectFileIndexer.java:214)
          at java.base/java.nio.file.Files.walkFileTree(Unknown Source)
          at org.sonar.scanner.scan.filesystem.ProjectFileIndexer.indexDirectory(ProjectFileIndexer.java:210)
          at org.sonar.scanner.scan.filesystem.ProjectFileIndexer.indexFiles(ProjectFileIndexer.java:197)
          ... 23 more
    

    ERROR:
    ERROR: Re-run SonarScanner using the -X switch to enable full debug logging.

Hi Mikhael,

Welcome to the SonarSource Community!

The issue you are seeing indicates that the scanner cannot read your source files. This could be caused by a number of permission or system related issues.

I’ll suggest that you try your scan with the debug (-X) option to get more information. If the cause of the issue is not obvious based on the debug output, please post the debug-level log here so someone can assist you further.

Brian