vboxdrv.sh.in revision d766e56621531afa7cc104d93a53697d293f4bfb
af062818b47340eef15700d2f0211576ba3506eevboxsync# Sun xVM VirtualBox
af062818b47340eef15700d2f0211576ba3506eevboxsync# Linux kernel module init script
af062818b47340eef15700d2f0211576ba3506eevboxsync# Copyright (C) 2006-2007 Sun Microsystems, Inc.
af062818b47340eef15700d2f0211576ba3506eevboxsync# This file is part of VirtualBox Open Source Edition (OSE), as
af062818b47340eef15700d2f0211576ba3506eevboxsync# available from http://www.virtualbox.org. This file is free software;
af062818b47340eef15700d2f0211576ba3506eevboxsync# you can redistribute it and/or modify it under the terms of the GNU
af062818b47340eef15700d2f0211576ba3506eevboxsync# General Public License (GPL) as published by the Free Software
af062818b47340eef15700d2f0211576ba3506eevboxsync# Foundation, in version 2 as it comes in the "COPYING" file of the
af062818b47340eef15700d2f0211576ba3506eevboxsync# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
af062818b47340eef15700d2f0211576ba3506eevboxsync# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
af062818b47340eef15700d2f0211576ba3506eevboxsync# chkconfig: 35 30 60
af062818b47340eef15700d2f0211576ba3506eevboxsync# description: VirtualBox Linux kernel module
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync### BEGIN INIT INFO
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync# Provides: vboxdrv
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync# Required-Start: $syslog
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync# Required-Stop:
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync# Default-Start: 2 3 4 5
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync# Default-Stop: 0 1 6
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync# Short-Description: VirtualBox Linux kernel module
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync### END INIT INFO
af062818b47340eef15700d2f0211576ba3506eevboxsyncif [ -n "$INSTALL_DIR" ]; then
af062818b47340eef15700d2f0211576ba3506eevboxsync BUILDVBOXDRV="$INSTALL_DIR/src/vboxdrv/build_in_tmp"
af062818b47340eef15700d2f0211576ba3506eevboxsync BUILDVBOXNETFLT="$INSTALL_DIR/src/vboxnetflt/build_in_tmp"
af062818b47340eef15700d2f0211576ba3506eevboxsync BUILDVBOXDRV="/usr/share/%PACKAGE%/src/vboxdrv/build_in_tmp"
af062818b47340eef15700d2f0211576ba3506eevboxsync BUILDVBOXNETFLT="/usr/share/%PACKAGE%/src/vboxnetflt/build_in_tmp"
af062818b47340eef15700d2f0211576ba3506eevboxsyncif [ -n "$NOLSB" ]; then
af062818b47340eef15700d2f0211576ba3506eevboxsync[ -r /etc/default/%PACKAGE% ] && . /etc/default/%PACKAGE%
af062818b47340eef15700d2f0211576ba3506eevboxsyncif [ -z "$NOLSB" ]; then
rc_status -v
rc_status -v
sleep .2
if [ ! -c $DEVICE ]; then
MINOR=0
MAJOR=10
if ! chown :$GROUPNAME $DEVICE 2>/dev/null; then
rmmod vboxnetflt 2>/dev/null
if ! modprobe vboxnetflt > /dev/null 2>&1; then
if running vboxnetflt; then
if ! rmmod vboxnetflt 2>/dev/null; then
for i in $SHUTDOWN_USERS; do
if ! $BUILDVBOXDRV \
if ! $BUILDVBOXNETFLT \
--use-module-symvers /tmp/vboxdrv-Module.symvers \
if running vboxnetflt; then
for i in $SHUTDOWN_USERS; do
stop && start