如何在android上挂载linux分区?

时间:2013-11-15 11:03:25

标签: android mount partition

如何在android上安装分区2?文件系统是ext2。大小是8 GB,在这个分区上安装了Linux Ububuntu 13.04 PL。我收到错误Device busy。我做错了什么?

控制台中的详细信息:

app_149@android:/ $ su
root@android:/ # mount
rootfs / rootfs rw,relatime 0 0
tmpfs /dev tmpfs rw,nosuid,relatime,mode=755 0 0
devpts /dev/pts devpts rw,relatime,mode=600 0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,relatime 0 0
none /acct cgroup rw,relatime,cpuacct 0 0
tmpfs /mnt/asec tmpfs rw,relatime,mode=755,gid=1000 0 0
tmpfs /mnt/obb tmpfs rw,relatime,mode=755,gid=1000 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
/dev/block/mtdblock0 /system yaffs2 rw,relatime 0 0
/dev/block/mtdblock2 /data yaffs2 rw,nosuid,nodev,relatime 0 0
/dev/block/mtdblock1 /cache yaffs2 rw,nosuid,nodev,relatime 0 0
/dev/block/mtdblock3 /system/vendor yaffs2 ro,relatime 0 0
/dev/block/mmcblk0p2 /data/sdext2 vfat rw,relatime,uid=1000,gid=1000,fmask=0133,dmask=0002,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro 0 0
/dev/block/vold/179:1 /mnt/sdcard vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:1 /mnt/secure/asec vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
tmpfs /mnt/sdcard/.android_secure tmpfs ro,relatime,size=0k,mode=000 0 0
root@android:/ # fdisk /dev/bloc/mmcblk0

The number of cylinders for this disk is set to 3880.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
   (e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): p

Disk /dev/block/mmcblk0: 31.9 GB, 31914983424 bytes
255 heads, 63 sectors/track, 3880 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

              Device Boot      Start         End      Blocks  Id System
/dev/block/mmcblk0p1               1        2315    18594213+  b Win95 FAT32
/dev/block/mmcblk0p2   *        2316        3359     8385930  83 Linux
/dev/block/mmcblk0p3            3360        3880     4184932+  e Win95 FAT16 (LBA)

Command (m for help):
root@android:/ # mkdir /mnt/linux
mkdir failed for /mnt/linux, File exists
255|root@android:/ # rmdir /mnt/linux
root@android:/ # mkdir /mnt/linux
root@android:/ # mount -t ext2 /dec/block/mmcblk0p2 /mnt/linux
mount: No such file or directory
255|root@android:/ # mount -t ext2 /dev/block/mmcblk0p2 /mnt/linux
mount: Device or resource busy
255|root@android:/ # mount -t linux /dev/block/mmcblk0p2 /mnt/linux
mount: No such device
255|root@android:/ #

1 个答案:

答案 0 :(得分:1)

你无法装载已装载的东西:

/dev/block/mmcblk0p2 /data/sdext2 vfat rw,relatime,uid=1000,gid=1000,fmask=0133,dmask=0002,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro 0 0

/dev/block/mmcblk0p2 - already mounted in /data/sdext2