mirror of
https://github.com/superconvert/smart-os.git
synced 2024-11-22 18:20:30 +08:00
Delete cat_disk.sh
This commit is contained in:
parent
6ae72c6914
commit
8b74261570
21
cat_disk.sh
21
cat_disk.sh
@ -1,21 +0,0 @@
|
||||
loop_dev=$(losetup -f)
|
||||
|
||||
# fdisk -l disk.img 查看 start 为 2048, unit 512 所以 -o 偏移扇区 1048576 = 2048 x 512
|
||||
losetup -o 1048576 ${loop_dev} disk.img
|
||||
|
||||
# 挂载磁盘到本地目录
|
||||
mkdir -p ./mnt1
|
||||
mount -t ext3 ${loop_dev} ./mnt1
|
||||
echo "/ ---------------------------------------"
|
||||
ls ./mnt1/
|
||||
echo "boot ---------------------------------------"
|
||||
ls ./mnt1/boot
|
||||
echo "sbin ---------------------------------------"
|
||||
ls ./mnt1/sbin
|
||||
echo "etc ---------------------------------------"
|
||||
ls ./mnt1/etc
|
||||
echo "dev ---------------------------------------"
|
||||
ls ./mnt1/dev
|
||||
umount ./mnt1
|
||||
rm -rf mnt1
|
||||
losetup -d ${loop_dev}
|
Loading…
Reference in New Issue
Block a user