java.lang.Error: java.io.IOException: No such file or directory

Jenkins JIRA | jbq | 10 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    When Hudson's home directory does not exist, this is the exception thrown: java.lang.Error: java.io.IOException: No such file or directory at hudson.WebAppMain.contextInitialized(WebAppMain.java:88) at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:511) at org.mortbay.jetty.servlet.Context.startContext(Context.java:135) at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1191) at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:481) at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:434) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:147) at org.mortbay.jetty.handler.ContextHandlerCollection.doStart(ContextHandlerCollection.java:120) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:147) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:117) at org.mortbay.jetty.Server.doStart(Server.java:210) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.xml.XmlConfiguration.main(XmlConfiguration.java:929) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.mortbay.start.Main.invokeMain(Main.java:183) at org.mortbay.start.Main.start(Main.java:497) at org.mortbay.start.Main.main(Main.java:115) Caused by: java.io.IOException: No such file or directory at java.io.UnixFileSystem.createFileExclusively(Native Method) at java.io.File.checkAndCreate(File.java:1345) at java.io.File.createTempFile(File.java:1434) at hudson.util.AtomicFileWriter.<init>(AtomicFileWriter.java:27) at hudson.util.TextFile.write(TextFile.java:50) at hudson.TcpSlaveAgentListener.<init>(TcpSlaveAgentListener.java:75) at hudson.model.Hudson.<init>(Hudson.java:197) at hudson.WebAppMain.contextInitialized(WebAppMain.java:86) ... 22 more The attached patch fixes that problem by properly checking that the directory exists, and reports a meaningful error.

    Jenkins JIRA | 10 years ago | jbq
    java.lang.Error: java.io.IOException: No such file or directory
  2. 0

    When Hudson's home directory does not exist, this is the exception thrown: java.lang.Error: java.io.IOException: No such file or directory at hudson.WebAppMain.contextInitialized(WebAppMain.java:88) at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:511) at org.mortbay.jetty.servlet.Context.startContext(Context.java:135) at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1191) at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:481) at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:434) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:147) at org.mortbay.jetty.handler.ContextHandlerCollection.doStart(ContextHandlerCollection.java:120) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:147) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:117) at org.mortbay.jetty.Server.doStart(Server.java:210) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40) at org.mortbay.xml.XmlConfiguration.main(XmlConfiguration.java:929) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.mortbay.start.Main.invokeMain(Main.java:183) at org.mortbay.start.Main.start(Main.java:497) at org.mortbay.start.Main.main(Main.java:115) Caused by: java.io.IOException: No such file or directory at java.io.UnixFileSystem.createFileExclusively(Native Method) at java.io.File.checkAndCreate(File.java:1345) at java.io.File.createTempFile(File.java:1434) at hudson.util.AtomicFileWriter.<init>(AtomicFileWriter.java:27) at hudson.util.TextFile.write(TextFile.java:50) at hudson.TcpSlaveAgentListener.<init>(TcpSlaveAgentListener.java:75) at hudson.model.Hudson.<init>(Hudson.java:197) at hudson.WebAppMain.contextInitialized(WebAppMain.java:86) ... 22 more The attached patch fixes that problem by properly checking that the directory exists, and reports a meaningful error.

    Jenkins JIRA | 10 years ago | jbq
    java.lang.Error: java.io.IOException: No such file or directory

    Root Cause Analysis

    1. java.lang.Error

      java.io.IOException: No such file or directory

      at hudson.WebAppMain.contextInitialized()
    2. Hudson
      WebAppMain.contextInitialized
      1. hudson.WebAppMain.contextInitialized(WebAppMain.java:88)
      1 frame