当前位置: 首页 > news >正文

北京都有那些做网站的公司百度指数排名明星

北京都有那些做网站的公司,百度指数排名明星,给企业做网站怎么收钱,短网址生成器是什么Yocto/OpenEmbedded使用的磁盘镜像格式是 wic。为嵌入式系统提供 bootable images。 The disk image format used in the Yocto Project is wic. .wic 文件显然只是一个带有分区表和分区的磁盘镜像,就像下载 Linux 发行版时获得的所有 .img 文件一样。这就是为什么你…

Yocto/OpenEmbedded使用的磁盘镜像格式是 wic。为嵌入式系统提供 bootable images。

The disk image format used in the Yocto Project is wic.

.wic 文件显然只是一个带有分区表和分区的磁盘镜像,就像下载 Linux 发行版时获得的所有 .img 文件一样。这就是为什么你可以使用 dd 命令烧写 .wic 文件,就像使用 .img 文件一样。

A .wic file is apparently just a disk image with a partition table and partitions, just like all the .img files you get when downloading e.g Linux distros. That's why you can flash a .wic file using dd just like you would with a .img file.

之所以使用 .wic 文件扩展名,是因为它是由 wic 工具创建的,该工具读取 .wks 文件中描述的分区布局,并生成带有相应分区的映像。有关 wic 工具的更多信息,请参阅: 19 Creating Partitioned Images Using Wic — The Yocto Project ® 5.0.1 documentation

The reason for the .wic file extension is simply that it's created by the wic tool, which reads a partition layout described in a .wks file and generates an image with the corresponding partitions. For more info on the wic tool, see:  19 Creating Partitioned Images Using Wic — The Yocto Project ® 5.0.1 documentation 

如何读取wic文件中的内容呢?

1,Mount the .wic File

将wic文件加载为loop device。

Automatically find an available loop device and associate it with a file.

$ sudo losetup -Pf --show my-image.wic

/dev/loop17

$ losetup --help

-a, --all                     list all used devices

-P, --partscan                create a partitioned loop device

-f, --find                    find first unused device

--show                    print device name after setup (with -f)

-d, --detach <loopdev>...     detach one or more devices

-D, --detach-all              detach all used devices

$ losetup -a

上面结果显示加载为/dev/loop17设备。

将设备名赋值给变量:

LOOP_DEVICE=$(sudo losetup -Pf --show my-image.wic)

2, List Partitions

使用fdisk命令,查看加载设备的分区信息

$ sudo fdisk -l /dev/loop17

Disk /dev/loop17: 7.11 GiB, 7638816768 bytes, 14919564 sectors

Units: sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 512 bytes

I/O size (minimum/optimal): 512 bytes / 512 bytes

Disklabel type: dos

Disk identifier: 0x076c4a2a

Device        Boot  Start      End  Sectors  Size Id Type

/dev/loop17p1 *     16384   186775   170392 83.2M  c W95 FAT32 (LBA)

/dev/loop17p2      196608 14919563 14722956    7G 83 Linux

3,Mount Partitions

sudo mount  /dev/loop17p1 mnt

4,Access Files

cd mnt

ls

5, Cleaning up

Unmount partitions:

sudo umount mnt

6, Detach the loop device

sudo losetup -d /dev/loop17


使用kpartx命令操作:

$ kpartx --help

-a add partition devmappings

-d del partition devmappings

-v verbose

-l list partitions devmappings that would be added by -a

$ sudo kpartx -av my-image.wic

[sudo] password for dev:

add map loop17p1 (252:0): 0 170392 linear 7:17 16384

add map loop17p2 (252:1): 0 14722956 linear 7:17 196608

$ sudo kpartx -l my-image.wic

loop17p1 : 0 170392 /dev/loop17 16384

loop17p2 : 0 14722956 /dev/loop17 196608

$ sudo kpartx -l /dev/loop17

loop17p1 : 0 170392 /dev/loop17 16384

loop17p2 : 0 14722956 /dev/loop17 196608

$ sudo fdisk -l /dev/loop17

Disk /dev/loop17: 7.11 GiB, 7638816768 bytes, 14919564 sectors

Units: sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 512 bytes

I/O size (minimum/optimal): 512 bytes / 512 bytes

Disklabel type: dos

Disk identifier: 0x076c4a2a

Device        Boot  Start      End  Sectors  Size Id Type

/dev/loop17p1 *     16384   186775   170392 83.2M  c W95 FAT32 (LBA)

/dev/loop17p2      196608 14919563 14722956    7G 83 Linux

$ ls /dev/mapper/

control  loop17p1  loop17p2

$ sudo mount /dev/mapper/loop17p2 mnt

$ sudo umount mnt

$ sudo kpartx -dv my-image.wic

del devmap : loop17p1

del devmap : loop17p2

loop deleted : /dev/loop17

$ sudo kpartx -dv /dev/loop17

del devmap : loop17p1

del devmap : loop17p2

参考:

linux - Difference between wic and hddimg format in yocto - Stack Overflow

http://www.mmbaike.com/news/25690.html

相关文章:

  • 电子商务网站规划建设与管理上海seo顾问推推蛙
  • 网站里可以增加网址吗百度官方营销推广平台加载中
  • 做期货网站可以推广的平台
  • 外贸是先做网站还是做阿里巴巴软件推广
  • 网站设计有哪些语言版本采集站seo提高收录
  • 青岛网站推广招商人工智能教育培训机构排名
  • 极速网站建设合肥网站关键词排名
  • 手机 网站模板淄博seo培训
  • 荥阳做网站优化怎么自己做一个网页
  • 温岭高端网站设计哪家好目前最新推广平台
  • 滨州正规网站建设价格江西省seo
  • 网站开发 java怎么申请域名建网站
  • 做乒乓球网站的图片大全跨境电商平台
  • 做网站应该学什么搜索关键词排名一般按照什么收费
  • 新蔡哪有做网站建设的全自动推广引流软件
  • 网站做压测淘宝客怎么做推广
  • 如何做电商网站首页南宁整合推广公司
  • 广州最新新闻事件今天网络排名优化软件
  • 江苏省质量建设厅网站微信公众号运营
  • b站怎么看视频分区谷歌seo关键词排名优化
  • 宿迁做网站多少钱竞价托管外包费用
  • 中国工信部网站备案百度旗下产品
  • 青岛模板网站建设价格济南优化网站的哪家好
  • 做网站英文编辑有前途吗品牌网络营销策划方案
  • 手机制作游戏软件宁波seo网络推广优质团队
  • dw网站怎么做点击图片放大域名注册信息查询
  • 李宁运动服网站建设规划书微信怎么做推广
  • 怎么做网站啊网站大全
  • 网站建设基本完成抖音seo排名系统哪个好用
  • 方案策划网站企业培训考试平台官网