Sponsored Content
Full Discussion: Recycle Jboss server script
Top Forums Shell Programming and Scripting Recycle Jboss server script Post 302619915 by Blogger11 on Friday 6th of April 2012 11:00:27 AM
Old 04-06-2012
Recycle Jboss server script

Hello, I need help writing a script to restart our Jboss server when it crashes. I am not very good with scripting but here is the basics.

1) I'm hoping to use KornShell
2) The command to stop the Jboss is "/var/opt/HP/ALM/jboss/bin/run.sh stop"
3) I want to verify the jboss is stopped before attempting to restart, not sure how to do this at all
4) Start the jboss "/var/opt/HP/ALM/jboss/bin/run.sh start"

Should be very simple but I just am not sure where to start, how to get that stop/start command to be input into the string. Can anyone help?
 

10 More Discussions You Might Find Interesting

1. Windows & DOS: Issues & Discussions

Path of Recycle Bin on Windows

hello everybody, I am trying to find the path of the Recycle Bin. I know that it's a temporary storage place, but it should have a path that we can refer to. I want to know it because I sometimes use cygwin to work on Windows, and when you delete something with it, it's gone. I just checked... (4 Replies)
Discussion started by: milhan
4 Replies

2. UNIX for Dummies Questions & Answers

HP-UX recycle

Hi, I am new to HP-UX environment. Could someone help me giving commands to recycle the server and how to go to single user mode. Thanks Hemanth (3 Replies)
Discussion started by: Hemanth_gp
3 Replies

3. Red Hat

JBoss Application Server 5 CR1 available

The first candidate release (CR1) for JBoss Application Server 5 has been released. There is a lot of good background from Sacha Labourey and feature details from project lead Dimitris Andreadis. Now that version 5 of the new application server has been through alpha and beta stages, this... (0 Replies)
Discussion started by: Linux Bot
0 Replies

4. Shell Programming and Scripting

Recycle Bin Script

Hello, I have having problems with an assignment and am pretty desperate. My assignment is to create a shell script that does a Recycle_Bin tasks. You can only open this with PuTTY software or Knoppix. Perhaps on other software that are able to read linux language. My part is stuck... (2 Replies)
Discussion started by: chueu
2 Replies

5. Shell Programming and Scripting

Script to monitor JBoss web server

Hello All, I need a shell script to monitor JBOSS web server.If the JBOSS web server is down, then the script should send a mail. Please help on this. Regards, Sachin (2 Replies)
Discussion started by: nsachin
2 Replies

6. UNIX for Dummies Questions & Answers

Help with my recycle bin code

Hi~ I have a problem with my recycle bin code. #!/bin/bash if test !-d ~/.recyclebin #if recycle bin does not exists then mkdir ~/.recyclebin # then create recycle bin else mv $1 ~/.recyclebin #else move the deleted file in the recycle bin fi so when I... (10 Replies)
Discussion started by: zel2zel
10 Replies

7. Shell Programming and Scripting

Single Startup script for Apache/jboss

Hi, I have apache ,jboss and jon instances on various linux boxes.I need to create a generic startup script to restart those instances on server reboot.The script requirement is : It should take the name of instances from one text file named active-servers and recycle those instances. 1.... (6 Replies)
Discussion started by: saurau
6 Replies

8. Shell Programming and Scripting

Recycle Bin

what is recycle bin mode in unix??? (4 Replies)
Discussion started by: arun508.gatike
4 Replies

9. UNIX for Dummies Questions & Answers

Recycle bin on minix 3.2.1?

Hi. I'm started to use minix 3.2.1 recently and I'm trying to create a recycle bin for it. I'm kinda struggling on how to do it. I searched internet and I found scripts created for it but I actually didn't learn how to create scripts in college and I'm not sure if I understand them. I just wanted... (1 Reply)
Discussion started by: ReonarudoB
1 Replies

10. Shell Programming and Scripting

Recycle bin.

Hi. I've created scripts for a recycle bin that can list, restore and empty it. I only have the problem of deleting two files with the same name. When I do it one file overwrite the other. What could I do to resolve it? The only thing I can think is asking the user to rename file before moving to... (2 Replies)
Discussion started by: ReonarudoB
2 Replies
OCF_HEARTBEAT_JBOSS(7)						OCF resource agents					    OCF_HEARTBEAT_JBOSS(7)

NAME
ocf_heartbeat_jboss - Manages a JBoss application server instance SYNOPSIS
jboss [start | stop | status | monitor | meta-data | validate-all] DESCRIPTION
Resource script for Jboss. It manages a Jboss instance as an HA resource. SUPPORTED PARAMETERS
resource_name The name of the resource. Defaults to the name of the resource instance. (unique, optional, string, default default) console A destination of the log of jboss run and shutdown script. (unique, optional, string, no default) shutdown_timeout Timeout for jboss bin/shutdown.sh. We wait for this timeout to expire, then send the TERM and QUIT signals. Finally, the KILL signal is used to terminate the jboss process. You should set the timeout for the stop operation to a value bigger than the sum of the timeout parameters. See also kill_timeout. (optional, integer, default 5) kill_timeout If bin/shutdown.sh doesn't stop the jboss process, then we send it TERM and QUIT signals, intermittently and once a second. After this timeout expires, if the process is still live, we use the KILL signal. See also shutdown_timeout. (optional, integer, default 10) user A user name to start a JBoss. (optional, string, default root) statusurl URL to test in the monitor operation. (optional, string, default http://127.0.0.1:8080) java_home Home directory of Java. Defaults to the environment variable JAVA_HOME. If it is not set, then define this parameter. (optional, string, no default) jboss_home Home directory of Jboss. (unique, required, string, no default) pstring With this string heartbeat matches for the right process to kill. (optional, string, default java -Dprogram.name=run.sh) run_opts Start options to start Jboss with, defaults are from the Jboss-Doku. (optional, string, default -c default -l lpg4j) shutdown_opts Stop options to stop Jboss with. (optional, string, default -s 127.0.0.1:1099) SUPPORTED ACTIONS
This resource agent supports the following actions (operations): start Starts the resource. Suggested minimum timeout: 60s. stop Stops the resource. Suggested minimum timeout: 120s. status Performs a status check. Suggested minimum timeout: 30s. monitor Performs a detailed status check. Suggested minimum timeout: 30s. Suggested interval: 10s. meta-data Retrieves resource agent metadata (internal use only). Suggested minimum timeout: 5s. validate-all Performs a validation of the resource configuration. Suggested minimum timeout: 5. EXAMPLE
The following is an example configuration for a jboss resource using the crm(8) shell: primitive p_jboss ocf:heartbeat:jboss params jboss_home=string op monitor depth="0" timeout="30s" interval="10s" SEE ALSO
http://www.linux-ha.org/wiki/jboss_(resource_agent) AUTHOR
Linux-HA contributors (see the resource agent source for information about individual authors) resource-agents UNKNOWN 03/09/2014 OCF_HEARTBEAT_JBOSS(7)
All times are GMT -4. The time now is 06:10 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy