Friday, September 22, 2017

The Shell Script Stop Start and control JBoss standalone 7 1 final

The Shell Script Stop Start and control JBoss standalone 7 1 final


The Shell Script Stop Start and control JBoss standalone 7.1 final
           the script run by user or root on Linux platform. you need to define variable environment for script Like follow :
            JAVA_HOME = path of java installed (1.6 or higher)
            JBOSS_HOME = path of jboss
            JBOSS_CONFIG = path file of jboss configuration.
            .....bababa........


#!/bin/sh
#
# JBoss standalone control script
#
# chkconfig: - 2012-10-25
# description: JBoss AS Standalone
# processname: standalone
# pidfile: JBOSS_HOME/jboss-as-standalone.pid

# Define Java configuration.
export JAVA_HOME=/usr/local/java

# Load JBoss AS init.d configuration.
if [ -z "$JBOSS_CONF" ]; then
JBOSS_CONF="/opt/JBOSS71/bin/jboss-as-standalone.conf"
fi

[ -r "$JBOSS_CONF" ] && . "${JBOSS_CONF}"

# Set defaults.

if [ -z "$JBOSS_HOME" ]; then
JBOSS_HOME=/opt/JBOSS71
fi
export JBOSS_HOME

if [ -z "$JBOSS_PIDFILE" ]; then
JBOSS_PIDFILE=$JBOSS_HOME/bin/jboss-as-standalone.pid
fi
export JBOSS_PIDFILE

if [ -z "$JBOSS_CONSOLE_LOG" ]; then
JBOSS_CONSOLE_LOG=$JBOSS_HOME/console.log
fi

if [ -z "$STARTUP_WAIT" ]; then
STARTUP_WAIT=30
fi

if [ -z "$SHUTDOWN_WAIT" ]; then
SHUTDOWN_WAIT=30
fi

if [ -z "$JBOSS_CONFIG" ]; then
JBOSS_CONFIG=standalone.xml
fi

if [ -z "$JBOSS_USER" ]; then
JBOSS_USER=pum
fi

JBOSS_SCRIPT=$JBOSS_HOME/bin/standalone.sh

prog=JBOSS71 Server

start() {
echo -n "Starting $prog:"
if [ -f $JBOSS_PIDFILE ]; then
read ppid < $JBOSS_PIDFILE
if [ `ps --pid $ppid 2> /dev/null | grep -c $ppid 2> /dev/null` -eq 1 ]; then
echo -n "$prog is already running."
#failure
echo
return 1
else
rm -f $JBOSS_PIDFILE
fi
fi
#mkdir -p $(dirname $JBOSS_CONSOLE_LOG)
cat /dev/null > $JBOSS_CONSOLE_LOG
#mkdir -p $(dirname $JBOSS_PIDFILE)
chown $JBOSS_USER $(dirname $JBOSS_PIDFILE) || true

# Cleaning temp server
rm -rf $JBOSS_HOME/standalone/tmp/*
#comand start Jboss Server
eval LAUNCH_JBOSS_IN_BACKGROUND=1 JBOSS_PIDFILE=$JBOSS_PIDFILE $JBOSS_SCRIPT -c $JBOSS_CONFIG 2>&1 > $JBOSS_CONSOLE_LOG &

count=0
launched=false

until [ $count -gt $STARTUP_WAIT ]
do
grep Deployed "PUMEAR.ear" $JBOSS_CONSOLE_LOG > /dev/null
if [ $? -eq 0 ] ; then
launched=true
break
fi
echo -n "."
sleep 1
let count=$count+1;
done
echo ": PumSrv Starting Succeed!!."
return 0
}

stop() {
echo -n $"Stopping $prog:"
count=0;

if [ -f $JBOSS_PIDFILE ]; then
read kpid < $JBOSS_PIDFILE
let kwait=$SHUTDOWN_WAIT

# Try issuing SIGTERM

kill -15 $kpid
until [ `ps --pid $kpid 2> /dev/null | grep -c $kpid 2> /dev/null` -eq 0 ] || [ $count -gt $kwait ]
do
echo -n "."
sleep 1
let count=$count+1;
done

if [ $count -gt $kwait ]; then
kill -9 $kpid
fi
fi
rm -f $JBOSS_PIDFILE > /dev/null
#success
echo " PumSrv Server Stoping Succeed!!."
echo
}

status() {
if [ -f $JBOSS_PIDFILE ]; then
read ppid < $JBOSS_PIDFILE
if [ `ps --pid $ppid 2> /dev/null | grep -c $ppid 2> /dev/null` -eq 1 ]; then
echo "$prog is running (pid $ppid)"
return 0
else
echo "$prog dead but pid file exists"
return 1
fi
fi
echo "$prog is Not running."
return 3
}

case "$1" in
start)
start
;;
stop)
stop
;;
restart)
$0 stop
$0 start
;;
status)
status
;;
*)
## If no parameters are given, print which are avaiable.
echo "Usage: $0 {start|stop|status|restart}"
exit 1
;;
esac
Good luck ..... by stumjub!

download file now

Continue reading ...

Tuesday, August 22, 2017

The Transatlantic Cyber War Games Are to Start Soon

The Transatlantic Cyber War Games Are to Start Soon


Transatlantic Cyber War Games Are to Start Soon:

newsofcrime.blogspot.com
The UK and United States of America intelligence agencies are getting to conduct transatlantic cyber �war games� so as to check their resilience to the world cyber attacks. The heads of the 2 countries have started negotiations on the subject will announce that a simulated attack will target banks within the city of London and Wall Street later in 2015.
The simulated �war game� against the financial sector are allotted with the assistance of specialists of the Bank of england and different financial establishments and coordinated by a replacement joint �cyber-cell� of the 2 countries. The latter are created by agents from GCHQ and MI5 on the united kingdom aspect and also the NSA and also the FBI on the North American country aspect.

The us and uk leaders dont underestimate the threat of islamist extremists in syria, Iraq and in Europe and also the dangers represented by cyber-warfare. Obama pointed to the �urgent and growing danger� display by cyber attacks, and also the example was a recent attack on Sony pictures. Previously, the president spoke of the requirement for a �shared mission� with the participation of the govt. and also the personal sector. Considering that almost all of the �critical infrastructure� of the united states is closely-held by the personal sector and runs on networks connected to the internet, the conclusion will be created that neither the govt. nor the personal sector will defend the state alone.

Cooperation between the us and also the uk is meant to pool their effort and permit them keep one step ahead of people who ask for to attack. The heads of the states believe that the joint exercises and coaching of the next generation of cyber experts could make sure that the countries have the capability needed to safeguard vital sectors like energy, transport and financial infrastructure from the potential threats.

In the in the meantime, David Cameron has some inquiries to raise Obama and can apparently press him to influence the school giants, as well as Facebook and Twitter, to accentuate their efforts in cooperating with the intelligence agencies, that wish to observe the communications of suspected terrorists. David Cameron has proclaimed his plans a couple of days past to make a stronger legal framework that will enable intelligence agencies to interrupt into encrypted communications of the suspects, however he wants support of the US-based corporations, as well as the most important social media websites.


download file now

Continue reading ...