Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

debugfs command not found

When I try to use debugfs on my Macbook pro(10.6.8) I get

-bash: debugfs: command not found

Then I try to look at my path

echo $PATH

I get

/opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/usr/local/git/bin:/usr/texbin:/usr/X11/bin

which seems pretty much everything.

Where is my debugfs command? How can I reinstall it?

like image 637
user1781270 Avatar asked Oct 28 '12 18:10

user1781270


2 Answers

There is no debugfs(8) on Mac OS X. Debugfs(8) is a Linux program used to debug the Linux file system ext2/ext3. If you want to debug a Mac filesystem like HFS+ try fsck(8) or use Disk Utility.

If you really want to debug a Linux ext2/ext3 filesystem on a Mac (e.g. an external Linux USB disk) you will have to install ext2/3 first. Since you have /opt/local/bin in your path I suppose you have MacPorts installed. In this case you could just install the packet ext2fuse which includes the debugfs(8) program.

like image 93
Mackie Messer Avatar answered Nov 15 '22 05:11

Mackie Messer


You can install e2fsprogs, including debugfs, using Homebrew on OsX.

brew install e2fsprogs

You will find debugfs in /usr/local/opt/e2fsprogs/sbin/debugfs

like image 25
Davide Guerri Avatar answered Nov 15 '22 05:11

Davide Guerri