Changeset 36688 in vbox for trunk/src/VBox/Installer
- Timestamp:
- Apr 15, 2011 4:48:33 PM (14 years ago)
- Location:
- trunk/src/VBox/Installer/linux
- Files:
-
- 1 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Installer/linux/Makefile.kmk
r35463 r36688 5 5 6 6 # 7 # Copyright (C) 2006-201 0Oracle Corporation7 # Copyright (C) 2006-2011 Oracle Corporation 8 8 # 9 9 # This file is part of VirtualBox Open Source Edition (OSE), as … … 48 48 deffiles \ 49 49 routines.sh \ 50 vboxballoonctrl-service.sh \ 50 51 vboxdrv.sh \ 51 52 vboxweb-service.sh \ … … 54 55 $(wildcard $(VBOX_LNX_INST_OUT_DIR)/VirtualBox-*) \ 55 56 $(addprefix $(VBOX_LNX_INST_OUT_DIR)/,\ 57 vboxballoonctrl-service.sh \ 56 58 vboxdrv.sh \ 57 59 vboxweb-service.sh \ … … 118 120 $(if $(VBOX_WITH_GUEST_CONTROL),VBoxGuestControlSvc.so,) \ 119 121 $(if $(VBOX_WITH_MAIN), \ 122 VBoxBalloonCtrl \ 120 123 VBoxManage \ 121 124 VBoxNetDHCP $(if $(VBOX_WITH_HARDENING),VBoxNetDHCP.so,) \ … … 298 301 $(VBOX_PATH_LNX_INST_SRC)/deffiles \ 299 302 $(if $(VBOX_OSE),,$(VBOX_BRAND_LICENSE_TXT)) \ 303 $(VBOX_LNX_INST_OUT_DIR)/vboxballoonctrl-service.sh \ 300 304 $(VBOX_LNX_INST_OUT_DIR)/vboxdrv.sh \ 301 305 $(VBOX_LNX_INST_OUT_DIR)/vboxweb-service.sh \ … … 312 316 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LNX_INST_SRC)/deffiles $(VBOX_LNX_INST_STAGE_DIR)/ 313 317 $(QUIET)$(if $(VBOX_OSE),,$(INSTALL) -m 0644 $(VBOX_BRAND_LICENSE_TXT) $(VBOX_LNX_INST_STAGE_DIR)/LICENSE) 318 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_INST_OUT_DIR)/vboxballoonctrl-service.sh $(VBOX_LNX_INST_STAGE_DIR)/ 314 319 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_INST_OUT_DIR)/vboxdrv.sh $(VBOX_LNX_INST_STAGE_DIR)/ 315 320 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_INST_OUT_DIR)/vboxweb-service.sh $(VBOX_LNX_INST_STAGE_DIR)/ … … 322 327 323 328 # files that needs editing before they can be included in the generic installer. 329 $(VBOX_LNX_INST_OUT_DIR)/vboxballoonctrl-service.sh: $(VBOX_PATH_LNX_INST_SRC)/vboxballoonctrl-service.sh.in | $$(dir $$@) 330 $(QUIET)$(SED_EXT) \ 331 -e "s|%NOLSB%|yes|g" \ 332 -e "s|%DEBIAN%||g" \ 333 -e "s|%PACKAGE%|virtualbox|g" \ 334 --output $@ \ 335 $< 336 324 337 $(VBOX_LNX_INST_OUT_DIR)/vboxdrv.sh: $(VBOX_PATH_LNX_INST_SRC)/vboxdrv.sh.in | $$(dir $$@) 325 338 $(QUIET)$(SED_EXT) \ -
trunk/src/VBox/Installer/linux/vboxballoonctrl-service.sh.in
r36685 r36688 1 1 #!/bin/sh 2 2 # 3 # VirtualBox web service APIdaemon init script.3 # VirtualBox balloon control daemon init script. 4 4 # 5 5 # Copyright (C) 2006-2011 Oracle Corporation … … 15 15 16 16 # chkconfig: 35 35 65 17 # description: VirtualBox web service API17 # description: VirtualBox balloon control daemon 18 18 # 19 19 ### BEGIN INIT INFO 20 # Provides: vbox web-service20 # Provides: vboxballoonctrl-service 21 21 # Required-Start: vboxdrv 22 22 # Required-Stop: vboxdrv 23 23 # Default-Start: 2 3 4 5 24 24 # Default-Stop: 0 1 6 25 # Description: VirtualBox web service API25 # Description: VirtualBox balloon control daemon 26 26 ### END INIT INFO 27 27 … … 34 34 35 35 if [ -n "$INSTALL_DIR" ]; then 36 binary="$INSTALL_DIR/ vboxwebsrv"36 binary="$INSTALL_DIR/VBoxBalloonCtrl" 37 37 else 38 binary="/usr/lib/%PACKAGE%/ vboxwebsrv"38 binary="/usr/lib/%PACKAGE%/VBoxBalloonCtrl" 39 39 fi 40 40 … … 48 48 if [ -f /etc/redhat-release ]; then 49 49 system=redhat 50 PIDFILE="/var/lock/subsys/vbox web-service"50 PIDFILE="/var/lock/subsys/vboxballoonctrl-service" 51 51 elif [ -f /etc/SuSE-release ]; then 52 52 system=suse 53 PIDFILE="/var/lock/subsys/vbox web-service"53 PIDFILE="/var/lock/subsys/vboxballoonctrl-service" 54 54 elif [ -f /etc/debian_version ]; then 55 55 system=debian 56 PIDFILE="/var/run/vbox web-service"56 PIDFILE="/var/run/vboxballoonctrl-service" 57 57 elif [ -f /etc/gentoo-release ]; then 58 58 system=gentoo 59 PIDFILE="/var/run/vbox web-service"59 PIDFILE="/var/run/vboxballoonctrl-service" 60 60 elif [ -f /etc/arch-release ]; then 61 61 system=arch 62 PIDFILE="/var/run/vbox web-service"62 PIDFILE="/var/run/vboxballoonctrl-service" 63 63 elif [ -f /etc/slackware-version ]; then 64 64 system=slackware 65 PIDFILE="/var/run/vbox web-service"65 PIDFILE="/var/run/vboxballoonctrl-service" 66 66 elif [ -f /etc/lfs-release ]; then 67 67 system=lfs 68 PIDFILE="/var/run/vbox web-service.pid"68 PIDFILE="/var/run/vboxballoonctrl-service.pid" 69 69 else 70 70 system=other 71 71 if [ -d /var/run -a -w /var/run ]; then 72 PIDFILE="/var/run/vbox web-service"72 PIDFILE="/var/run/vboxballoonctrl-service" 73 73 fi 74 74 fi … … 276 276 check_single_user() { 277 277 if [ -n "$2" ]; then 278 fail_msg "VBOX WEB_USER must not contain multiple users!"278 fail_msg "VBOXBALLOONCTRL_USER must not contain multiple users!" 279 279 exit 1 280 280 fi … … 283 283 start() { 284 284 if ! test -f $PIDFILE; then 285 [ -z "$VBOX WEB_USER" ] && exit 0286 begin_msg "Starting VirtualBox webservice";287 check_single_user $VBOX WEB_USER285 [ -z "$VBOXBALLOONCTRL_USER" ] && exit 0 286 begin_msg "Starting VirtualBox balloon control service"; 287 check_single_user $VBOXBALLOONCTRL_USER 288 288 vboxdrvrunning || { 289 289 fail_msg "VirtualBox kernel module not loaded!" … … 291 291 } 292 292 PARAMS="--background" 293 [ -n "$VBOXWEB_HOST" ] && PARAMS="$PARAMS -H $VBOXWEB_HOST" 294 [ -n "$VBOXWEB_PORT" ] && PARAMS="$PARAMS -p $VBOXWEB_PORT" 295 [ -n "$VBOXWEB_TIMEOUT" ] && PARAMS="$PARAMS -t $VBOXWEB_TIMEOUT" 296 [ -n "$VBOXWEB_CHECK_INTERVAL" ] && PARAMS="$PARAMS -i $VBOXWEB_CHECK_INTERVAL" 297 [ -n "$VBOXWEB_THREADS" ] && PARAMS="$PARAMS -T $VBOXWEB_THREADS" 298 [ -n "$VBOXWEB_KEEPALIVE" ] && PARAMS="$PARAMS -k $VBOXWEB_KEEPALIVE" 299 [ -n "$VBOXWEB_LOGFILE" ] && PARAMS="$PARAMS -F $VBOXWEB_LOGFILE" 300 [ -n "$VBOXWEB_ROTATE" ] && PARAMS="$PARAMS -R $VBOXWEB_ROTATE" 301 [ -n "$VBOXWEB_LOGSIZE" ] && PARAMS="$PARAMS -S $VBOXWEB_LOGSIZE" 302 [ -n "$VBOXWEB_LOGINTERVAL" ] && PARAMS="$PARAMS -I $VBOXWEB_LOGINTERVAL" 293 [ -n "$VBOXBALLOONCTRL_INTERVAL" ] && PARAMS="$PARAMS --interval $VBOXBALLOONCTRL_INTERVAL" 294 [ -n "$VBOXBALLOONCTRL_INCREMENT" ] && PARAMS="$PARAMS --balloon-inc $VBOXBALLOONCTRL_INCREMENT" 295 [ -n "$VBOXBALLOONCTRL_DECREMENT" ] && PARAMS="$PARAMS --balloon-dec $VBOXBALLOONCTRL_DECREMENT" 296 [ -n "$VBOXBALLOONCTRL_LOWERLIMIT" ] && PARAMS="$PARAMS --balloon-lower-limit $VBOXBALLOONCTRL_LOWERLIMIT" 297 [ -n "$VBOXBALLOONCTRL_ROTATE" ] && PARAMS="$PARAMS - $VBOXBALLOONCTRL_ROTATE" 298 [ -n "$VBOXBALLOONCTRL_LOGSIZE" ] && PARAMS="$PARAMS -S $VBOXBALLOONCTRL_LOGSIZE" 299 [ -n "$VBOXBALLOONCTRL_LOGINTERVAL" ] && PARAMS="$PARAMS -I $VBOXBALLOONCTRL_LOGINTERVAL" 303 300 # prevent inheriting this setting to VBoxSVC 304 301 unset VBOX_RELEASE_LOG_DEST 305 start_daemon $VBOX WEB_USER $binary $PARAMS > /dev/null 2>&1302 start_daemon $VBOXBALLOONCTRL_USER $binary $PARAMS > /dev/null 2>&1 306 303 # ugly: wait until the final process has forked 307 304 sleep .1 … … 321 318 stop() { 322 319 if test -f $PIDFILE; then 323 begin_msg "Stopping VirtualBox webservice";320 begin_msg "Stopping VirtualBox balloon control service"; 324 321 killproc $binary 325 322 RETVAL=$? … … 339 336 340 337 status() { 341 echo -n "Checking for VBox Web Service"338 echo -n "Checking for VBox balloon control service" 342 339 if [ -f $PIDFILE ]; then 343 340 echo " ...running"
Note:
See TracChangeset
for help on using the changeset viewer.