NAME

sdloop, addloop, sdusb – loopback storage device interface

SYNOPSIS

bind –a #S /dev
echo config switch on spec
l type loop/path[[!sectors]!sectsize] >/dev/sdctl
/dev/sd
l0/ctl
/dev/sd
l0/raw
/dev/sd
l0/data
...
addloop letter unit
usbsd

DESCRIPTION

Sdloop allows a file to be used as a sd device. By specifying a number of sectors, the device may be be a different size than the file. To configure /tmp/data as sdl0: with a 1024–byte sector size
echo config switch on spec l type loop//tmp/data!1024 >/dev/sdctl
To turn this device off,
echo config switch off spec l >/dev/sdctl
The configuration variable loopdev may be specified in plan9.ini(8) to configure a loopback sd device at boot. For example
loopdev=l!/tmp/data!1024
The script addloop automates the process of adding loopback targets To replace the example above,
addloop l /tmp/data
The usbsd script allows USB disks to be used as sd devices, and automatically partitions them. Drive letters are assigned starting with `u' for compatability with the boot process.

SOURCE

/sys/src/9/port/sdloop.c
/rc/bin/addloop

SEE ALSO

sd(3), sdaoe(3), 9load(8),

BUGS

Maybe.