Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

i'm thinking about installing and setting up iscsitarget on my Debian squeeze box. so far, the examples i saw on various Google searches and the debian wiki: http://wiki.debian.org/SAN/iSCSI/iscsitarget

set the path to unmounted devices like /dev/sda1 or /dev/sda. is it possible to set the path to a folder on a mounted filesystem instead? like: /home/iscsi_target

share|improve this question
up vote 3 down vote accepted

No, it is not possible. iSCSI exports a whole disk over the network for another machine to access directly, using its own filesystem drivers. A directory is not a disk.

If you want to share files and directories, then you need to use a network filesystem, like NFS or CIFS/Samba.

share|improve this answer
thanks after doing further research, it came clear to me that iscsi is not capable of directory read/write. i'll stick to my smb and ftp shares – godMode Jul 18 '11 at 16:09

Typically things that ask for a device node like /dev/sda1 are looking to read/write a block device instead of a file node. A directory in a mounted filesystem is an entirely different kind of object than a block device node.

Sometimes things that would normally operate on a device can operate on a file. For example various file formats like iso and dmg are basically "images" of block devices saved in a file on some host file system that can have their own file system structures inside them. Some software knows how to deal with these kind of "files".

There do seem to be some notes about fileio vs blockio in on the site you link, although it the documentation is far from complete. That might be something to look into.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.