░▒▓████████████████████████████████▓▒░ ░▒▓█ ▓▒░ ░▒▓█ ~ S W A M P ~ ▓▒░ ░▒▓█ ▓▒░ ░▒▓████████████████████████████████▓▒░
pplmvsvm
LOCATION:
/opt/microsoft/dependency-agent
☗ ROOT
↻ REFRESH
✎ CARVE FLESH
EDITING: uninstall
#!/bin/sh # # ********************************************************************* # # Copyright (C) 2023 Microsoft. All rights reserved. # # This software is the intellectual property of Microsoft, Inc., # and contains confidential information and trade secrets of # Microsoft, Inc. It is protected by United States and # international copyright law and/or international treaties. # Unauthorized use, reproduction or distribution of the software, or # any portion of it, may result in severe civil and criminal # penalties, and will be prosecuted to the maximum extent possible # under the law. # # ********************************************************************* # preuninstall() { local waited /etc/init.d/microsoft-dependency-agent stop if [ -x /usr/lib/lsb/remove_initd ]; then # SuSE /usr/lib/lsb/remove_initd /etc/init.d/microsoft-dependency-agent elif [ -x /sbin/chkconfig ]; then # RHEL /sbin/chkconfig --del microsoft-dependency-agent elif [ -x /usr/sbin/update-rc.d ]; then # Ubuntu update-rc.d -f microsoft-dependency-agent remove else # other rm -f /etc/rc.d/rc?.d/???microsoft-dependency-agent fi waited=0 while lsmod | grep -q bluechannel; do if /sbin/rmmod bluechannel 2> /dev/null; then break; fi sleep 1 if [ ${waited} = 20 ]; then break; fi waited=$((${waited}+1)) done if lsmod | grep -q bluechannel 2> /dev/null; then [ -f /dev/bluechannel ] && chmod 000 /dev/bluechannel echo Unable to unload the Dependency Agent bluechannel module. if which fuser >/dev/null; then if [ ${?} -eq 0 ]; then echo "The module is still in use." fuser -v /dev/bluechannel fi fi fi [ -f /etc/opt/microsoft/dependency-agent/config/DependencyAgentIdentity.dat ] && \ cp /etc/opt/microsoft/dependency-agent/config/DependencyAgentIdentity.dat /etc/MicrosoftDependencyAgent-saved-identity.dat rm -f /etc/opt/microsoft/dependency-agent/config/*.new rm -rf /var/opt/microsoft/dependency-agent/log/* if [ -x /var/opt/microsoft/dependency-agent/storage ]; then find /var/opt/microsoft/dependency-agent/storage -type f -print0 | xargs -0 rm -f fi /opt/microsoft/dependency-agent/lib/scripts/connector.sh -u rm -f /opt/microsoft/dependency-agent/bin/python } BSERR_UNINSTALL_SUCCESS=0 BSERR_UNINSTALL_DPKG_OUT_OF_TIME=11 BSERR_UNINSTALL_DPKG_LOCKED=12 # Deprecated BSERR_UNINSTALL_DPKG_NOT_REMOVED=13 BSERR_UNINSTALL_DPKG_NOT_REMOVED_FORCE=14 BSERR_UNINSTALL_DPKG_NOT_LOCKED=15 BSERR_UNINSTALL_RPM_PKG_NOT_FOUND=30 BSERR_UNINSTALL_RPM_DBREBUILD_FAILED=31 BSERR_UNINSTALL_RPM_E_FAILED=32 now() { echo ${SECONDS:-`date +"%s"`} } # If there is a need to retry anything, give up if it # has been more than 4.5 minutes (default) since the script # started. # Can be overridden with the environment variable MAX_RETRY_SECONDS. start_time=`now` run_limit=`expr $start_time + ${MAX_RETRY_SECONDS:-270}` # 4 min 30 sec remove_pkg() { while : ; do dpkg --purge $1 2>&1 && return 0 if ! fuser /var/lib/dpkg/lock-frontend /var/lib/dpkg/lock > /dev/null 2>&1; then return $BSERR_UNINSTALL_DPKG_NOT_LOCKED fi if [ `now` -ge $run_limit ]; then # exit if time limit elapsed exit $BSERR_UNINSTALL_DPKG_OUT_OF_TIME fi sleep 15 done } preuninstall # Assume success status=$BSERR_UNINSTALL_SUCCESS # Need to use dkms to remove the module before removing the DA if [ -n "`dkms status -m microsoft-dependency-agent`" ]; then dkms remove -m microsoft-dependency-agent -v "9.10.18" --all status=$? if [ $status -ne 0 ]; then echo dkms remove error: $status fi fi pkgs="dependency-agent" # remove Agent packages for pkg in $pkgs; do if dpkg --status $pkg > /dev/null 2>&1; then remove_pkg $pkg if dpkg --status $pkg > /dev/null 2>&1; then echo "$pkg did not uninstall cleanly, doing force uninstall" dpkg --purge --force-depends $pkg 2>&1 if dpkg --status $pkg > /dev/null 2>&1; then echo "$pkg did not uninstall (force) cleanly, doing more forceful uninstall" dpkg --purge --force-depends,remove-reinstreq $pkg 2>&1 if dpkg --status $pkg 2>&1; then echo "$pkg did not uninstall (force aggressive) cleanly". status=$BSERR_UNINSTALL_DPKG_NOT_REMOVED fi fi fi fi done if [ $status -ne 0 ]; then # Extreme measures to recover from broken installs if dpkg --status dependency-agent > /dev/null 2>&1; then if test -f /var/lib/dpkg/info/dependency-agent.prerm; then echo "Trying to recover from a bad install ... " rm /var/lib/dpkg/info/dependency-agent.prerm remove_pkg dependency-agent status=$? for pkg in $pkgs; do if dpkg --status $pkg 2>&1; then status=$BSERR_UNINSTALL_DPKG_NOT_REMOVED_FORCE fi done if [ $status -eq 0 ]; then echo "Success!" else echo "Failed" fi fi fi fi exit $status
CANCEL
Name
Type
Size
Modified
Actions
↩ ..
DIR
—
—
📁 bin/
DIR
—
2026-03-10 17:09
📁 driver/
DIR
—
2023-11-30 04:08
📁 lib/
DIR
—
2023-11-30 04:08
📄 NOTICE.txt
TXT
39.7 KB
2023-11-01 09:12
EDIT
📄 uninstall
?
5.3 KB
2023-11-01 09:12
EDIT