To create a BFS image from the terminal you need to do two steps. First you need to create a raw imagefile and the second is to initialitze the imagefile with the bfs filesystem.
To create the raw imagefile open the terminal and run following command:
dd if=/dev/zero of="Path/to/imagefile/filename" bs=1024 count="File size"
With the command dd and the information if=/dev/zero we create a raw imagefile at position (of=) " Path/to/imagefile/filename". With bs we set the blocksize for the imagefile (BeOS standard 1024). At count=Filesize we set the size of the imagefile in kilobyte.
Past this we initialitze the bfs filesystem to the imagefile:
mkbfs 2048 "Path/to/imagefile/filename"
We use the command mkbfs (make BFS) with the information of the blockzie (2048) and the imagefile we want to initialitze.
Finaly we run the command sync and the bfs image is ready.
To use this imagefile we mount it with the command mount. Before we can do this we create a temporary folder in order to mout the imagefile into it.
mount -t bfs "Path/to/imagefile/filename /mnt
We create the temporarie folder with mkdir /mnt (you can name this folder as you like). Then we mount the image file into the temporary folder (/mnt).
Finaly you can use this mounted imagefile like a harddrive.
To unmount the imagefile you can do it like every other hardrive using the right mouse menu unmount or you type into the terminal:
mountvolume -unmount /Name of Harddrive
If you want to know more about mounting and unmounting over the terminal you can take a look at this Tutorial.
Made available by BeSly, the BeOS, ZETA and HAIKU Knowledgebase.