[pve-devel] [PATCH manager v2 03/17] services: remove obsolete init.d scripts
Thomas Lamprecht
t.lamprecht at proxmox.com
Mon Mar 12 14:13:54 CET 2018
They all have a systemd service file so no need for them anymore
Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
---
bin/init.d/Makefile | 13 ++---------
bin/init.d/pvebanner | 33 ----------------------------
bin/init.d/pvedaemon | 49 -----------------------------------------
bin/init.d/pveproxy | 60 ---------------------------------------------------
bin/init.d/pvestatd | 54 ----------------------------------------------
bin/init.d/spiceproxy | 60 ---------------------------------------------------
6 files changed, 2 insertions(+), 267 deletions(-)
delete mode 100755 bin/init.d/pvebanner
delete mode 100755 bin/init.d/pvedaemon
delete mode 100755 bin/init.d/pveproxy
delete mode 100755 bin/init.d/pvestatd
delete mode 100755 bin/init.d/spiceproxy
diff --git a/bin/init.d/Makefile b/bin/init.d/Makefile
index bd1445d2..45180244 100644
--- a/bin/init.d/Makefile
+++ b/bin/init.d/Makefile
@@ -2,13 +2,6 @@ include ../../defines.mk
all:
-SCRIPTS = \
- pvedaemon \
- pveproxy \
- spiceproxy \
- pvestatd
-
-
SERVICES= \
pvebanner.service \
pvenetcommit.service \
@@ -21,10 +14,8 @@ SERVICES= \
pvesr.service \
pvesr.timer
-.PHONY: install
-install: ${SCRIPTS}
- install -d ${INITDBINDIR}
- install -m 0755 ${SCRIPTS} ${INITDBINDIR}
+.PHONY: install
+install: ${SERVICES}
install -d ${SERVICEDIR}
install -m 0644 ${SERVICES} ${SERVICEDIR}
install -d ${SERVICEDIR}/ceph-mon at .service.d
diff --git a/bin/init.d/pvebanner b/bin/init.d/pvebanner
deleted file mode 100755
index 9c3312c9..00000000
--- a/bin/init.d/pvebanner
+++ /dev/null
@@ -1,33 +0,0 @@
-#!/bin/sh
-
-### BEGIN INIT INFO
-# Provides: pvebanner
-# Required-Start: $all
-# Required-Stop:
-# Default-Start: 2 3 4 5
-# Default-Stop:
-# Short-Description: print PVE banner
-### END INIT INFO
-
-. /lib/lsb/init-functions
-
-PATH=/sbin:/bin:/usr/bin:/usr/sbin
-
-test -f /usr/bin/pvebanner || exit 0
-
-test -f /etc/lsb-base-logging.sh || echo "FANCYTTY=0" >/etc/lsb-base-logging.sh
-
-case "$1" in
- start)
- pvebanner
- ;;
- stop|restart|force-reload)
- exit 1
- ;;
- *)
- echo "Usage: /etc/init.d/pvebanner {start}"
- exit 1
- ;;
-esac
-
-exit 0
diff --git a/bin/init.d/pvedaemon b/bin/init.d/pvedaemon
deleted file mode 100755
index 196f88f0..00000000
--- a/bin/init.d/pvedaemon
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/sh
-
-### BEGIN INIT INFO
-# Provides: pvedaemon
-# Required-Start: $remote_fs $network $syslog pve-cluster cman clvm
-# Required-Stop: $remote_fs $network $syslog pve-cluster cman clvm
-# Default-Start: 2 3 4 5
-# Default-Stop: 0 1 6
-# Short-Description: PVE Daemon
-### END INIT INFO
-
-. /lib/lsb/init-functions
-
-PATH=/sbin:/bin:/usr/bin:/usr/sbin
-DAEMON=/usr/bin/pvedaemon
-NAME=pvedaemon
-DESC="PVE Daemon"
-PIDFILE=/var/run/pvedaemon.pid
-
-test -f $DAEMON || exit 0
-
-# avoid warnings about uninstalled locales when pvedaemon executes commands
-export LC_ALL="C"
-
-case "$1" in
- start)
- log_daemon_msg "Starting $DESC" "$NAME"
- $DAEMON start
- log_end_msg $?
- ;;
- stop)
- log_daemon_msg "Stopping $DESC" "$NAME"
- $DAEMON stop
- log_end_msg $?
- ;;
- restart|reload|force-reload)
- log_daemon_msg "Restarting $DESC" "$NAME"
- $DAEMON restart
-
- log_end_msg $?
- ;;
- *)
- N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|restart|reload|force-reload}"
- exit 1
- ;;
-esac
-
-exit 0
diff --git a/bin/init.d/pveproxy b/bin/init.d/pveproxy
deleted file mode 100755
index 032c40f1..00000000
--- a/bin/init.d/pveproxy
+++ /dev/null
@@ -1,60 +0,0 @@
-#!/bin/sh
-
-### BEGIN INIT INFO
-# Provides: pveproxy
-# Required-Start: $remote_fs $network $syslog pvedaemon
-# Required-Stop: $remote_fs $network $syslog pvedaemon
-# Default-Start: 2 3 4 5
-# Default-Stop: 0 1 6
-# Short-Description: PVE API Proxy Server
-### END INIT INFO
-
-. /lib/lsb/init-functions
-
-PATH=/sbin:/bin:/usr/bin:/usr/sbin
-DAEMON=/usr/bin/pveproxy
-NAME=pveproxy
-DESC="PVE API Proxy Server"
-RUNDIR=/var/run/pveproxy
-PIDFILE=${RUNDIR}/pveproxy.pid
-
-test -f $DAEMON || exit 0
-
-# avoid warnings about uninstalled locales when pveproxy executes commands
-export LC_ALL="C"
-
-mkdir -p ${RUNDIR} || true
-chmod 0700 ${RUNDIR} || true
-chown www-data:www-data ${RUNDIR} || true
-
-DAEMON_OPTS=""
-
-# Include defaults if available
-if [ -f /etc/default/$NAME ] ; then
- . /etc/default/$NAME
-fi
-
-case "$1" in
- start)
- log_daemon_msg "Starting $DESC" "$NAME"
- $DAEMON start
- log_end_msg $?
- ;;
- stop)
- log_daemon_msg "Stopping $DESC" "$NAME"
- $DAEMON stop
- log_end_msg $?
- ;;
- restart|reload|force-reload)
- log_daemon_msg "Restarting $DESC" "$NAME"
- $DAEMON restart
- log_end_msg $?
- ;;
- *)
- N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|restart|reload|force-reload}"
- exit 1
- ;;
-esac
-
-exit 0
diff --git a/bin/init.d/pvestatd b/bin/init.d/pvestatd
deleted file mode 100755
index 8f87ae94..00000000
--- a/bin/init.d/pvestatd
+++ /dev/null
@@ -1,54 +0,0 @@
-#!/bin/sh
-
-### BEGIN INIT INFO
-# Provides: pvestatd
-# Required-Start: $remote_fs $network $syslog pve-cluster pvedaemon cman clvm
-# Required-Stop: $remote_fs $network $syslog pve-cluster pvedaemon cman clvm
-# Default-Start: 2 3 4 5
-# Default-Stop: 0 1 6
-# Short-Description: PVE Status Daemon
-### END INIT INFO
-
-. /lib/lsb/init-functions
-
-PATH=/sbin:/bin:/usr/bin:/usr/sbin
-NAME=pvestatd
-DAEMON=/usr/bin/pvestatd
-DESC="PVE Status Daemon"
-
-PIDFILE=/var/run/pvestatd.pid
-
-# Exit if the package is not installed
-test -f $DAEMON || exit 0
-[ -e /proxmox_install_mode ] && exit 0
-
-# avoid warnings about uninstalled locales
-export LC_ALL="C"
-
-case "$1" in
- start)
- log_daemon_msg "Starting $DESC" "$NAME"
- $DAEMON start
- log_end_msg $?
- ;;
- stop)
- log_daemon_msg "Stopping $DESC" "$NAME"
- $DAEMON stop
- log_end_msg $?
- ;;
- status)
- $DAEMON status
- ;;
- reload|restart|force-reload)
- log_daemon_msg "Restarting $DESC" "$NAME"
- $DAEMON restart
- log_end_msg $?
- ;;
- *)
- N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|status|reload|restart|force-reload}" >&2
- exit 1
- ;;
-esac
-
-exit 0
diff --git a/bin/init.d/spiceproxy b/bin/init.d/spiceproxy
deleted file mode 100755
index 5ddd61f0..00000000
--- a/bin/init.d/spiceproxy
+++ /dev/null
@@ -1,60 +0,0 @@
-#!/bin/sh
-
-### BEGIN INIT INFO
-# Provides: spiceproxy
-# Required-Start: $remote_fs $network $syslog pveproxy
-# Required-Stop: $remote_fs $network $syslog pveproxy
-# Default-Start: 2 3 4 5
-# Default-Stop: 0 1 6
-# Short-Description: PVE SPICE Proxy Server
-### END INIT INFO
-
-. /lib/lsb/init-functions
-
-PATH=/sbin:/bin:/usr/bin:/usr/sbin
-DAEMON=/usr/bin/spiceproxy
-NAME=spiceproxy
-DESC="PVE SPICE Proxy Server"
-RUNDIR=/var/run/pveproxy
-PIDFILE=${RUNDIR}/spiceproxy.pid
-
-test -f $DAEMON || exit 0
-
-# avoid warnings about uninstalled locales when pveproxy executes commands
-export LC_ALL="C"
-
-mkdir -p ${RUNDIR} || true
-chmod 0700 ${RUNDIR} || true
-chown www-data:www-data ${RUNDIR} || true
-
-DAEMON_OPTS=""
-
-# Include defaults if available
-if [ -f /etc/default/$NAME ] ; then
- . /etc/default/$NAME
-fi
-
-case "$1" in
- start)
- log_daemon_msg "Starting $DESC" "$NAME"
- $DAEMON start
- log_end_msg $?
- ;;
- stop)
- log_daemon_msg "Stopping $DESC" "$NAME"
- $DAEMON stop
- log_end_msg $?
- ;;
- restart|force-reload)
- log_daemon_msg "Restarting $DESC" "$NAME"
- $DAEMON restart
- log_end_msg $?
- ;;
- *)
- N=/etc/init.d/$NAME
- echo "Usage: $N {start|stop|restart|force-reload}"
- exit 1
- ;;
-esac
-
-exit 0
--
2.14.2
More information about the pve-devel
mailing list