You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by joe <fi...@yahoo.de> on 2010/12/06 11:13:06 UTC
blank in OPENEJB_HOME
Hi,
Today i moved an OpenEJB installation to "c:\Program Files".
I adapted the OPENEJB_HOME but in the first time, i wasn't able to start
the container using the openejb.bat.
Error opening zip file or JAR manifest missing : c:\Program
Error occurred during initialization of VM
agent library failed to init: instrument
I played around with some single/double qouting in the command line,
but i only was able to get the container started after adapting the
openejb.bat
the following line must be adapted
java %OPENEJB_OPTS% -javaagent:%OPENEJB_JAVAAGENT_JAR% -jar
%OPENEJB_CORE_JAR% %*
to
java %OPENEJB_OPTS% -javaagent:"%OPENEJB_JAVAAGENT_JAR%" -jar
"%OPENEJB_CORE_JAR%" %*
After this starting was no problem.
Maybe this is something that should be adapted in a newer release.
Re: blank in OPENEJB_HOME
Posted by Andy <an...@orprovision.com>.
On 06.12.2010 13:57, Andy wrote:
> On 06.12.2010 11:57, Jean-Louis MONTEIRO wrote:
>> Andy,
>>
>> I can add quotes to the script to fix spaces issue.
>> But, do you think our batch file can be updated according to your proposal ?
>>
>> Jean-Louis
> I have checked it into trunk - It's just a little bit more dynamic than the current one, and also fixes the quoted
> path issues.
> I still want to find the time to document the Windows service installation!
>
> Andy.
>
>
>
The files can all be found here for those that would like to try the latest Windows batch files and or services:
https://svn.apache.org/repos/asf/openejb/trunk/openejb3/assembly/openejb-standalone/src/main/resources/
Andy.
Re: blank in OPENEJB_HOME
Posted by Andy <an...@orprovision.com>.
On 06.12.2010 11:57, Jean-Louis MONTEIRO wrote:
> Andy,
>
> I can add quotes to the script to fix spaces issue.
> But, do you think our batch file can be updated according to your proposal ?
>
> Jean-Louis
I have checked it into trunk - It's just a little bit more dynamic than the current one, and also fixes the quoted path
issues.
I still want to find the time to document the Windows service installation!
Andy.
Re: blank in OPENEJB_HOME
Posted by Jean-Louis MONTEIRO <je...@atosorigin.com>.
Andy,
I can add quotes to the script to fix spaces issue.
But, do you think our batch file can be updated according to your proposal ?
Jean-Louis
--
View this message in context: http://openejb.979440.n4.nabble.com/blank-in-OPENEJB-HOME-tp3074224p3074282.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: blank in OPENEJB_HOME
Posted by Andy <an...@orprovision.com>.
I use this slightly more robust batch file.
Andy.
@echo off
CLS
REM================================================
REM Licensed to the Apache Software Foundation (ASF) under one or more
REM contributor license agreements. See the NOTICE file distributed with
REM this work for additional information regarding copyright ownership.
REM The ASF licenses this file to You under the Apache License, Version 2.0
REM (the "License"); you may not use this file except in compliance with
REM the License. You may obtain a copy of the License at
REM
REM http://www.apache.org/licenses/LICENSE-2.0
REM
REM Unless required by applicable law or agreed to in writing, software
REM distributed under the License is distributed on an "AS IS" BASIS,
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
REM See the License for the specific language governing permissions and
REM limitations under the License.
REM _______________________________________________
REM $Rev: 636963 $ $Date: 2008-03-14 03:40:08 +0100 (Fr, 14 Mrz 2008) $
REM================================================
@echo off
rem -------------------------------------------------------------------------
rem Manager Bootstrap Script for Windows
rem -------------------------------------------------------------------------
@if not "%ECHO%" == "" echo %ECHO%
@if "%OS%" == "Windows_NT" setlocal
if "%OS%" == "Windows_NT" (
set "DIRNAME=%~dp0%"
) else (
set "DIRNAME=.\"
)
pushd "%DIRNAME%
REM echo Path is: "%DIRNAME%"
set OPENEJB_HOME=.
cd ..
set "OPENEJB_HOME=%CD%"
REM echo OPENEJB_HOME is: %OPENEJB_HOME%
set OPENEJB_CORE_JAR="%OPENEJB_HOME%\lib\openejb-core-*.jar"
set OPENEJB_JAVAAGENT_JAR="%OPENEJB_HOME%\lib\openejb-javaagent-*.jar"
for %%a in (%OPENEJB_CORE_JAR%) do (
set OPENEJB_CORE_JAR="%%a"
)
for %%a in (%OPENEJB_JAVAAGENT_JAR%) do (
set OPENEJB_JAVAAGENT_JAR="%%a"
)
REM echo OPENEJB_CORE_JAR is: %OPENEJB_CORE_JAR%
REM echo OPENEJB_JAVAAGENT_JAR is: %OPENEJB_JAVAAGENT_JAR%
if exist %OPENEJB_CORE_JAR% goto openejbHomeSet
:noOpenEJBHome
echo OPENEJB_HOME is set incorrectly or OpenEJB could not be located. Please set "%OPENEJB_HOME%".
goto EOF
:openejbHomeSet
set OPTIONS=-Dopenejb.home=%OPENEJB_HOME%
REM echo %OPENEJB_OPTS% -javaagent:%OPENEJB_JAVAAGENT_JAR% -jar %OPENEJB_CORE_JAR% %*
java %OPENEJB_OPTS% -javaagent:%OPENEJB_JAVAAGENT_JAR% -jar %OPENEJB_CORE_JAR% %*
:EOF
ENDLOCAL