Public bug reported:

== Comment: #0 - Ping Tian Han <[email protected]> - 2016-10-25 02:01:23
==

---Problem Description---
The 'lsscsi -w' gives a wrong WWN:

% lsscsi -w | grep sda
[0:0:1:0]    disk    0x6005076304ffc4410000000000000  /dev/sda
% ls -l /dev/disk/by-id/ | grep 'wwn.*sda'
lrwxrwxrwx 1 root root  9 Oct 24 21:20 wwn-0x6005076304ffc4410000000000000096 
-> ../../sda
lrwxrwxrwx 1 root root 10 Oct 24 21:20 
wwn-0x6005076304ffc4410000000000000096-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Oct 24 21:20 
wwn-0x6005076304ffc4410000000000000096-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Oct 24 21:20 
wwn-0x6005076304ffc4410000000000000096-part3 -> ../../sda3
lrwxrwxrwx 1 root root 10 Oct 24 21:20 
wwn-0x6005076304ffc4410000000000000096-part4 -> ../../sda4
 
Contact Information = Ping Tian Han/[email protected] 
 
Machine Type = lpar 
 ---Debugger---
A debugger was configured, however the system did not enter into the debugger
 
Userspace tool common name: lsscsi 

Userspace rpm: 0.27-3
 
The userspace tool has the following bit modes: 64-bit 

Userspace tool obtained from project website:  na 
 
*Additional Instructions for Ping Tian Han/[email protected]: 
-Post a private note with access information to the machine that the bug is 
occuring on.
-Attach ltrace and strace of userspace application.

== Comment: #1 - VIPIN K. PARASHAR <[email protected]> - 2016-10-25 05:50:58 
==
lsscsi -w output
==========
[0:0:5:0]    disk    0x60050764008181941000000000000  /dev/sdad
[0:0:5:1]    disk    0x60050764008181941000000000000  /dev/sdae
[0:0:5:2]    disk    0x60050764008181941000000000000  /dev/sdaf
[0:0:5:3]    disk    0x60050764008181941000000000000  /dev/sdag
[0:0:5:4]    disk    0x60050764008181941000000000000  /dev/sdah

/dev/disk/by-id/ contents
===============
# ls -l /dev/disk/by-id/ | grep wwn | awk '{printf("%s %s %s\n", $9, $10, $11)}'
wwn-0x600507640081819410000000000001b1 -> ../../sdad
wwn-0x600507640081819410000000000001b2 -> ../../sdae
wwn-0x600507640081819410000000000001b3 -> ../../sdaf
wwn-0x600507640081819410000000000001b4 -> ../../sdag
wwn-0x600507640081819410000000000001b5 -> ../../sdah
# 

Last 3 digits of wwn id is getting tripped in lssscsi output.
This is causing wwn to differ. Its a bug in lsscsi code.

== Comment: #2 - VIPIN K. PARASHAR <[email protected]> - 2016-10-25 05:56:59 
==
Pull request with the fix reading  "Fix truncation of 128-bit wwn"
is already raised upstream at 

https://github.com/hreinecke/lsscsi/pull/1

== Comment: #3 - VIPIN K. PARASHAR <[email protected]> - 2016-10-25 06:06:38 
==
lsscsi binary created with fix prints full WWN
without any truncation.

# ./lsscsi -V
version: 0.28  2014/09/30 [svn: r120]
#

# ./lsscsi -w
[0:0:5:0]    disk    IBM      2145             0000  
0x600507640081819410000000000001b1  /dev/sdad
[0:0:5:1]    disk    IBM      2145             0000  
0x600507640081819410000000000001b2  /dev/sdae
[0:0:5:2]    disk    IBM      2145             0000  
0x600507640081819410000000000001b3  /dev/sdaf
[0:0:5:3]    disk    IBM      2145             0000  
0x600507640081819410000000000001b4  /dev/sdag
[0:0:5:4]    disk    IBM      2145             0000  
0x600507640081819410000000000001b5  /dev/sdah
#

# ls -l /dev/disk/by-id/wwn* | awk '{printf("%s %s %s\n", $9,$10,$11)}'
/dev/disk/by-id/wwn-0x600507640081819410000000000001b1 -> ../../sdad
/dev/disk/by-id/wwn-0x600507640081819410000000000001b2 -> ../../sdae
/dev/disk/by-id/wwn-0x600507640081819410000000000001b3 -> ../../sdaf
/dev/disk/by-id/wwn-0x600507640081819410000000000001b4 -> ../../sdag
/dev/disk/by-id/wwn-0x600507640081819410000000000001b5 -> ../../sdah
#

** Affects: lsscsi (Ubuntu)
     Importance: Undecided
     Assignee: Taco Screen team (taco-screen-team)
         Status: New


** Tags: architecture-ppc64le bugnameltc-147821 severity-high 
targetmilestone-inin1704

** Tags added: architecture-ppc64le bugnameltc-147821 severity-high
targetmilestone-inin1704

** Changed in: ubuntu
     Assignee: (unassigned) => Taco Screen team (taco-screen-team)

** Package changed: ubuntu => lsscsi (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1636467

Title:
  pVM:Ubuntu 16.10: lsscsi shows wrong wwn

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lsscsi/+bug/1636467/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to