I accidentally deleted /dev/loop special block device. Is it possible to recover it?


You can recreate the device with mknod:

sudo mknod -m 660 /dev/loop b 7 0

assuming that you don't have /dev/loop0 that already has taken that minor number (0)

  • the main problem is that ; I want to mount an iso image so I'm using that command (mount -t iso966 -o loop "iso image path" mount point) and it still doesn't recognize /dev/loop . U understand me ? – Asma Sarhan May 6 '15 at 11:23
  • @AsmaSarhan That is essentially a different problem. After creating the loop device with mknod use mount -t iso9660 -r -o loop "iso image path" /dev/loop. You need to do it read-only (-r) and your type was wrong (missing a 0) at the end. Post a new question if there are additional problems, including the exact command you use and error message. – Anthon May 6 '15 at 11:33
  • Can you explain how\why you used those parameters for mknod? – SailorCire May 6 '15 at 11:54
  • @SailorCire Yes I can. (I specify the parameters on the commandline) – Anthon May 6 '15 at 12:32

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.