This content has been marked as final.
Show 9 replies
-
1. Re: Remote conenct JBoss AS
jaikiran Jul 2, 2008 1:14 AM (in response to gan.gary)Start JBoss with -b option. See this for more details http://wiki.jboss.org/wiki/Wiki.jsp?page=JBoss42FAQ
-
2. Re: Remote conenct JBoss AS
gan.gary Jul 2, 2008 1:30 AM (in response to gan.gary)it only mentioned using as normal app. what If my JBoss set as JBoss Native windows service? Do i need to modify "service.bat"?
:cmdInstall jbosssvc.exe -imwdc %SVCNAME% "%DIRNAME%" "%SVCDISP%" "%SVCDESC%" service.bat if not errorlevel 0 goto errExplain echo Service %SVCDISP% installed goto cmdEnd
-
3. Re: Remote conenct JBoss AS
jaikiran Jul 2, 2008 1:38 AM (in response to gan.gary)service.bat acts just like a wrapper over the run.bat. So edit your service.bat to include the -b option as follows:
:cmdStart REM Executed on service start call run.bat -b 0.0.0.0>run.log
:cmdRestart REM Executed on service restart REM Note. We can only stop and start call shutdown -S >>shutdown.log call run.bat -b 0.0.0.0 >>run.log goto cmdEnd
-
4. Re: Remote conenct JBoss AS
gan.gary Jul 2, 2008 2:32 AM (in response to gan.gary)"jaikiran" wrote:
service.bat acts just like a wrapper over the run.bat. So edit your service.bat to include the -b option as follows::cmdStart REM Executed on service start call run.bat -b 0.0.0.0>run.log
:cmdRestart REM Executed on service restart REM Note. We can only stop and start call shutdown -S >>shutdown.log call run.bat -b 0.0.0.0 >>run.log goto cmdEnd
thanks!
cmdRestart? I found the places call the "run.bat" is on::cmdStart REM Executed on service start del .r.lock 2>&1 | findstr /C:"being used" > nul if not errorlevel 1 ( echo Could not continue. Locking file already in use. goto cmdEnd ) echo Y > .r.lock jbosssvc.exe -p 1 "Starting %SVCDISP%" > run.log call run.bat < .r.lock >> run.log 2>&1 jbosssvc.exe -p 1 "Shutdown %SVCDISP% service" >> run.log del .r.lock goto cmdEnd
:waitRun REM Delete lock file del .r.lock > nul 2>&1 REM Wait one second if lock file exist jbosssvc.exe -s 1 if exist ".r.lock" goto waitRun echo Y > .r.lock jbosssvc.exe -p 1 "Restarting %SVCDISP%" >> run.log call run.bat < .r.lock >> run.log 2>&1 jbosssvc.exe -p 1 "Shutdown %SVCDISP% service" >> run.log del .r.lock goto cmdEnd
why on cmdRestart? -
5. Re: Remote conenct JBoss AS
gan.gary Jul 2, 2008 3:13 AM (in response to gan.gary)even I removed & re-installed & changed to this:
:cmdStart REM Executed on service start del .r.lock 2>&1 | findstr /C:"being used" > nul if not errorlevel 1 ( echo Could not continue. Locking file already in use. goto cmdEnd ) echo Y > .r.lock jbosssvc.exe -p 1 "Starting %SVCDISP%" > run.log call run.bat -b 0.0.0.0 < .r.lock >> run.log 2>&1 jbosssvc.exe -p 1 "Shutdown %SVCDISP% service" >> run.log del .r.lock goto cmdEnd
also cannot. -
6. Re: Remote conenct JBoss AS
jaikiran Jul 2, 2008 3:24 AM (in response to gan.gary)The contents from service.bat that i posted were from an older version of JBossNative. For the version you are using, the service.bat has to be edited as follows:
:cmdStart REM Executed on service start del .r.lock 2>&1 | findstr /C:"being used" > nul if not errorlevel 1 ( echo Could not continue. Locking file already in use. goto cmdEnd ) echo Y > .r.lock jbosssvc.exe -p 1 "Starting %SVCDISP%" > run.log call run.bat < .r.lock -b 0.0.0.0 >> run.log 2>&1 ..... ...... some more lines from the bat file .... .... :cmdRestart REM Executed manually from command line REM Note: We can only stop and start echo Y > .s.lock jbosssvc.exe -p 1 "Shutting down %SVCDISP%" >> shutdown.log call shutdown -S < .s.lock >> shutdown.log 2>&1 del .s.lock :waitRun REM Delete lock file del .r.lock > nul 2>&1 REM Wait one second if lock file exist jbosssvc.exe -s 1 if exist ".r.lock" goto waitRun echo Y > .r.lock jbosssvc.exe -p 1 "Restarting %SVCDISP%" >> run.log call run.bat < .r.lock -b 0.0.0.0 >> run.log 2>&1
-
7. Re: Remote conenct JBoss AS
gan.gary Jul 2, 2008 3:32 AM (in response to gan.gary)why
call run.bat < .r.lock -b 0.0.0.0 >> run.log 2>&1
instead ofcall run.bat -b 0.0.0.0 < .r.lock >> run.log 2>&1
-
-
9. Re: Remote conenct JBoss AS
gan.gary Jul 2, 2008 6:36 AM (in response to gan.gary)great, thanks!. You solved my problem. I found my problem is casued by IP problem.