summaryrefslogtreecommitdiffstats
path: root/vboxdrv
diff options
context:
space:
mode:
Diffstat (limited to 'vboxdrv')
-rwxr-xr-xvboxdrv19
1 files changed, 19 insertions, 0 deletions
diff --git a/vboxdrv b/vboxdrv
new file mode 100755
index 0000000..6cf3400
--- /dev/null
+++ b/vboxdrv
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+case "$1" in
+ start)
+ find -L /lib/modules/`uname -r` -name "vbox*" | while read module; do
+ modprobe $(basename $module ".ko.gz")
+ done
+ ;;
+ stop)
+ find -L /lib/modules/`uname -r` -name "vbox*" | while read module; do
+ rmmod $(basename $module ".ko") 2>/dev/null
+ done
+ find -L /lib/modules/`uname -r` -name "vbox*" | while read module; do
+ rmmod $(basename $module ".ko") 2>/dev/null
+ done
+ ;;
+ *)
+ echo "usage: $0 {start|stop}"
+esac