Transclusion: CL-SOM-iMX7: Linux: Manual Installation: Install Images

From Compulab Mediawiki
Jump to: navigation, search
  • Unmount all eMMC partitions:
root@cl-ramdisk:~# umount -l /dev/mmcblk2p*
  • Clean up the on the eMMC flash:
root@cl-ramdisk:~# dd if=/dev/zero of=/dev/mmcblk2 bs=1M count=1
root@cl-ramdisk:~# hdparm -z /dev/mmcblk2
  • Create two partitions for the Linux kernel (EXT2 100M) and root file system (EXT4 the rest of the disk) on the eMMC flash:
root@cl-ramdisk:~# echo -e "n\np\n1\n\n+100M\nn\np\n2\n\n\nw\neof\n" | fdisk /dev/mmcblk2
  • Format the first partition with EXT2 file system:
root@cl-ramdisk:~# mkfs.ext2 -L boot /dev/mmcblk2p1
  • Format the second partition with EXT4 file system:
root@cl-ramdisk:~# mkfs.ext4 -L rootfs /dev/mmcblk2p2
  • Mount both partitions:
root@cl-ramdisk:~# mkdir -p /media/boot && mount /dev/mmcblk2p1 /media/boot
root@cl-ramdisk:~# mkdir -p /media/rootfs && mount /dev/mmcblk2p2 /media/rootfs
  • Copy zImage and imx7d-*imx7.dtb to the first (EXT2) partition:
root@cl-ramdisk:~# cp /mnt/install/zImage /mnt/install/imx7d-*.dtb /media/boot && sync
  • Extract the content of rootfs.tar.bz2 onto the second partition:
root@cl-ramdisk:~# tar --numeric-owner -xpf /mnt/install/rootfs.tar.bz2 -C /media/rootfs && sync
  • Unmount both partitions:
root@cl-ramdisk:~# umount /dev/mmcblk2p1
root@cl-ramdisk:~# umount /dev/mmcblk2p2