preremove.sh revision f902ede7eb073d09a81c1d470c089c7b14921714
af062818b47340eef15700d2f0211576ba3506eevboxsync#!/bin/sh
af062818b47340eef15700d2f0211576ba3506eevboxsync# innotek VirtualBox
af062818b47340eef15700d2f0211576ba3506eevboxsync# VirtualBox pre-remove script for Solaris Guest Additions.
af062818b47340eef15700d2f0211576ba3506eevboxsync#
af062818b47340eef15700d2f0211576ba3506eevboxsync# Copyright (C) 2008 innotek GmbH
af062818b47340eef15700d2f0211576ba3506eevboxsync#
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#
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsyncecho "innotek VirtualBox Guest Additions - preremove script"
af062818b47340eef15700d2f0211576ba3506eevboxsyncecho "This script will unload the VirtualBox Guest kernel module..."
af062818b47340eef15700d2f0211576ba3506eevboxsync
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync# stop and unregister VBoxService daemon
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync/usr/sbin/svcadm disable -s svc:/system/virtualbox/vboxservice:default
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync/usr/sbin/svccfg delete svc:/system/virtualbox/vboxservice:default
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync# vboxguest.sh would've been installed, we just need to call it.
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync/opt/VirtualBoxAdditions/vboxguest.sh stop
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync# Try and restore xorg.conf!
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsyncecho "Restoring Xorg..."
af062818b47340eef15700d2f0211576ba3506eevboxsync/opt/VirtualBoxAdditions/x11restore.pl
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsyncecho "Done."
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync