4

I am trying to access an image file in my code, but my code is telling that it does not exist. However, listing the directory where the image is I can see it, but I got the following strange output when showing its permissions:

??????????   ? ?       ?         ?            ? class3705.png

I also cannot see it using Nautilus in the folder.

When I try to change its permissions I have the following error:

chmod 644 class3705.png
chmod: cannot access `class3705.png': Invalid argument

I even cannot copy it to another place to change its permissions, it returns me the following error:

cp: cannot stat `class3705.png': Invalid argument

It never happened to me before and I really don't want to erase this file because I don't know if it is the only one with this error. Is there any other way to recover this file?

EDIT: here you can see the ls ls and chmod enter image description here

  • 1
  • 1
    Not a duplicate because he is not trying to change a directory . and @OP can you give output of ls command ? – rɑːdʒɑ Dec 29 '15 at 7:16
  • @Raja ls shows class3705.png but ls -la shows ?????????? ? ? ? ? ? class3705.png – Anselmo Ferreira Dec 29 '15 at 7:18
  • 1
    do this in your terminal , cd ..;chmod -R 755 ./* and try again. – rɑːdʒɑ Dec 29 '15 at 7:21
  • when I tried to change the permission of the whole directory where the image is I got the error chmod: cannot access `H225BIS11.tif/class3705.png': Invalid argument – Anselmo Ferreira Dec 29 '15 at 7:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.