Commit 9097116e authored by Jim Harris's avatar Jim Harris Committed by Tomasz Zawadzki
Browse files

test/iscsi_tgt: add iptables entry to forward packets



Similar to commit 9035986e for the nvmf tests, we add
the same FORWARD entry here for iscsi_tgt tests.

Some distros or kernels do not automatically forward
packets across the bridge we set up in
create_veth_interfaces().  So add an iptables entry to
explicitly add a forwarding rule.

This allows me to run the iscsi_tgt tests in my
Ubuntu 22.04 VM.

Signed-off-by: default avatarJim Harris <james.r.harris@intel.com>
Change-Id: I9e48c10971bdf752e8bd83e5494f4a2a75b06ccd
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12161


Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarShuhei Matsumoto <smatsumoto@nvidia.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
parent aef71e29
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -75,6 +75,7 @@ function create_veth_interfaces() {

	# Accept connections from veth interface
	iptables -I INPUT 1 -i $INITIATOR_INTERFACE -p tcp --dport $ISCSI_PORT -j ACCEPT
	iptables -A FORWARD -i $ISCSI_BRIDGE -o $ISCSI_BRIDGE -j ACCEPT

	# Verify connectivity
	ping -c 1 $TARGET_IP