views:

655

answers:

2

Hi,

I'm trying to unpack a Weblogic 10.3 domain on one of our production servers (SunOS 5.10), but get the following error:

 $ /opt/bea10/wlserver_10.3/common/bin/unpack.sh -template=/tmp/CM.jar -domain=/opt/bea10/user_projects/CM
 Error: failed to create the temporary script file

Assuming that this is a priviledge problem: where actually the unpack utility tries to create its temporary script files? The unpack script calls a Java class com.bea.plateng.domain.script.Unpacker, so reading the script itself does not reveal the location. I need to ask the sysadmin for the priviledges, so an exact directory location is needed.

Of course, the error message is so vague that this might also be some other issue. Any ideas?

BR,

Marko

P.S. Sorry for cross-posting. I tried this question also on Serverfault but got no replies. Perhaps programmers (like myself) do this kind of stuff anyway.

+1  A: 

Please try to execute your command using the -log=log_file and -log_priority=debug optional parameters (see http://download.oracle.com/docs/cd/E12840_01/common/docs103/pack/commands.html for the details) and update your question with the results.

EDIT (answering a comment from the OP): That's weird... My next suggestion would be to try to use the WLST equivalent of the unpack utility. Have a look at How to create a distributed WebLogic domain ? for the WLST script. The idea is still to get a trace for the real problem.

And if this doesn't work, then I'd just create a good old tar.gz of the domain (removing manually the log file) and contact the support to find out what happens exactly.

PS: It is possible that com.bea.plateng.domain.script.Unpacker uses the temporary directory returned by java.io.tmpdir which, on Solaris, is /var/tmp/. Check that you can write there. But this is just a bet.

Pascal Thivent
Hi Pascal, thanks for the reply.I added <code>-log=/tmp/pack.log -log_priority=debug</code> to the command. Unfortunately, nothing gets written to the specified log file. In fact, the log file does not even get created. Both the current directory and /tmp are writable, and I tried them both with no luck. Any further ideas?
MarkoU
Hi again, reading the documentation (which is always a good idea) revealed the the configuration wizard can be executed in console mode also(config.sh -mode=console). By using that I was able to create the domain. I still have no idea why unpack command failed, but this workaround was sufficient at this point. Thanks for providing the info anyway!
MarkoU
+1  A: 

Hi Marko,

with unpack the problem is there because unpack needs write permission on one folder and the file domain-registry.xml.

This problem occurs because you have installed the Weblogic installation with one user and you want to execute unpack with a different user.

The user starting the unpack.sh needs write access to the folder $BEA_HOME/wlserver_10.3/common/lib. A temporary file is written here by the user executing the unpack command. This file is removed by unpack after the unpack command has terminated.

Beside of this directory the file $BEA_HOME/domain-registry.xml is updated by the unpack command. Use chmod as the install user to give write access for the time you need to unpack the domain on the folder and the file with the command below:

chmod a+rwx $BEA_HOME/wlserver_10.3/common/lib $BEA_HOME/domain-registry.xml

After the creation of the domain change the permission to a safe value.

Regards

     Hemant
Thank you. That was the problem for me, the owner of WebLogic installation was not the same user as the user I was using to unpack the domain. I gave to the domain user the permission to write into WebLogic installation.
Mircea Vutcovici