<p>UPDATE &#8211; Chris Gibson pointed out that with AIX 6.1 you can use a loopback device like Linux.</p>
<p>I recently heard someone discuss how to handle ISO images on AIX.  On Linux, you can mount the ISO image as a filesystem, which is pretty slick. </p>
<p>Starting in AIX 6.1, you can use the loopmount command to create a loopback device and mount an ISO directly:</p>
<pre><code>loopmount -i <i>cdrom.iso</i> -o “-V cdrfs -o ro” -m <i>/mnt</i></code></pre>
<p>And, loopumount unmounts the ISO and removes the loopback device:</p>
<pre><code>loopumount -i <i>cdrom.iso</i> -o "<i>/mnt</i>"</code></pre>
<p>There are a couple of gotcha&#8217;s, but nothing unusual.  An ISO can only be associated with one loopback device at a time, the mount is only readonly, and it&#8217;s not supported in WPARs.</p>
<p>But, AIX previous to 6.1 doesn&#8217;t support mounting ISO images directly.  The recommendation was to mount the ISO as a virtual optical drive on the VIOS.  But, I don&#8217;t use VIOS because it hasn&#8217;t gained uptake in our environment and with our vendors.  You can always burn the image and mount the CD, but if your optical drive is tied up on another LPAR you may not be able to move the optical drive to the right LPAR.</p>
<p>There is another way to mount those images, but it&#8217;s not a one-step process.  What you need to do is create a LV at least as big as your ISO image, then copy the ISO data to that LV, and then mount the LV:</p>
<pre><code>mklv -y cdlv -s n rootvg 704M hdisk0
dd if=<i>cdrom.iso</i> of=/dev/cdlv
mount -v cdrfs -o ro /dev/cdlv /mnt</code</pre>
{"id":525,"date":"2010-08-18T16:23:17","date_gmt":"2010-08-18T20:23:17","guid":{"rendered":"http:\/\/patrickv.info\/wordpress\/?p=525"},"modified":"2010-08-18T16:23:17","modified_gmt":"2010-08-18T20:23:17","slug":"mounting-iso-images-on-aix","status":"publish","type":"post","link":"https:\/\/rootuser.ninja\/index.php\/2010\/08\/18\/mounting-iso-images-on-aix\/","title":{"rendered":"Mounting ISO Images On AIX"},"content":{"rendered":"<p>UPDATE &#8211; Chris Gibson pointed out that with AIX 6.1 you can use a loopback device like Linux.<\/p>\n<p>I recently heard someone discuss how to handle ISO images on AIX.  On Linux, you can mount the ISO image as a filesystem, which is pretty slick. <\/p>\n<p>Starting in AIX 6.1, you can use the loopmount command to create a loopback device and mount an ISO directly:<\/p>\n<pre><code>loopmount -i <i>cdrom.iso<\/i> -o \u201c-V cdrfs -o ro\u201d -m <i>\/mnt<\/i><\/code><\/pre>\n<p>And, loopumount unmounts the ISO and removes the loopback device:<\/p>\n<pre><code>loopumount -i <i>cdrom.iso<\/i> -o \"<i>\/mnt<\/i>\"<\/code><\/pre>\n<p>There are a couple of gotcha&#8217;s, but nothing unusual.  An ISO can only be associated with one loopback device at a time, the mount is only readonly, and it&#8217;s not supported in WPARs.<\/p>\n<p>But, AIX previous to 6.1 doesn&#8217;t support mounting ISO images directly.  The recommendation was to mount the ISO as a virtual optical drive on the VIOS.  But, I don&#8217;t use VIOS because it hasn&#8217;t gained uptake in our environment and with our vendors.  You can always burn the image and mount the CD, but if your optical drive is tied up on another LPAR you may not be able to move the optical drive to the right LPAR.<\/p>\n<p>There is another way to mount those images, but it&#8217;s not a one-step process.  What you need to do is create a LV at least as big as your ISO image, then copy the ISO data to that LV, and then mount the LV:<\/p>\n<pre><code>mklv -y cdlv -s n rootvg 704M hdisk0\ndd if=<i>cdrom.iso<\/i> of=\/dev\/cdlv\nmount -v cdrfs -o ro \/dev\/cdlv \/mnt<\/code<\/pre>\n","protected":false},"excerpt":{"rendered":null,"protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,1],"tags":[],"class_list":["post-525","post","type-post","status-publish","format-standard","hentry","category-aix-notes","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/posts\/525","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/comments?post=525"}],"version-history":[{"count":0,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/posts\/525\/revisions"}],"wp:attachment":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/media?parent=525"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/categories?post=525"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/tags?post=525"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}