{"id":317,"date":"1997-09-09T01:36:29","date_gmt":"1997-09-09T09:36:29","guid":{"rendered":"http:\/\/www.birdhouse.org\/betips\/?p=317"},"modified":"1997-09-09T01:36:29","modified_gmt":"1997-09-09T09:36:29","slug":"preparing-disk-images","status":"publish","type":"post","link":"https:\/\/www.betips.net\/?p=317","title":{"rendered":"Preparing disk images"},"content":{"rendered":"<p>Let&#8217;s say you want to create a disk image for burning to a CD. You need to create a filesystem within a BFS (<b>B<\/b>eOS <b>F<\/b>ile <b>S<\/b>ystem) file, mount it as a new volume, and copy all your stuff into it. Here&#8217;s how:<br \/>\nCreate a file with <code>dd<\/code>. In a Terminal type:<\/p>\n<pre>dd if=\/dev\/zero of=image.img bs=1024k count=640<\/pre>\n<p>Replace 640 with the size in megabytes you want the image to have. Then type:<\/p>\n<pre>mkbfs 2048 image.img; sync<\/pre>\n<p>This will create a filesystem in the file. It&#8217;s important to use a block size of 2048 bytes here, because BeOS can&#8217;t handle logical blocksizes that are smaller than the physical sectorsize of the device. Since CDs use 2048-byte sectors, you need to create 2048-byte blocks. &#8222;sync&#8220; needs to be called because otherwise you might get an error message when trying to mount it. Lastly, mount the image:<\/p>\n<pre>mkdir \/mnt; mount -t bfs image.img \/mnt<\/pre>\n<p>The (empty) &#8222;disk&#8220; will now appear on your desktop, and you can start copying stuff into it normally. When you&#8217;re done, unmount it and and burn <code>image.img<\/code> to a CD.<br \/>\n<b>Warning:<\/b> If you&#8217;re using BeOS R3, attempting to mount a file will lock up your system.<br \/>\nPeter Schultz (pete at beforever dot com) adds that you can also give the image a volume name while you&#8217;re creating it, or create the volume without an index. The complete mkbfs usage options are:<\/p>\n<pre>mkbfs [-noindex] [block_size] device_name [volumename]<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Let&#8217;s say you want to create a disk image for burning to a CD. You need to create a filesystem within a BFS (BeOS File System) file, mount it as a new volume, and copy all your stuff into it. Here&#8217;s how: Create a file with dd. In a Terminal type: dd if=\/dev\/zero of=image.img bs=1024k [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[13],"class_list":["post-317","post","type-post","status-publish","format-standard","hentry","tag-tracker"],"_links":{"self":[{"href":"https:\/\/www.betips.net\/index.php?rest_route=\/wp\/v2\/posts\/317","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.betips.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.betips.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.betips.net\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.betips.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=317"}],"version-history":[{"count":0,"href":"https:\/\/www.betips.net\/index.php?rest_route=\/wp\/v2\/posts\/317\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.betips.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=317"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.betips.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=317"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.betips.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=317"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}