9

I have an ISO image with a UDF filesystem and a boot sector and I need to add a file to it. When I do

sudo mount -o loop,rw /tmp/file.iso /tmp/dir

I get

mount: block device /tmp/file.iso is write-protected, mounting read-only

This happens even if I remove loop or add unhide. The file has permissions rw-rw-rw-. I have tried various UDF command-line tools, but they all demand an actual CD drive, and won't even work with the loopback device. So is there anything I can do?

Because this has a boot sector, I'd rather edit the ISO file directly than unpack/repack.

Using Kubuntu 14.04 here. Thanks.

andlabs
  • 473
  • 1
  • 5
  • 14

2 Answers2

1

I'm able to browse, add and delete files in an ISO file without unpacking/repacking it by simply opening it with the Archive Manager (Ubuntu 14.04).

Hopefully you can do the same using Kubuntu.

SNugues
  • 69
  • 6
  • Archive Manager is file-roller, right? Or has that changed? – andlabs Aug 08 '14 at 06:14
  • Yes that's it, Archive Manager is its new name (like Files for Nautilus...). – SNugues Aug 08 '14 at 06:28
  • 2
    It does not seem to be reading the UDF section of the disk image. All I see is a single folder `.` with nothing inside. This is both with the package and with a file-roller master build via jhbuild. – andlabs Aug 08 '14 at 15:35
  • For UDF images I only see a `README.TXT` saying "This disc contains a "UDF" file system and requires an operating system that supports the ISO-13346 "UDF" file system specification.". – Paul Sep 03 '20 at 13:43
-1

What you've done is somewhat correct, but you must login as a root user.

sudo su -

Create a mount point:

mkdir -p /mnt/<mount_name>

The use mount command as follows to mount ISO file .iso:

mount -o loop disk1.iso /mnt/<mount_name>

Change directory to list files stored inside an ISO image:

cd /mnt/<mount_name>
ls -l
Mitch
  • 106,657
  • 24
  • 210
  • 268
  • I did use sudo; the output of my original question was with sudo. Edited. – andlabs Aug 08 '14 at 15:36
  • See changes in my answer, try that, and please let me know. – Mitch Aug 09 '14 at 07:27
  • Still complains about write-protect. – andlabs Aug 09 '14 at 10:28
  • @Mitch Your `mount -o loop` command says : `mount: block device /tmp/toto.iso is write-protected, mounting read-only` – SebMa Jan 11 '19 at 14:10
  • @SebMa Just to clarify, you did use `sudo` right? – Mitch Jan 11 '19 at 14:29
  • @Mitch I tried both methods : with `sudo su -` then `mount -o loop` and I tried with `sudo mount -o loop`. Both methods said : `mount: block device /tmp/toto.iso is write-protected, mounting read-only` – SebMa Jan 11 '19 at 14:37
  • Try to install smbfs. `sudo apt install smbfs`, and then try that. – Mitch Jan 11 '19 at 19:44
  • This answer is plain wrong and weird. Iso9660 ain't really made to be editable. And the suggestion to install smbfs makes it even weirder. Smbfs is a network file system from Microsoft, and doesn't even make sense for physical disks. – vidarlo Feb 07 '23 at 07:16