move iscsi_ibft and iscsi_boot_sysfs to -virtual kernel

Bug #1511006 reported by Scott Moser
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Medium
Tim Gardner
Wily
Fix Released
Undecided
Tim Gardner
Xenial
Fix Released
Medium
Tim Gardner

Bug Description

Calling iscsi ibft a 'virtual' thing is a bit questionable.

That said, I was looking at ibft using qemu and ipxe. The cloud images do not have the iscsi_ibft module included, so you can't read the information out of /sys/firmware/ibft until you have it.

Given a iscsi target at 192.168.1.131::3260:1:mytest (format is described at http://etherboot.org/wiki/sanboot/iscsi_boot) with a cloud image populated (or other bootable data) you can boot from that via:

qemu-system-x86_64 -enable-kvm -m 1024 -curses \
   -kernel /usr/lib/ipxe/ipxe.lkrn -append 'dhcp && sanboot iscsi:192.168.1.131::3260:1:mytest'

The ipxe.lkrn file is in the 'ipxe' package, and tested above on wily.

If the open-iscsi package is installed in the image and the modules available, in the initramfs you can then do:

(initramfs) modprobe iscsi_ibft
[ 11.444414] iBFT detected.
(initramfs) cat /sys/firmware/ibft/target0/nic-assoc
0
(initramfs) cat /sys/firmware/ibft/target0/target-name
mytest
(initramfs) cat /sys/firmware/ibft/target0/port
3260
(initramfs) cat /sys/firmware/ibft/ethernet0/mac
52:54:00:12:34:56
(initramfs) for x in /sys/class/net/*/address; do echo $x; cat $x; done
/sys/class/net/eth0/address
52:54:00:12:34:56
/sys/class/net/lo/address
00:00:00:00:00:00

Related bugs:
 * bug 1511008: add open-iscsi to cloud image

ProblemType: Bug
DistroRelease: Ubuntu 15.10
Package: linux-image-4.2.0-16-generic 4.2.0-16.19
ProcVersionSignature: User Name 4.2.0-16.19-generic 4.2.3
Uname: Linux 4.2.0-16-generic x86_64
AlsaDevices:
 total 0
 crw-rw---- 1 root audio 116, 1 Oct 27 14:58 seq
 crw-rw---- 1 root audio 116, 33 Oct 27 14:58 timer
AplayDevices: Error: [Errno 2] No such file or directory: 'aplay'
ApportVersion: 2.19.1-0ubuntu4
Architecture: amd64
ArecordDevices: Error: [Errno 2] No such file or directory: 'arecord'
AudioDevicesInUse: Error: command ['fuser', '-v', '/dev/snd/seq', '/dev/snd/timer'] failed with exit code 1:
CRDA: N/A
Date: Wed Oct 28 15:50:04 2015
Ec2AMI: ami-00000661
Ec2AMIManifest: FIXME
Ec2AvailabilityZone: nova
Ec2InstanceType: m1.small
Ec2Kernel: unavailable
Ec2Ramdisk: None
IwConfig: Error: [Errno 2] No such file or directory: 'iwconfig'
Lsusb: Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
MachineType: OpenStack Foundation OpenStack Nova
PciMultimedia:

ProcEnviron:
 TERM=screen
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcFB:

ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.2.0-16-generic root=LABEL=cloudimg-rootfs ro console=tty1 console=ttyS0
RelatedPackageVersions:
 linux-restricted-modules-4.2.0-16-generic N/A
 linux-backports-modules-4.2.0-16-generic N/A
 linux-firmware N/A
RfKill: Error: [Errno 2] No such file or directory: 'rfkill'
SourcePackage: linux
UdevLog: Error: [Errno 2] No such file or directory: '/var/log/udev'
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 04/01/2014
dmi.bios.vendor: SeaBIOS
dmi.bios.version: 1.7.5-20150310_111955-batsu
dmi.chassis.type: 1
dmi.chassis.vendor: QEMU
dmi.chassis.version: pc-i440fx-utopic
dmi.modalias: dmi:bvnSeaBIOS:bvr1.7.5-20150310_111955-batsu:bd04/01/2014:svnOpenStackFoundation:pnOpenStackNova:pvr2015.1.1:cvnQEMU:ct1:cvrpc-i440fx-utopic:
dmi.product.name: OpenStack Nova
dmi.product.version: 2015.1.1
dmi.sys.vendor: OpenStack Foundation

Revision history for this message
Scott Moser (smoser) wrote :
Scott Moser (smoser)
description: updated
Revision history for this message
Brad Figg (brad-figg) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
tags: added: kernel-da-key
Changed in linux (Ubuntu):
importance: Undecided → Medium
Tim Gardner (timg-tpi)
Changed in linux (Ubuntu Wily):
assignee: nobody → Tim Gardner (timg-tpi)
status: New → In Progress
Changed in linux (Ubuntu Xenial):
assignee: nobody → Tim Gardner (timg-tpi)
status: Confirmed → In Progress
Brad Figg (brad-figg)
Changed in linux (Ubuntu Wily):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (32.9 KiB)

This bug was fixed in the package linux - 4.2.0-19.23

---------------
linux (4.2.0-19.23) wily; urgency=low

  [ Luis Henriques ]

  * Release Tracking Bug
    - LP: #1515157

  [ Andy Whitcroft ]

  * [Config] re-enable OSS support and blacklist
    - LP: #1434842

  [ dann frazier ]

  * Revert "[Config] CONFIG_ARM64_ERRATUM_843419=n"
    - LP: #1502946

  [ Paolo Pisati ]

  * [SRU] [Config] armhf: LEDS_TRIGGER_HEARTBEAT=y
    - LP: #1510165

  [ Tim Gardner ]

  * [Config] Add iscsi_ibft and iscsi_boot_sysfs to generic inclusion list
    - LP: #1511006
  * [Config] CONFIG_AUFS_EXPORT=y
    - LP: #1121699

  [ Upstream Kernel Changes ]

  * Revert "KVM: x86: apply guest MTRR virtualization on host reserved
    pages"
    - LP: #1509886
  * Revert "KVM: SVM: use NPT page attributes"
    - LP: #1509886
  * Revert "KVM: SVM: Sync g_pat with guest-written PAT value"
    - LP: #1509886
  * Revert "cgroup: simplify threadgroup locking"
    - LP: #1509886
  * Revert "sched, cgroup: replace signal_struct->group_rwsem with a global
    percpu_rwsem"
    - LP: #1509886
  * Revert "ARM64: unwind: Fix PC calculation"
    - LP: #1514889
  * Revert "serial: 8250_dma: don't bother DMA with small transfers"
    - LP: #1514889
  * Revert "md: allow a partially recovered device to be hot-added to an
    array."
    - LP: #1514889
  * arm64: Change memcpy in kernel to use the copy template file
    - LP: #1508471
  * arm64: copy_to-from-in_user optimization using copy template
    - LP: #1508471
  * Input: elan_i2c - enable ELAN0600 acpi panels
    - LP: #1439111
  * e1000e: Fix tight loop implementation of systime read algorithm
  * arm: KVM: Fix incorrect device to IPA mapping
    - LP: #1509886
  * KVM: vmx: fix VPID is 0000H in non-root operation
    - LP: #1509886
  * kvm: don't try to register to KVM_FAST_MMIO_BUS for non mmio eventfd
    - LP: #1509886
  * kvm: fix zero length mmio searching
    - LP: #1509886
  * kvm: factor out core eventfd assign/deassign logic
    - LP: #1509886
  * kvm: fix double free for fast mmio eventfd
    - LP: #1509886
  * arm: KVM: Disable virtual timer even if the guest is not using it
    - LP: #1509886
  * kvm: svm: reset mmu on VCPU reset
    - LP: #1509886
  * KVM: x86: trap AMD MSRs for the TSeg base and mask
    - LP: #1509886
  * KVM: PPC: Book3S: Take the kvm->srcu lock in
    kvmppc_h_logical_ci_load/store()
    - LP: #1509886
  * KVM: PPC: Book3S HV: Pass the correct trap argument to
    kvmhv_commence_exit
    - LP: #1509886
  * time: Fix timekeeping_freqadjust()'s incorrect use of abs() instead of
    abs64()
    - LP: #1509886
  * target/iscsi: Fix np_ip bracket issue by removing np_ip
    - LP: #1509886
  * scsi: fix scsi_error_handler vs. scsi_host_dev_release race
    - LP: #1509886
  * target: Attach EXTENDED_COPY local I/O descriptors to xcopy_pt_sess
    - LP: #1509886
  * target: Fix PR registration + APTPL RCU conversion regression
    - LP: #1509886
  * iser-target: remove command with state ISTATE_REMOVE
    - LP: #1509886
  * iser-target: Put the reference on commands waiting for unsol data
    - LP: #1509886
  * toshiba_acpi: Fix hotkeys registration on some toshiba models
    - LP: #1509886
  *...

Changed in linux (Ubuntu Xenial):
status: In Progress → Fix Released
Revision history for this message
Luis Henriques (henrix) wrote :

This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-wily' to 'verification-done-wily'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: verification-needed-wily
Revision history for this message
Scott Moser (smoser) wrote :

$ echo "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc)-proposed main" | sudo tee /etc/apt/sources.list.d/proposed.list
$ sudo apt-get update
$ sudo apt-get install linux-virtual
$ apt-cache policy linux-virtual
linux-virtual:
  Installed: 4.2.0.19.21
  Candidate: 4.2.0.19.21
  Version table:
 *** 4.2.0.19.21 0
        500 http://archive.ubuntu.com/ubuntu/ wily-proposed/main amd64 Packages
        100 /var/lib/dpkg/status
     4.2.0.18.20 0
        500 http://nova.clouds.archive.ubuntu.com/ubuntu/ wily-updates/main amd64 Packages
        500 http://security.ubuntu.com/ubuntu/ wily-security/main amd64 Packages
     4.2.0.16.18 0
        500 http://nova.clouds.archive.ubuntu.com/ubuntu/ wily/main amd64 Packages

$ sudo apt-get install open-iscsi
$ sudo touch /etc/iscsi/iscsi.initramfs
$ sudo update-initramfs -u -k all
update-initramfs: Generating /boot/initrd.img-4.2.0-19-generic
update-initramfs: Generating /boot/initrd.img-4.2.0-18-generic

## iscsi_ibft and iscsi_boot_sysfs are now in /lib/modules
$ find /lib/modules/ -type f | grep iscsi
/lib/modules/4.2.0-18-generic/kernel/drivers/scsi/libiscsi.ko
/lib/modules/4.2.0-18-generic/kernel/drivers/scsi/scsi_transport_iscsi.ko
/lib/modules/4.2.0-18-generic/kernel/drivers/scsi/libiscsi_tcp.ko
/lib/modules/4.2.0-18-generic/kernel/drivers/scsi/iscsi_tcp.ko

/lib/modules/4.2.0-19-generic/kernel/drivers/scsi/libiscsi.ko
/lib/modules/4.2.0-19-generic/kernel/drivers/scsi/iscsi_boot_sysfs.ko
/lib/modules/4.2.0-19-generic/kernel/drivers/scsi/scsi_transport_iscsi.ko
/lib/modules/4.2.0-19-generic/kernel/drivers/scsi/libiscsi_tcp.ko
/lib/modules/4.2.0-19-generic/kernel/drivers/scsi/iscsi_tcp.ko
/lib/modules/4.2.0-19-generic/kernel/drivers/firmware/iscsi_ibft.ko

## missing from 4.2.0-18-generic initramfs (old linux-virtual)
$ lsinitramfs /boot/initrd.img-4.2.0-18-generic | grep iscsi
lib/modules/4.2.0-18-generic/kernel/drivers/scsi/libiscsi.ko
lib/modules/4.2.0-18-generic/kernel/drivers/scsi/scsi_transport_iscsi.ko
lib/modules/4.2.0-18-generic/kernel/drivers/scsi/libiscsi_tcp.ko
lib/modules/4.2.0-18-generic/kernel/drivers/scsi/iscsi_tcp.ko
scripts/local-top/iscsi

## present in new from 4.2.0-19-generic
$ lsinitramfs /boot/initrd.img-4.2.0-19-generic | grep iscsi
lib/modules/4.2.0-19-generic/kernel/drivers/scsi/libiscsi.ko
lib/modules/4.2.0-19-generic/kernel/drivers/scsi/iscsi_boot_sysfs.ko
lib/modules/4.2.0-19-generic/kernel/drivers/scsi/scsi_transport_iscsi.ko
lib/modules/4.2.0-19-generic/kernel/drivers/scsi/libiscsi_tcp.ko
lib/modules/4.2.0-19-generic/kernel/drivers/scsi/iscsi_tcp.ko
lib/modules/4.2.0-19-generic/kernel/drivers/firmware/iscsi_ibft.ko
etc/initiatorname.iscsi
etc/iscsi.initramfs
scripts/local-top/iscsi
sbin/iscsistart

Then, reboot and ensure the modules load (to verify deps are present).
$ uname -r
4.2.0-19-generic
$ sudo modprobe iscsi_ibft
$ sudo modprobe iscsi_boot_sysfs
$ lsmod | grep iscsi
iscsi_ibft 16384 0
iscsi_boot_sysfs 16384 1 iscsi_ibft
iscsi_tcp 20480 0
libiscsi_tcp 24576 1 iscsi_tcp
libiscsi 53248 2 libiscsi_tcp,iscsi_tcp
scsi_transport_iscsi 102400 3 iscsi_tcp,libiscsi

tags: added: verification-done-wily
removed: verification-needed-wily
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (32.9 KiB)

This bug was fixed in the package linux - 4.2.0-19.23

---------------
linux (4.2.0-19.23) wily; urgency=low

  [ Luis Henriques ]

  * Release Tracking Bug
    - LP: #1515157

  [ Andy Whitcroft ]

  * [Config] re-enable OSS support and blacklist
    - LP: #1434842

  [ dann frazier ]

  * Revert "[Config] CONFIG_ARM64_ERRATUM_843419=n"
    - LP: #1502946

  [ Paolo Pisati ]

  * [SRU] [Config] armhf: LEDS_TRIGGER_HEARTBEAT=y
    - LP: #1510165

  [ Tim Gardner ]

  * [Config] Add iscsi_ibft and iscsi_boot_sysfs to generic inclusion list
    - LP: #1511006
  * [Config] CONFIG_AUFS_EXPORT=y
    - LP: #1121699

  [ Upstream Kernel Changes ]

  * Revert "KVM: x86: apply guest MTRR virtualization on host reserved
    pages"
    - LP: #1509886
  * Revert "KVM: SVM: use NPT page attributes"
    - LP: #1509886
  * Revert "KVM: SVM: Sync g_pat with guest-written PAT value"
    - LP: #1509886
  * Revert "cgroup: simplify threadgroup locking"
    - LP: #1509886
  * Revert "sched, cgroup: replace signal_struct->group_rwsem with a global
    percpu_rwsem"
    - LP: #1509886
  * Revert "ARM64: unwind: Fix PC calculation"
    - LP: #1514889
  * Revert "serial: 8250_dma: don't bother DMA with small transfers"
    - LP: #1514889
  * Revert "md: allow a partially recovered device to be hot-added to an
    array."
    - LP: #1514889
  * arm64: Change memcpy in kernel to use the copy template file
    - LP: #1508471
  * arm64: copy_to-from-in_user optimization using copy template
    - LP: #1508471
  * Input: elan_i2c - enable ELAN0600 acpi panels
    - LP: #1439111
  * e1000e: Fix tight loop implementation of systime read algorithm
  * arm: KVM: Fix incorrect device to IPA mapping
    - LP: #1509886
  * KVM: vmx: fix VPID is 0000H in non-root operation
    - LP: #1509886
  * kvm: don't try to register to KVM_FAST_MMIO_BUS for non mmio eventfd
    - LP: #1509886
  * kvm: fix zero length mmio searching
    - LP: #1509886
  * kvm: factor out core eventfd assign/deassign logic
    - LP: #1509886
  * kvm: fix double free for fast mmio eventfd
    - LP: #1509886
  * arm: KVM: Disable virtual timer even if the guest is not using it
    - LP: #1509886
  * kvm: svm: reset mmu on VCPU reset
    - LP: #1509886
  * KVM: x86: trap AMD MSRs for the TSeg base and mask
    - LP: #1509886
  * KVM: PPC: Book3S: Take the kvm->srcu lock in
    kvmppc_h_logical_ci_load/store()
    - LP: #1509886
  * KVM: PPC: Book3S HV: Pass the correct trap argument to
    kvmhv_commence_exit
    - LP: #1509886
  * time: Fix timekeeping_freqadjust()'s incorrect use of abs() instead of
    abs64()
    - LP: #1509886
  * target/iscsi: Fix np_ip bracket issue by removing np_ip
    - LP: #1509886
  * scsi: fix scsi_error_handler vs. scsi_host_dev_release race
    - LP: #1509886
  * target: Attach EXTENDED_COPY local I/O descriptors to xcopy_pt_sess
    - LP: #1509886
  * target: Fix PR registration + APTPL RCU conversion regression
    - LP: #1509886
  * iser-target: remove command with state ISTATE_REMOVE
    - LP: #1509886
  * iser-target: Put the reference on commands waiting for unsol data
    - LP: #1509886
  * toshiba_acpi: Fix hotkeys registration on some toshiba models
    - LP: #1509886
  *...

Changed in linux (Ubuntu Wily):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.