i=0
for file in $hd_vfat
do
vfat_hd[i]=$file
let i="$i+1"
done
j=0
for file in $hd_ntfs
do
ntfs_hd[j]=$file
let j="$j+1"
done
I=0
while [ $I -lt $i ]
do
umount "${vfat_hd[$I]}"
vfat_mnt=`echo ${vfat_hd[$I]} | awk -F/ '{print $3}'`
mount -t vfat -o iocharset=cp936 "${vfat_hd[$I]}" "/mnt/$vfat_mnt"
let I="$I+1"
done
J=0
while [ $J -lt $j ]
do
umount "${ntfs_hd[$J]}"
ntfs_mnt=`echo ${ntfs_hd[$J]} | awk -F/ '{print $3}'`
mount -t ntfs -o iocharset=cp936 "${ntfs_hd[$J]}" "/mnt/$ntfs_mnt"
let J="$J+1"
done
[/code:1]
你没有复制错吧
直接运行看看