Closed pmarijan closed 8 years ago
The problem here is due to permissions. Payara makes a backup of the domain.xml
so that you always have a copy to restore to if something goes wrong. The default temporary directory is /tmp
, so if it doesn't have write permissions there, or on the original domain.xml
, you might see an error like this.
You can change the temp directory by setting -Djava.io.tmpdir=/my/new/path
which may help. If not, please upload the log file and I'll take a closer look.
Could I also ask exactly what the symptoms were? You say you couldn't make it work, but how did it fail? Did Payara Micro completely fail to start, or did it start with the default domain.xml?
Payara Micro started but with error I posted above and it didn't fail completely...I hadn't checked if it started with default domain.xml.
Solution you suggested worked, I just added System.setProperty("java.io.tmpdir", "/my/folder");
at the beginning of my application.
Excellent, thanks!
i have same problem and i will try to change temp folder.
Somehow I can't make it work to set alternate domain.xml programaticaly. Is it possible to get the working example?
I allways get this error
Could not rename /some_path/microdomain.xml to /tmp/gfembed4607422639911715601tmp/config/domain.xml.bak