1, get offset
# parted bone-debian-8.7-lxqt-4gb-armhf----4gb.img
GNU Parted 3.1
Using /workspace/bone-debian-8.7-lxqt-4gb-armhf----4gb.img
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) p
Model: (file)
Disk /workspace/bone-debian-8.7-lxqt-4gb-armhf----4gb.img: 3565MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: Number Start End Size Type File system Flags
4194kB 3565MB 3561MB primary ext4 boot (parted) unit B
(parted) p
Model: (file)
Disk /workspace/bone-debian-8.7-lxqt-4gb-armhf----4gb.img: 3565158400B
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: Number Start End Size Type File system Flags
4194304B 3565158399B 3560964096B primary ext4 boot (parted)
get the ext4 partation offset 4194304
or u can use fdisk:
fdisk -l /workspace/bone-debian-8.7-lxqt-4gb-armhf----4gb.img Disk /workspace/bone-debian-8.7-lxqt-4gb-armhf----4gb.img: MB, bytes, sectors
Units = sectors of * = bytes
Sector size (logical/physical): bytes / bytes
I/O size (minimum/optimal): bytes / bytes
Disk label type: dos
Disk identifier: 0xca52207f Device Boot Start End Blocks Id System
/workspace/bone-debian-8.7-lxqt-4gb-armhf----4gb.img1 * Linux
the offset is 8192(sectors) * 512 = 4194304 Byte
2,mount
mount -o loop,ro,offset= bone-debian-8.7-lxqt-4gb-armhf----4gb.img /mnt/