From 64a7eace88b30f3ea03df86ddceb23d4949b692d Mon Sep 17 00:00:00 2001
From: Harald Hoyer <harald@redhat.com>
Date: Wed, 31 Jul 2013 17:28:04 +0200
Subject: [PATCH] cms/cmssetup.sh: correct port for zfcp.conf
---
modules.d/80cms/cmssetup.sh | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/modules.d/80cms/cmssetup.sh b/modules.d/80cms/cmssetup.sh
index 16704c3..36955bc 100755
--- a/modules.d/80cms/cmssetup.sh
+++ b/modules.d/80cms/cmssetup.sh
@@ -182,7 +182,19 @@ function dasd_settle_all() {
unset _do_zfcp
for i in ${!FCP_*}; do
- echo "${!i}" >> /etc/zfcp.conf
+ echo "${!i}" | while read port rest; do
+ case $port in
+ *.*.*)
+ ;;
+ *.*)
+ port="0.$port"
+ ;;
+ *)
+ port="0.0.$port"
+ ;;
+ esac
+ echo $port $rest >> /etc/zfcp.conf
+ done
_do_zfcp=1
done
[[ $_do_zfcp ]] && zfcp_cio_free