KVM test: Unattended install: Mount isos as read only
Sometimes CD images can be located on read only NFS shares,
so allways pass the ro option to the CD mount command
on the unattended.py setup script.
Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
git-svn-id: http://test.kernel.org/svn/autotest/trunk@3880 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/client/tests/kvm/scripts/unattended.py b/client/tests/kvm/scripts/unattended.py
index febea6e..2667649 100755
--- a/client/tests/kvm/scripts/unattended.py
+++ b/client/tests/kvm/scripts/unattended.py
@@ -136,8 +136,8 @@
pxe_dest = os.path.join(self.tftp_root, 'pxelinux.0')
shutil.copyfile(pxe_file, pxe_dest)
- m_cmd = 'mount -t iso9660 -v -o loop %s %s' % (self.cdrom_iso,
- self.cdrom_mount)
+ m_cmd = 'mount -t iso9660 -v -o loop,ro %s %s' % (self.cdrom_iso,
+ self.cdrom_mount)
if os.system(m_cmd):
raise SetupError('Could not mount CD image %s.' % self.cdrom_iso)