Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Basically I have binary image of NTFS partition made with WinHex. WinHex is able to open such files and show directory structure, besides hex editing. Is there tool with similar capabilities on Ubuntu Linux?

share|improve this question
I solved the issue with WinHEX under Wine :) That's because I was not able to correctly mount my partition image - it was not recognized correctly. But WinHEX handled it very well. If you need, I can provide error messages etc. – Gill Bates Jul 17 '13 at 15:15
WinHex is catastrophic under Wine...when I go in as regular user, OpenDisk works but I have no permission to open the disk. When I go in as root, the Open Disk window does not appear and the whole application is blocked. – syntaxerror Dec 1 '14 at 0:52

Not sure about about a tool like WinHex, but you can mount a binary image of the partition by doing the following:

If sda.img is the binary image file, then...

Get the partition layout of the image

$ sudo fdisk -lu sda.img
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
  Device Boot      Start         End      Blocks   Id  System
sda.img1   *          56     6400000     3199972+   c  W95 FAT32 (LBA)

Calculate the offset from the start of the image to the partition start

Sector size * Start = (in the case) 56 * 512 = 28672 

Mount it on /dev/loop0 using the offset

sudo losetup -o 28672 /dev/loop0 sda.img

Now the partition resides on /dev/loop0. You can fsck it, mount it etc

sudo fsck -fv /dev/loop0
sudo mount /dev/loop0 /mnt


sudo umount /mnt
sudo losetup -d /dev/loop0
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .