Load iSCSI target in LXC Container

fahadshery

Member
Feb 13, 2021
131
8
23
42
Hi,

I have an iSCSI target in TrueNAS CORE. I can easily mount in an ubuntu VM.
However, I am unable to do so in LXC container.
Here is what it shows after installing the open-iscsi package in ubuntu 20.04 LXC container

Code:
sudo systemctl status open-iscsi
* open-iscsi.service - Login to default iSCSI targets
     Loaded: loaded (/lib/systemd/system/open-iscsi.service; enabled; vendor preset: enabled)
     Active: inactive (dead)
  Condition: start condition failed at Sun 2021-05-23 09:44:48 BST; 2s ago
             |- ConditionDirectoryNotEmpty=|/etc/iscsi/nodes was not met
             `- ConditionDirectoryNotEmpty=|/sys/class/iscsi_session was not met
       Docs: man:iscsiadm(8)
             man:iscsid(8)

May 23 09:43:33 fuse-lxc systemd[1]: Condition check resulted in Login to default iSCSI targets being skipped.

Is it even possible to load it in LXC container or do I have to install a VM?

Thanks