1# ======检查是否以sudo运行================= 2uid=`id -u` 3if [ ! $uid == "0" ];then 4 echo "请以sudo权限运行" 5 exit 6fi 7 8LOOP_DEVICE=$(lsblk | grep disk_mount) 9 10LOOP_DEVICE=${LOOP_DEVICE:2:10} 11LOOP_DEVICE=${LOOP_DEVICE%%p1*} 12 13umount -f ../bin/disk_mount/ 14losetup -d /dev/$LOOP_DEVICE 15echo $LOOP_DEVICE 16