dist: change scylla-jmx process name from 'java' to 'scylla-jmx'
Helps in top, pgrep and friends. Unfortunately the only reasonable way to do it is to create a symlink to /usr/bin/java and run that. Message-Id: <1463580254-8369-1-git-send-email-avi@scylladb.com>
This commit is contained in:
parent
2ff16fa2a5
commit
f6710465ef
3
dist/redhat/scylla-jmx.spec.in
vendored
3
dist/redhat/scylla-jmx.spec.in
vendored
@ -32,8 +32,10 @@ install -m644 dist/common/sysconfig/scylla-jmx $RPM_BUILD_ROOT%{_sysconfdir}/sys
|
|||||||
install -m644 dist/redhat/systemd/scylla-jmx.service $RPM_BUILD_ROOT%{_unitdir}/
|
install -m644 dist/redhat/systemd/scylla-jmx.service $RPM_BUILD_ROOT%{_unitdir}/
|
||||||
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla
|
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla
|
||||||
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
|
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
|
||||||
|
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx/symlinks
|
||||||
install -m644 target/scylla-jmx-1.0.jar $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx/
|
install -m644 target/scylla-jmx-1.0.jar $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx/
|
||||||
install -m755 scripts/scylla-jmx $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
|
install -m755 scripts/scylla-jmx $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
|
||||||
|
ln -sf /usr/bin/java $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx/symlinks/scylla-jmx
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
/usr/sbin/groupadd scylla 2> /dev/null || :
|
/usr/sbin/groupadd scylla 2> /dev/null || :
|
||||||
@ -68,6 +70,7 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%{_unitdir}/scylla-jmx.service
|
%{_unitdir}/scylla-jmx.service
|
||||||
%{_prefix}/lib/scylla/jmx/scylla-jmx
|
%{_prefix}/lib/scylla/jmx/scylla-jmx
|
||||||
%{_prefix}/lib/scylla/jmx/scylla-jmx-1.0.jar
|
%{_prefix}/lib/scylla/jmx/scylla-jmx-1.0.jar
|
||||||
|
%{_prefix}/lib/scylla/jmx/symlinks/scylla-jmx
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Fri Aug 7 2015 Takuya ASADA Takuya ASADA <syuu@cloudius-systems.com>
|
* Fri Aug 7 2015 Takuya ASADA Takuya ASADA <syuu@cloudius-systems.com>
|
||||||
|
2
dist/ubuntu/rules.in
vendored
2
dist/ubuntu/rules.in
vendored
@ -22,6 +22,8 @@ override_dh_auto_install:
|
|||||||
mkdir -p $(DEST)
|
mkdir -p $(DEST)
|
||||||
cp $(CURDIR)/scripts/scylla-jmx $(DEST)
|
cp $(CURDIR)/scripts/scylla-jmx $(DEST)
|
||||||
cp $(CURDIR)/target/scylla-jmx-1.0.jar $(DEST)
|
cp $(CURDIR)/target/scylla-jmx-1.0.jar $(DEST)
|
||||||
|
mkdir $(DEST)/symlinks
|
||||||
|
ln -sf /usr/bin/java $(DEST)/symlinks/scylla-jmx
|
||||||
|
|
||||||
override_dh_installinit:
|
override_dh_installinit:
|
||||||
dh_installinit --no-start @@DH_INSTALLINIT@@
|
dh_installinit --no-start @@DH_INSTALLINIT@@
|
||||||
|
@ -13,6 +13,7 @@ PARAM_API_PORT="-p"
|
|||||||
PARAM_ADDR="-a"
|
PARAM_ADDR="-a"
|
||||||
PARAM_LOCATION="-l"
|
PARAM_LOCATION="-l"
|
||||||
LOCATION="target"
|
LOCATION="target"
|
||||||
|
LOCATION_SCRIPTS="scripts"
|
||||||
PARAM_FILE="-cf"
|
PARAM_FILE="-cf"
|
||||||
ALLOW_REMOTE="-r"
|
ALLOW_REMOTE="-r"
|
||||||
ALLOW_DEBUG="-d"
|
ALLOW_DEBUG="-d"
|
||||||
@ -61,6 +62,7 @@ do
|
|||||||
;;
|
;;
|
||||||
"$PARAM_LOCATION")
|
"$PARAM_LOCATION")
|
||||||
LOCATION=$2
|
LOCATION=$2
|
||||||
|
LOCATION_SCRIPTS="$2"
|
||||||
shift 2
|
shift 2
|
||||||
;;
|
;;
|
||||||
"$PARAM_FILE")
|
"$PARAM_FILE")
|
||||||
@ -90,4 +92,4 @@ else
|
|||||||
REMOTE="-Dcassandra.jmx.local.port=$JMX_PORT"
|
REMOTE="-Dcassandra.jmx.local.port=$JMX_PORT"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
exec java $API_ADDR $API_PORT $DEBUG $CONF_FILE $REMOTE -Xmx256m -XX:+UseSerialGC -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -jar $LOCATION/scylla-jmx-1.0.jar
|
exec "$LOCATION_SCRIPTS"/symlinks/scylla-jmx $API_ADDR $API_PORT $DEBUG $CONF_FILE $REMOTE -Xmx256m -XX:+UseSerialGC -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -jar $LOCATION/scylla-jmx-1.0.jar
|
||||||
|
1
scripts/symlinks/scylla-jmx
Symbolic link
1
scripts/symlinks/scylla-jmx
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
/usr/bin/java
|
Loading…
Reference in New Issue
Block a user