mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
ziomon/ziorep_traffic: disambiguate paths with device bus-ID
Add device bus-ID to ziorep_traffic output for better distinguishing
of paths in setups, which have paths in the same pathgroup with same
WWPN and LUN.
Output without device bus-ID column:
$ ziorep_traffic log
WWPN LUN ...
...
2019-10-21 11:44:38
0x50050763071bc5e3:0x4006404f00000000 ...
0x50050763071bc5e3:0x4006404f00000000 ...
Output with device bus-ID column:
$ ziorep_traffic log
DEVBUSID WWPN LUN ...
...
2019-10-21 11:44:38
0.0.1980:0x50050763071bc5e3:0x4006404f00000000 ...
0.0.19c0:0x50050763071bc5e3:0x4006404f00000000 ...
After patch application device bus-ID can also be seen in detailed
(with -D option) output and in CSV output format (with -x option).
Also adjust output headings correspondingly.
Signed-off-by: Fedor Loshakov <loshakov@linux.ibm.com>
Reviewed-by: Steffen Maier <maier@linux.ibm.com>
Reviewed-by: Benjamin Block <bblock@linux.ibm.com>
Reviewed-by: Sakshi Singh <005c7w@linux.ibm.com>
Reviewed-by: M Nikhil <nikh1092@linux.ibm.com>
Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
This commit is contained in:
committed by
Jan Höppner
parent
d3b7581669
commit
638f0aa4f9
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* Utility classes to print framsets
|
||||
*
|
||||
* Copyright IBM Corp. 2008, 2021
|
||||
* Copyright IBM Corp. 2008, 2024
|
||||
*
|
||||
* s390-tools is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the MIT license. See LICENSE for details.
|
||||
@@ -638,9 +638,9 @@ void TrafficPrinter::print_topline_prefix1(FILE *fp)
|
||||
switch (m_agg_crit) {
|
||||
case none:
|
||||
if (m_csv)
|
||||
str = "WWPN,LUN";
|
||||
str = "DEVBUSID,WWPN,LUN";
|
||||
else
|
||||
str = " WWPN LUN ";
|
||||
str = "DEVBUSID WWPN LUN ";
|
||||
break;
|
||||
case chpid:
|
||||
if (m_csv)
|
||||
@@ -677,7 +677,7 @@ void TrafficPrinter::print_topline_prefix2(FILE *fp)
|
||||
|
||||
switch (m_agg_crit) {
|
||||
case none:
|
||||
str = " ";
|
||||
str = " ";
|
||||
break;
|
||||
case chpid:
|
||||
str = " ID";
|
||||
@@ -705,7 +705,7 @@ void TrafficPrinter::print_topline_whitespace(FILE *fp)
|
||||
|
||||
switch (m_agg_crit) {
|
||||
case none:
|
||||
str = " ";
|
||||
str = " ";
|
||||
break;
|
||||
case chpid:
|
||||
str = " ";
|
||||
@@ -788,12 +788,16 @@ void TrafficPrinter::print_device_mp_mm(FILE *fp, __u32 mp_mm,
|
||||
void TrafficPrinter::print_device(FILE *fp, __u32 dev,
|
||||
const ConfigReader &cfg, int *rc)
|
||||
{
|
||||
__u32 devno = cfg.get_devno_by_mm_internal(dev, rc);
|
||||
|
||||
print_device_devno(fp, devno);
|
||||
|
||||
if (m_csv)
|
||||
fprintf(fp, "0x%016Lx,0x%016Lx",
|
||||
fprintf(fp, ",0x%016Lx,0x%016Lx",
|
||||
(long long unsigned int)cfg.get_wwpn_by_mm_internal(dev, rc),
|
||||
(long long unsigned int)cfg.get_lun_by_mm_internal(dev, rc));
|
||||
else
|
||||
fprintf(fp, "0x%016Lx:0x%016Lx",
|
||||
fprintf(fp, ":0x%016Lx:0x%016Lx",
|
||||
(long long unsigned int)cfg.get_wwpn_by_mm_internal(dev, rc),
|
||||
(long long unsigned int)cfg.get_lun_by_mm_internal(dev, rc));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user