Installation guide
Logging In to an iSCSI Target
139
Using our previous example (where proper_target_name is equallogic-iscsi1), the full
command would be:
iscsiadm --mode node --targetname \ iqn.2001-05.com.equallogic:6-8a0900-
ac3fe0101-63aff113e344a4a2-dl585-03-1 \ --portal 10.16.41.155:3260,0 --
login
7
21.13. Logging In to an iSCSI Target
As mentioned in Section 21.2, “iSCSI”, the iSCSI service must be running in order to discover or log
into targets. To start the iSCSI service, run:
service iscsi start
When this command is executed, the iSCSI init scripts will automatically log into targets where the
node.startup setting is configured as automatic. This is the default value of node.startup for
all targets.
To prevent automatic login to a target, set node.startup to manual. To do this, run the following
command:
iscsiadm -m node --targetname proper_target_name -p target_IP:port -o
update -n node.startup -v manual
Deleting the entire record will also prevent automatic login. To do this, run:
iscsiadm -m node --targetname proper_target_name -p target_IP:port -o
delete
To automatically mount a file system from an iSCSI device on the network, add a partition entry for
the mount in /etc/fstab with the _netdev option. For example, to automatically mount the iSCSI
device sdb to /mount/iscsi during startup, add the following line to /etc/fstab:
/dev/sdb /mnt/iscsi ext3 _netdev 0 0
To manually log in to an iSCSI target, use the following command:
iscsiadm -m node --targetname proper_target_name -p target_IP:port -l
Note
The proper_target_name and target_IP:port refer to the full name and IP address/
port combination of a target. For more information, refer to Section 21.2.1, “iSCSI API” and
Section 21.12, “ Scanning iSCSI Interconnects”.
21.14. Resizing an Online Logical Unit
In most cases, fully resizing an online logical unit involves two things: resizing the logical unit itself
and reflecting the size change in the corresponding multipath device (if multipathing is enabled on the
system).
To resize the online logical unit, start by modifying the logical unit size through the array management
interface of your storage device. This procedure differs with each array; as such, consult your storage
array vendor documentation for more information on this.