From ISCSI clients, we execute # systemctl start iscsi
. However, i can see there is another service called iscsid.
Can anybody explain about iscsi service vs iscsid service in rhel7.?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.
Sign up to join this communityiscsid
is the daemon (system service) that runs in the background, acting on iSCSI configuration, and managing the connections. From its manpage:
The iscsid implements the control path of iSCSI protocol, plus some management facilities. For example, the daemon could be configured to automatically re-start discovery at startup, based on the contents of persistent iSCSI database.
The iscsi
service that you can start with systemctl start iscsi
is really just a shell script. It automatically starts iscsid
, but then goes on to log into the targets you have marked for automatic login. Starting the iscsi
service is what you want to do.
# systemctl enable iscsid
Jul 16, 2015 at 1:39
iscsid
, it also brings up the sessions that are marked for automatic start. You should be able to do systemctl enable iscsi
to get it to start at boot.
Jul 16, 2015 at 14:01
After doing some reading and some practices this is how i think iscsi differs from iscsid.
In a system that acting as iSCSI initiator, there are two particular iscsi services running. One is "iscsi service" and other is "iscsid service".
where, iscsid is the daemon that runs in the background while acting on iSCSI configuration and managing the connections.
On the otherhand, iscsi job is to execute its main config file - locate @ /etc/iscsi/iscsi.conf, which of course helps to brings the iscsi related sockets. As a part of that it also brings the iscsi targets those are set in /etc/iscsi/initiatorname.iscsi
. However, this only gonna happen if it set "node.startup = automatic"
in its main config file.
However, it also important to run the below commands once as that will create necessary files under /var/lib/iscsi/nodes/ - which holds iscsi specific target related information that is used by iscsid daemon
to access the targets;
$ iscsiadm --mode discoverydb --type sendtargets --portal 192.168.5.81 --discover
$ iscsiadm --mode node --targetname iqn.2015-09.com.example:tgt1 --portal 192.168.5.81:3260 --login