I installed jenkins issue with downloading the plugins

I getting below error while running war file using command prompt.
Also: java.nio.file.AccessDeniedException: C:\ProgramData\Jenkins.jenkins\atomic2381561023445587992tmp → C:\ProgramData\Jenkins.jenkins\config.xml
at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:89)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
at java.base/sun.nio.fs.WindowsFileCopy.move(WindowsFileCopy.java:309)
at java.base/sun.nio.fs.WindowsFileSystemProvider.move(WindowsFileSystemProvider.java:292)
at java.base/java.nio.file.Files.move(Files.java:1422)
at hudson.util.AtomicFileWriter.commit(AtomicFileWriter.java:211)
java.nio.file.AccessDeniedException: C:\ProgramData\Jenkins.jenkins\config.xml
at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:89)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:108)
at java.base/sun.nio.fs.WindowsFileCopy.move(WindowsFileCopy.java:384)
at java.base/sun.nio.fs.WindowsFileSystemProvider.move(WindowsFileSystemProvider.java:292)
at java.base/java.nio.file.Files.move(Files.java:1422)
at hudson.util.AtomicFileWriter.commit(AtomicFileWriter.java:226)
at hudson.XmlFile.write(XmlFile.java:221)
at jenkins.model.Jenkins.save(Jenkins.java:3625)
at jenkins.model.Jenkins.(Jenkins.java:1013)
at hudson.model.Hudson.(Hudson.java:86)
at hudson.model.Hudson.(Hudson.java:82)
at hudson.WebAppMain$3.run(WebAppMain.java:248)
Caused: hudson.util.HudsonFailedToLoad
at hudson.WebAppMain$3.run(WebAppMain.java:276)

My company is using Zscaler security and zenkins not accepting zscaler certificate. Can ant one help me with this

Hello and welcome to this community, @vamsi. :wave:

To me, the error message you’re seeing, java.nio.file.AccessDeniedException, seems to indicate that Jenkins does not have the necessary permissions to access or modify the config.xml file located at C:\ProgramData\Jenkins.jenkins.

This could be due to a few reasons:

  1. The user running the Jenkins process does not have the necessary permissions to access or modify the file.
  2. The file is currently in use by another process and cannot be accessed by Jenkins.
  3. The file or its parent directory has been marked as read-only.

I’m not very good when it comes to running anything under Windows, so I could be totally wrong. :person_shrugging:

Regarding the Zscaler certificate issue, it looks like Jenkins does not trust the Zscaler certificate.
You could maybe try importing the Zscaler certificate into the Java keystore used by Jenkins.

Here’s a general outline of the steps you would need to follow:

  1. Export the Zscaler certificate to a file. This can usually be done through your browser’s certificate viewer. I’m not sure this would work for Zscaler, but give it a try. :thinking:
  2. Import the certificate into the Java keystore used by Jenkins. You can do this using the keytool command that comes with Java. Here’s an example:
keytool -import -alias zscaler -keystore /path/to/your/keystore -file zscaler_certificate.cer

In this command, replace /path/to/your/keystore with the path to the Java keystore used by Jenkins, and zscaler_certificate.cer with the path to the Zscaler certificate file you exported.

Please note that you might need to restart Jenkins for the changes to take effect.

As far as I remember, Zscaler is a commercial product, so if this proposal does not work, feel free to reach Zscaler support. :person_shrugging: