Quantcast

shutdown cleanly problems

classic Classic list List threaded Threaded
18 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

shutdown cleanly problems

badbetty
how's it going folks - good i hope

this is more a linux question i think, but there may be some mileage here first  :-)

now then, please:

on linux i may start eXist manually from shell (with a 'nohup') ...forget about it and then remotely shut the machine down later.

i suspect , due to one or two issues (not going in to them here), that this isn't doing eXist any good sometimes.

so, is there a way to script something that will check for eXist and cleanly shut it down within the Linux shutdown process -     if this is really too linuxy for here, then is there a script to at least call in eXist that could be referenced/called?

thank you for your assistance.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Dannes Wessels-2
Hi,

On 27 Jul 2013, at 18:11 , badbetty <[hidden email]> wrote:

> so, is there a way to script something that will check for eXist and cleanly
> shut it down within the Linux shutdown process -     if this is really too
> linuxy for here, then is there a script to at least call in eXist that could
> be referenced/called?

yes, that is the wrapper:

- http://exist-db.org/exist/apps/doc/advanced-installation.xml#service

regards

Dannes


------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open

smime.p7s (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

lin_xd
In reply to this post by badbetty
tools/warpper/bin/exist.sh  start/stop
At 2013-07-28 00:11:22,badbetty <[hidden email]> wrote:

>how's it going folks - good i hope
>
>this is more a linux question i think, but there may be some mileage here
>first  :-)
>
>now then, please:
>
>on linux i may start eXist manually from shell (with a 'nohup') ...forget
>about it and then remotely shut the machine down later.
>
>i suspect , due to one or two issues (not going in to them here), that this
>isn't doing eXist any good sometimes.
>
>so, is there a way to script something that will check for eXist and cleanly
>shut it down within the Linux shutdown process -     if this is really too
>linuxy for here, then is there a script to at least call in eXist that could
>be referenced/called?
>
>thank you for your assistance.
>
>
>
>--
>View this message in context: http://exist.2174344.n4.nabble.com/shutdown-cleanly-problems-tp4660671.html
>Sent from the exist-open mailing list archive at Nabble.com.
>
>------------------------------------------------------------------------------
>See everything from the browser to the database with AppDynamics
>Get end-to-end visibility with application monitoring from AppDynamics
>Isolate bottlenecks and diagnose root cause in seconds.
>Start your free trial of AppDynamics Pro today!
>http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
>_______________________________________________
>Exist-open mailing list
>[hidden email]
>https://lists.sourceforge.net/lists/listinfo/exist-open


------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Dannes Wessels-2
Hi

On 27 Jul 2013, at 20:02 , easy <[hidden email]> wrote:

tools/warpper/bin/exist.sh  start/stop

no that does not have added value: it is the 'install' feature ; for this please RTM...

D.


------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
In reply to this post by badbetty
thanks for the info - ive used the    exist.sh install method  using sudo  .... just to test.

i've then used init.d  to start, stop and restart  and checked the logs.   each time on shutdown there is this message in the log file :

JVM exited unexpectedly while stopping the application


as i say,  i have changed nothing from defaults.  

has any one else encountered this or have any advice on where i can start to look   etc.

thank you again
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Wolfgang Meier-2
> JVM exited unexpectedly while stopping the application

Have you checked the eXist log files to see if it has shut down properly? If yes, the message from the wrapper would be ok because eXist has terminated the JVM.

Wolfgang
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
me again

yes i've checked the logs (mainly webapp/WEB-INF/logs/exist.log) and cannot see anything that resembles an error message.

i will presume as Wolfgang suggests ..... all ok.


thank you all.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
In reply to this post by badbetty
im back again

summary so far:

installed wrapper etc and can see eXist script in init.d   and also S and K symlinks in run level directories  rc.x


manually running  /etc/init.d/exist-db start     and  stop  etc    works and log entries in  wrapper and in exist log files are created.

however,   nothing happens by default at boot time.    despite   the scripts being in the rc.x   ...  nothing loads up....no entries in the logs.

i have not changed anything in any of the scripts and left it all as default wrapper install.

obviously something is amiss somewhere (probably me).     please can i have another prompt on where to check next ?


linux is latest Suse.


thank you






Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Dannes Wessels-2
hi,

On 30 Jul 2013, at 10:56 , badbetty <[hidden email]> wrote:

> installed wrapper etc and can see eXist script in init.d   and also S and K
> symlinks in run level directories  rc.x

did the wrapper script install these links?
is there anything logged on linux-level?

"no logs" : which files did you check? also the log directory in the wrapper directory?

please run "/etc/init.d/exist.sh console" or "tools/wrapper/bin/exist.sh console" for some details....

see the documentation on http://wrapper.tanukisoftware.com/doc/english/launch-nix.html#console

regards

Dannes


------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open

smime.p7s (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
Hello Dannes

all the links etc were installed by the wrapper install script - i havent made any changes

logs checked:

WEB-INF/logs/exist.log    and     wrapper/logs/wrapper.log
nothing noticed in /var/logs/boot


/etc/init.d/exist.sh   is not present    but tried  tools/wrapper/bin/exist.sh console and it started an instance  (and filled in the above logs of course)

but as i said earlier....  /etc/init.d/exist-db  start, stop and restart    all work fine if called manually  and log correctly

its only when the machine starts or boots...nothing happens for some reason.


my [limited] understanding is that   linux will boot and for example, the S50exist-db in /etc/init.d/rc5.d will be executed  so that means a call to   exist-db   which is a symlink to  [in my case] :  eXist/tools/wrapper/bin/./exist.sh   (ie. the file you asked me above to try which worked)

interesting path:   what is the  /./  referring to   ?   is this path correct?    it is as it was created by the wrapper install routine


thank you

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
extra...

when running the   wrapper/exist.sh console,  the only errors on standard out (if indeed they are errors)  i see are:

jvm 1    | log4j:WARN Continuable parsing error 1 and column 240
jvm 1    | log4j:WARN Document root element "log4j:configuration", must match DOCTYPE root "null".
jvm 1    | log4j:WARN Continuable parsing error 1 and column 240
jvm 1    | log4j:WARN Document is invalid: no grammar found.
j
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Dannes Wessels-2
this looks good....

but.... doe sit end like

INFO   | jvm 1    | 2013/07/30 09:01:20 | 30 Jul 2013 09:01:20,583 [WrapperListener_start_runner] INFO  (JettyStart.java [lifeCycleStarted]:410) - Jetty server started.
INFO   | jvm 1    | 2013/07/30 09:01:20 | 30 Jul 2013 09:01:20,585 [WrapperListener_start_runner] INFO  (JettyStart.java [run]:224) - -----------------------------------------------------
INFO   | jvm 1    | 2013/07/30 09:01:20 | 30 Jul 2013 09:01:20,585 [WrapperListener_start_runner] INFO  (JettyStart.java [run]:225) - Server has started on ports 7080 8443. Configured contexts:
INFO   | jvm 1    | 2013/07/30 09:01:20 | 30 Jul 2013 09:01:20,585 [WrapperListener_start_runner] INFO  (JettyStart.java [run]:234) - '/exist'
INFO   | jvm 1    | 2013/07/30 09:01:20 | 30 Jul 2013 09:01:20,585 [WrapperListener_start_runner] INFO  (JettyStart.java [run]:272) - -----------------------------------------------------
INFO   | jvm 1    | 2013/07/30 09:01:36 | Loading mime table from file /mypath/tools/wrapper/bin/../../../mime-types.xml

?

On 30 Jul 2013, at 14:33 , badbetty <[hidden email]> wrote:

> when running the   wrapper/exist.sh console,  the only errors on standard
> out (if indeed they are errors)  i see are:
>
> jvm 1    | log4j:WARN Continuable parsing error 1 and column 240
> jvm 1    | log4j:WARN Document root element "log4j:configuration", must
> match DOCTYPE root "null".
> jvm 1    | log4j:WARN Continuable parsing error 1 and column 240
> jvm 1    | log4j:WARN Document is invalid: no grammar found.


------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Dannes Wessels-2
In reply to this post by badbetty

On 30 Jul 2013, at 14:30 , badbetty <[hidden email]> wrote:

> all the links etc were installed by the wrapper install script - i havent
> made any changes
>
> logs checked:
>
> WEB-INF/logs/exist.log    and     wrapper/logs/wrapper.log
> nothing noticed in /var/logs/boot

Ok


> /etc/init.d/exist.sh   is not present    

I do not know the SuSe specifiics


> but tried tools/wrapper/bin/exist.sh console and it started an instance  (and filled
> in the above logs of course)
>
> but as i said earlier....  /etc/init.d/exist-db  start, stop and restart  
> all work fine if called manually  and log correctly

that is encouraging


> its only when the machine starts or boots...nothing happens for some reason.


that is strange indeed

> my [limited] understanding is that   linux will boot and for example, the
> S50exist-db in /etc/init.d/rc5.d will be executed  so that means a call to  
> exist-db   which is a symlink to  [in my case] :
> eXist/tools/wrapper/bin/./exist.sh   (ie. the file you asked me above to try
> which worked)

well, Myself I left linux quite some time ago (if I need a VM I use an ubuntu like image), my knowledge about the SuSe specifics is void.

it should work though: http://wrapper.tanukisoftware.com/doc/english/supported-platforms-350.html#Linux

I hope someone from the community can step into this discussion; Adam?


>
> interesting path:   what is the  /./  referring to   ?   is this path
> correct?    it is as it was created by the wrapper install routine

I could not say, but i'd think it is ok....

some more refs, alike the instructions you followed:
- http://www.source-code.biz/snippets/java/7.htm
- http://forum.pmease.com/viewtopic.php?f=1&t=2434


some specific SuSe thingies are in exist.sh:
- https://github.com/eXist-db/exist/blob/develop/tools/wrapper/bin/exist.sh.in 

regards

Dannes



------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
i have another observation.....

eXist/tools/wrapper/bin/./exist.sh           ....    when run manually   does only list  the options   e.g. console, start etc.


so i'm unclear how  eXist/tools/wrapper/bin/./exist.sh   in   init.d     without   a console, start or restart,  will do any thing ?

perhaps  exist.sh  has a default behaviour -  i cannot see it does   ?


any thoughts please. thank you.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Dannes Wessels-2
I can't help you on the SuSe specifics; anyone else?


On 30 Jul 2013, at 21:09 , badbetty <[hidden email]> wrote:

any thoughts please. thank you


------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

Tobias Krebs
In reply to this post by badbetty
Hi,

Am 30.07.2013 14:30, schrieb badbetty:

> Hello Dannes
>
> all the links etc were installed by the wrapper install script - i havent
> made any changes
>
> logs checked:
>
> WEB-INF/logs/exist.log    and     wrapper/logs/wrapper.log
> nothing noticed in /var/logs/boot
>
>
> /etc/init.d/exist.sh   is not present    but tried
> tools/wrapper/bin/exist.sh console and it started an instance  (and filled
> in the above logs of course)
>
> but as i said earlier....  /etc/init.d/exist-db  start, stop and restart
> all work fine if called manually  and log correctly
>
> its only when the machine starts or boots...nothing happens for some reason.

If i remember correctly you have to use "chkconfig" on SuSe to set
symlinks in the corresponding runlevel (it uses "INIT INFO" in the
wrapper script). See "man chkconfig" for the correct syntax.

Hth

Tobi

--
Tobias Krebs
betterFORM Project
Web:     www.betterform.de
Office:       +49 30 83 22 55 50
Fax:     +49 30 83 22 55 04

------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
already it looks as if the correct symlinks are put in the runlevel directories under init.d



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: shutdown cleanly problems

badbetty
In reply to this post by badbetty
SOLVED

I think it all came down to permissions.

Firstly I did a clean install to /opt    and changed the owner and group permissions to e.g. existdb:existdb
(I was trying to run it as it was installed in my home dir.   where i experiment as such.)

I set RUNAS to user 'existdb'


then 'su'  and ran 'tools/wrapper/bin/exist.sh install'

rebooted machine and it seems fine.




Loading...