3

I would like to see what the actual contents of a directory file are (not the files that are contained within that directory).

Specifically I would like to be able to do something like:

od -c .

I know this works (used to work?) on unix, as it is shown on page 59 of 'The Unix Programming Environment'

Yet when I attempt on my version of Arch Linux I get the following:

read error: Is a directory

Is there another command I should be using to inspect the bytes of a directory?

Jordan
  • 243
  • 1
    IIRC in the book "Linux Systems Programming", it is explained that the Linux kernel does not allow direct reads on directories. – jordanm Feb 13 '15 at 18:26
  • @jordanm that would explain my problem. I shall read into it more from that book. Thanks – Jordan Feb 13 '15 at 18:28

0 Answers0