richucj

manualflashlinux

Aug 14th, 2019
37
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.49 KB | None | 0 0
  1. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sudo umount /dev/sdc*
  2. umount: /dev/sdc: not mounted
  3. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sudo fdisk /dev/sdc
  4.  
  5. Command (m for help): p
  6.  
  7. Disk /dev/sdc: 15.9 GB, 15931539456 bytes
  8. 255 heads, 63 sectors/track, 1936 cylinders, total 31116288 sectors
  9. Units = sectors of 1 * 512 = 512 bytes
  10. Sector size (logical/physical): 512 bytes / 512 bytes
  11. I/O size (minimum/optimal): 512 bytes / 512 bytes
  12. Disk identifier: 0xf50387c3
  13.  
  14. Device Boot Start End Blocks Id System
  15. /dev/sdc1 2048 31115263 15556608 b W95 FAT32
  16.  
  17. Command (m for help): d
  18. Selected partition 1
  19.  
  20. Command (m for help): d
  21. No partition is defined yet!
  22.  
  23. Command (m for help): p
  24.  
  25. Disk /dev/sdc: 15.9 GB, 15931539456 bytes
  26. 255 heads, 63 sectors/track, 1936 cylinders, total 31116288 sectors
  27. Units = sectors of 1 * 512 = 512 bytes
  28. Sector size (logical/physical): 512 bytes / 512 bytes
  29. I/O size (minimum/optimal): 512 bytes / 512 bytes
  30. Disk identifier: 0xf50387c3
  31.  
  32. Device Boot Start End Blocks Id System
  33.  
  34. Command (m for help): n
  35. Partition type:
  36. p primary (0 primary, 0 extended, 4 free)
  37. e extended
  38. Select (default p): p
  39. Partition number (1-4, default 1): 1
  40. First sector (2048-31116287, default 2048):
  41. Using default value 2048
  42. Last sector, +sectors or +size{K,M,G} (2048-31116287, default 31116287): +1G
  43.  
  44. Command (m for help): n
  45. Partition type:
  46. p primary (1 primary, 0 extended, 3 free)
  47. e extended
  48. Select (default p): p
  49. Partition number (1-4, default 2): 2
  50. First sector (2099200-31116287, default 2099200):
  51. Using default value 2099200
  52. Last sector, +sectors or +size{K,M,G} (2099200-31116287, default 31116287):
  53. Using default value 31116287
  54.  
  55. Command (m for help): p
  56.  
  57. Disk /dev/sdc: 15.9 GB, 15931539456 bytes
  58. 255 heads, 63 sectors/track, 1936 cylinders, total 31116288 sectors
  59. Units = sectors of 1 * 512 = 512 bytes
  60. Sector size (logical/physical): 512 bytes / 512 bytes
  61. I/O size (minimum/optimal): 512 bytes / 512 bytes
  62. Disk identifier: 0xf50387c3
  63.  
  64. Device Boot Start End Blocks Id System
  65. /dev/sdc1 2048 2099199 1048576 83 Linux
  66. /dev/sdc2 2099200 31116287 14508544 83 Linux
  67.  
  68. Command (m for help): w
  69. The partition table has been altered!
  70.  
  71. Calling ioctl() to re-read partition table.
  72. Syncing disks.
  73. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sudo dd if=u-boot.imx of=/dev/sdc bs=512 seek=2 conv=fsync
  74. dd: failed to open ‘u-boot.imx’: No such file or directory
  75. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ cd binary/
  76. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo dd if=u-boot.imx of=/dev/sdc bs=512 seek=2 conv=fsync
  77. 918+0 records in
  78. 918+0 records out
  79. 470016 bytes (470 kB) copied, 0.10437 s, 4.5 MB/s
  80. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo mkfs.vfat /dev/sdc1
  81. mkfs.fat 3.0.26 (2014-03-07)
  82. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ cd mountpoint/
  83. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary/mountpoint$ ls
  84. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary/mountpoint$ sudo mount /dev/sdc1 mountpoint/
  85. mount: mount point mountpoint/ does not exist
  86. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary/mountpoint$ cd ../
  87. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo mount /dev/sdc1 mountpoint/
  88. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo cp zImage mountpoint/
  89. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo cp imx6q-sabreauto.dtb mountpoint/
  90. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo umount mountpoint/
  91. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ sudo mkfs.ext3 /dev/sdc2
  92. mke2fs 1.42.9 (4-Feb-2014)
  93. Filesystem label=
  94. OS type: Linux
  95. Block size=4096 (log=2)
  96. Fragment size=4096 (log=2)
  97. Stride=0 blocks, Stripe width=0 blocks
  98. 907536 inodes, 3627136 blocks
  99. 181356 blocks (5.00%) reserved for the super user
  100. First data block=0
  101. Maximum filesystem blocks=3716153344
  102. 111 block groups
  103. 32768 blocks per group, 32768 fragments per group
  104. 8176 inodes per group
  105. Superblock backups stored on blocks:
  106. 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208
  107.  
  108. Allocating group tables: done
  109. Writing inode tables: done
  110. Creating journal (32768 blocks): done
  111. Writing superblocks and filesystem accounting information: done
  112.  
  113. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu/binary$ cd ../
  114. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sudo mount /dev/sdc2 mountpoint/
  115. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sudo cp media/rootfs/* mountpoint/
  116. cp: omitting directory ‘media/rootfs/bin’
  117. cp: omitting directory ‘media/rootfs/boot’
  118. cp: omitting directory ‘media/rootfs/dev’
  119. cp: omitting directory ‘media/rootfs/etc’
  120. cp: omitting directory ‘media/rootfs/home’
  121. cp: omitting directory ‘media/rootfs/lib’
  122. cp: omitting directory ‘media/rootfs/media’
  123. cp: omitting directory ‘media/rootfs/mnt’
  124. cp: omitting directory ‘media/rootfs/opt’
  125. cp: omitting directory ‘media/rootfs/proc’
  126. cp: omitting directory ‘media/rootfs/root’
  127. cp: omitting directory ‘media/rootfs/run’
  128. cp: omitting directory ‘media/rootfs/sbin’
  129. cp: omitting directory ‘media/rootfs/srv’
  130. cp: omitting directory ‘media/rootfs/sys’
  131. cp: omitting directory ‘media/rootfs/tmp’
  132. cp: omitting directory ‘media/rootfs/usr’
  133. cp: omitting directory ‘media/rootfs/var’
  134. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sudo umount mountpoint/
  135. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$ sync
  136. BspDeveloper2@BspDeveloper2:~/NXP_ubuntu$
Add Comment
Please, Sign In to add comment