Skip to content
Bots!
Bots!
  • About
    • Myself
    • আমার দোয়া
  • Bookmarks
    • Bookmarks
    • My OCI Bookmarks
    • Useful Proxmox Commands & Links
    • Learning Nano
    • Useful Sites
    • Useful Virtualbox Command
    • Useful MySQL Command
    • Useful Linux Command
    • BTT-CAS
  • Resources
    • Webinar on Cloud Adoption for Project Managers
  • Photos
  • Videos
  • Downloads
Bots!

Configure iSCSI Initiator (client) in CentOS / RHEL 6

Rumi, October 30, 2018

To use RHEL/CentOS 6 system as an iSCSI initiator or client, you must have iscsi-initiator-utils package installed. You can verify that this is installed on your system using the rpm command, as shown in the following example:

$ rpm -qa | grep iscsi-initiator-utils

Install the package if its not already available on your system using yum.

# yum install iscsi-initiator-utils

Start the iscsi demaon and use chkconfig to enable it to start after reboot as well.

# service iscsi start
# chkconfig iscsi on

Once you have installed the required package and started the service you can start discovering the available targets. To Obtain a listing of available targets from a given host (please note that ipaddress listed below must be replaced with the resolvable hostname or IP address of the system providing the port if different than default):

# iscsiadm -m discovery -t st -p 192.168.10.10
192.168.10.10:3260,1 iqn.2010-03.com.example:tgtd

Here,
iqn.2010-03.com.example:tgtd – is the target_iqn_name.

You can view more information on the target using the below command.

# iscsiadm -m node -T [target_iqn_name] -p [target_ipaddress]

The next step is to login to the discovered target.

# iscsiadm -m node -T iqn.2010-03.com.example:tgtd -p 192.168.10.10 -l
Logging in to [iface: default, target: iqn.2010-03.com.example:tgtd, portal: 192.168.10.10,3260]
Login to [iface: default, target: iqn.2010-03.com.example:tgtd, portal: 192.168.10.10,3260]: successful

You can also login into all the LUNs exported on the target by running:

# iscsiadm -m discovery -t st -l

The iscsi initiator has it’s own database to save the target/node information and configuration. This is located in “/var/lib/iscsi” directory.

You can view the newly attached iSCSI storage using fdisk command.

# fdisk -l

To disconnect an existing iSCSI storage, you will have to first log out of the target.

# iscsiadm -m node -T [target_iqn_name] -p [ipaddress] -u

To remove the target from the iscsi database so that the iscsi does not reconnect upon reboot, delete the target after logging out of it:

# iscsiadm -m node -T target_iqn_name -p ip address --op delete

If you have multiple targets that you have logged into, you can log out of all targets by running:

# iscsiadm -m node -U all

Trouble Shooting

To get target list, run:

# iscsiadm -m discovery

To get the node list, run:

# iscsiadm -m node

The iscsid daemon opens a TCP session with the target. To check the open session, run:

# iscsiadm -m session
or
# netstat -tpan | grep iscsid

You can also check for the file /sys/class/iscsi_session to find open sessions.

Find which session a disk belongs to:

# iscsiadm -m session

The output will include active sessions and attached scsi disks.

For ZTE KU Storage integraion:

For ISCSI Discovery

# iscsiadm -m discovery -t sendtargets -p 10.10.10.211:3260
# iscsiadm -m discovery -t sendtargets -p 10.10.10.212:3260

( **this ip is the port IP where the optical fiber is connected)

To get the iqn number from blade: (need to enter in KU5200)

#yum install iscsi-initiator-utils

Next command is

# cat /etc/iscsi/initiatorname.iscsi
Administrations Configurations (Linux) CentOSCentOS 6iSCSI

Post navigation

Previous post
Next post

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Myself…

Hi, I am Hasan T. Emdad Rumi, an IT Project Manager & Consultant, Virtualization & Cloud Savvyfrom Dhaka, Bangladesh. I have prior experience in managing numerous local and international projects in the area of Telco VAS & NMC, National Data Center & PKI Naitonal Root and CA Infrastructure. Also engaged with several Offshore Software Development Team.

Worked with Orascom Telecom-Banglalink, Network Elites as VAS partner, BTRC, BTT (Turkey) , Mango Teleservices Limited and Access to Informaiton (A2I-UNDP)

Currently working at Oracle Corporation as Principal Technology Solution and Cloud Architect.

You can reach me [h.t.emdad at gmail.com] and I will be delighted to exchange my views.

Tags

Apache Bind Cacti CentOS CentOS 6 CentOS 7 Debain Debian Debian 10 Debian 11 Debian 12 DKIM Docker icinga iptables Jitsi LAMP Letsencrypt Linux Munin MySQL Nagios Nextcloud NFS nginx openvpn pfsense php Postfix Proxmox RDP Softether SSH SSL Ubuntu Ubuntu 16 Ubuntu 18 Ubuntu 20 Varnish virtualbox vpn Webmin Windows 10 XCP-NG zimbra

Topics

Recent Posts

  • KVM Cloud Capacity Planning Script (Enhanced) February 20, 2026
  • Youtube MP3 Downloader Script using AI February 14, 2026
  • Install Softether VPN and create a Destination NAT (D-NAT) Rule to access the private Client VPN Node on a Debian 12 OS February 14, 2026
  • Deploying Pulse Monitoring for Proxmox Cluster Ecosystem February 13, 2026
  • Technitium DNS Web UI Configuration for Primary-Secondary Name Servers February 12, 2026
  • Technitium DNS with Primary-Slave Installation on Debian February 12, 2026
  • Install Docker and Docker Compose in Debian 12 February 5, 2026
  • Install GUI on Debian 12 using CLI February 4, 2026
  • Configuring Multiple PHP Versions on Virtualmin January 30, 2026
  • Deploy a Container TIG (Telegraf, InfluxDB and Grafana) Stack January 24, 2026

Archives

Top Posts & Pages

  • KVM Cloud Capacity Planning Script (Enhanced)
©2026 Bots! | WordPress Theme by SuperbThemes