Jenkins permission problem.

3,741 views
Skip to first unread message

Brian Jakovich

unread,
Aug 20, 2011, 12:59:36 PM8/20/11
to jenkins...@googlegroups.com
I seem to be having a permissions problem with Jenkins.


## Background
I am running Jenkins ontop of Tomcat 6.
I set my JENKINS_HOME using JAVA_OPTS="-DJENKINS_HOME=/var/lib/jenkins -Xmx512m -Djava.awt.headless=true"
Both my jenkins/ folder in my tomcat webapp directory and my jenkins_home folder are owned by the tomcat6 user and the tomcat6 group. They are both chmoded to 0644 aswell

## Error

hudson.util.IOException2: Failed to create a temporary file in /var/lib/jenkins
    at hudson.util.AtomicFileWriter.<init>(AtomicFileWriter.java:67)
    at hudson.util.AtomicFileWriter.<init>(AtomicFileWriter.java:54)
    at hudson.util.TextFile.write(TextFile.java:78)
    at jenkins.model.Jenkins.<init>(Jenkins.java:709)
    at hudson.model.Hudson.<init>(Hudson.java:81)
    at hudson.model.Hudson.<init>(Hudson.java:77)
    at hudson.WebAppMain$2.run(WebAppMain.java:217)
Caused by: java.io.IOException: Permission denied
    at java.io.UnixFileSystem.createFileExclusively(Native Method)
    at java.io.File.checkAndCreate(File.java:1716)
    at java.io.File.createTempFile(File.java:1804)
    at hudson.util.AtomicFileWriter.<init>(AtomicFileWriter.java:65)
    ... 6 more

Any help would be appreciated

Gareth Bowles

unread,
Aug 20, 2011, 1:18:32 PM8/20/11
to jenkins...@googlegroups.com, jenkins...@googlegroups.com
You need execute permission to cd into a subdirectory:


chmod -R the dirs to 755 and you should be OK. 
Reply all
Reply to author
Forward
0 new messages