CentOS 7 PCS Cluster iSCSI Target does not gracefully Stop

I have configured an iSCSI HA cluster using DRBD, Pacemaker, and Corosync. I am using the tgt implementation and am using CentOS 7. I attempted to use the LIO-T implementation, however, the write performance using LIO was 3 times lower than TGT for some reason. After some googling on that issue, I learned that LIO has apparently not yet been fully performance tuned and there are some issues if certain settings do not match perfectly between initiator and target.

Anyway, onto my issue...

If I attempt to "gracefully" move the iSCSI resources and/or put one of the nodes into Standby mode to gracefully move the nodes that way, it ends up being a nightmare with a lot of pcs resource cleanups needing to be issues to eventually get the Iscsitarget resources to stop.

After running pcs resource debug-stop (and also combing the corosync log file), the issue appears that tgtadm which I understand pcs calls on the backend to shutdown the target, does not release the target because of existing iSCSI initiator connections that are established to the target. Exact output is:

> stderr: tgtadm: this target is still active
> stderr: WARNING: Failed to remove target <target iqn>, retrying.
> stderr: tgtadm: this target is still active
> stderr: WARNING: Failed to remove target <target iqn>, retrying.
> stderr: tgtadm: this target is still active
> stderr: WARNING: Failed to remove target <target iqn>, retrying.
> stderr: tgtadm: this target is still active
> stderr: WARNING: Failed to remove target <target iqn>, retrying.
> stderr: tgtadm: this target is still active

The stop fails, the resource goes into a failed state and then I am forced to run cleanup to eventually force the resource to stop to move over. This obviously is far from ideal and takes away significantly the HA of the solution as the process takes long enough to cause my initiator connections to drop and need to be manually reconnected.

Is there something in my configuration that I am missing to force tgtadm to immediately close any connections? How should this situation be handled?

If it matters, the initiators connecting are all Microsoft Windows Server 2016 iSCSI initiators.

Any assistance in resolving this would be greatly appreciated.
dcapone2004Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.