Hyper-V TRIM Feature Broken in current LTS trusty kernel

Bug #1406867 reported by Jeff Leung
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Medium
Andy Whitcroft
Trusty
Fix Released
Medium
Andy Whitcroft
Utopic
Fix Released
Medium
Andy Whitcroft
Vivid
Fix Released
Medium
Andy Whitcroft

Bug Description

The TRIM/UNMAP feature is broken in the current trusty kernel with Hyper-V because of the reversion of this commit:

http://kernel.ubuntu.com/git?p=ubuntu/ubuntu-trusty.git;a=commit;h=81a73bce0c7b86fbf51004cb171387e73e082784

However a proposed storvsc patch has been submitted to the upstream kernel mailing list which could be found here:

https://patchwork.kernel.org/patch/5503381/

In Hyper-V TRIM/UNMAP allows the user to reclaim allocated storage that is no longer in use inside a thin provisioned VHDX volume.
---
AlsaDevices:
 total 0
 crw-rw---- 1 root audio 116, 1 Jan 1 03:42 seq
 crw-rw---- 1 root audio 116, 33 Jan 1 03:42 timer
AplayDevices: Error: [Errno 2] No such file or directory
ApportVersion: 2.14.1-0ubuntu3.6
Architecture: amd64
ArecordDevices: Error: [Errno 2] No such file or directory
AudioDevicesInUse: Error: command ['fuser', '-v', '/dev/snd/seq', '/dev/snd/timer'] failed with exit code 1:
CRDA: Error: [Errno 2] No such file or directory
CurrentDmesg: [ 10.846694] init: plymouth-upstart-bridge main process ended, respawning
DistroRelease: Ubuntu 14.04
IwConfig: Error: [Errno 2] No such file or directory
Lspci: Error: [Errno 2] No such file or directory
Lsusb: Error: [Errno 2] No such file or directory
MachineType: Microsoft Corporation Virtual Machine
Package: linux (not installed)
PciMultimedia:

ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcFB: 0 VESA VGA
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-3.13.0-43-generic root=/dev/mapper/trusty--201412122541-root ro quiet elevator=noop video=hyperv_fb:800x600 splash vt.handoff=7
ProcVersionSignature: Ubuntu 3.13.0-43.72-generic 3.13.11.11
RelatedPackageVersions:
 linux-restricted-modules-3.13.0-43-generic N/A
 linux-backports-modules-3.13.0-43-generic N/A
 linux-firmware N/A
RfKill: Error: [Errno 2] No such file or directory
Tags: trusty
Uname: Linux 3.13.0-43-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups:

_MarkForUpload: True
dmi.bios.date: 05/23/2012
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 090006
dmi.board.name: Virtual Machine
dmi.board.vendor: Microsoft Corporation
dmi.board.version: 7.0
dmi.chassis.asset.tag: 3060-1254-0945-5202-9816-4673-85
dmi.chassis.type: 3
dmi.chassis.vendor: Microsoft Corporation
dmi.chassis.version: 7.0
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr090006:bd05/23/2012:svnMicrosoftCorporation:pnVirtualMachine:pvr7.0:rvnMicrosoftCorporation:rnVirtualMachine:rvr7.0:cvnMicrosoftCorporation:ct3:cvr7.0:
dmi.product.name: Virtual Machine
dmi.product.version: 7.0
dmi.sys.vendor: Microsoft Corporation

Revision history for this message
Brad Figg (brad-figg) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. From a terminal window please run:

apport-collect 1406867

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: trusty
Jeff Leung (jleung)
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
status: Confirmed → Incomplete
Revision history for this message
Jeff Leung (jleung) wrote : BootDmesg.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Jeff Leung (jleung) wrote : ProcCpuinfo.txt

apport information

Revision history for this message
Jeff Leung (jleung) wrote : ProcInterrupts.txt

apport information

Revision history for this message
Jeff Leung (jleung) wrote : ProcModules.txt

apport information

Revision history for this message
Jeff Leung (jleung) wrote : UdevDb.txt

apport information

Revision history for this message
Jeff Leung (jleung) wrote : UdevLog.txt

apport information

Revision history for this message
Jeff Leung (jleung) wrote : WifiSyslog.txt

apport information

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Jeff Leung (jleung) wrote :

This issue will only affect Windows 8/8.1 level hosts. This issue does not affect Windows 10 level hosts as starting in Windows 10, Hyper-V finally declares it's own virtual disks as SPC-3 compliant.

Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v3.19 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

If you are unable to test the mainline kernel, for example it will not boot, please add the tag: 'kernel-unable-to-test-upstream'.
Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.19-rc2-vivid/

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Confirmed → Triaged
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

I don't see the commit mentioned on https://patchwork.kernel.org/patch/5503381/ in v3.19-rc2 yet, so you probably don't have to test it.

tags: added: kernel-hyper-v
tags: added: vivid
Andy Whitcroft (apw)
Changed in linux (Ubuntu):
assignee: nobody → Andy Whitcroft (apw)
milestone: none → ubuntu-15.01
Andy Whitcroft (apw)
Changed in linux (Ubuntu Trusty):
status: New → In Progress
Changed in linux (Ubuntu Utopic):
status: New → In Progress
Changed in linux (Ubuntu Vivid):
status: Triaged → In Progress
Changed in linux (Ubuntu Trusty):
importance: Undecided → Medium
Changed in linux (Ubuntu Utopic):
importance: Undecided → Medium
Changed in linux (Ubuntu Trusty):
assignee: nobody → Andy Whitcroft (apw)
Changed in linux (Ubuntu Utopic):
assignee: nobody → Andy Whitcroft (apw)
milestone: none → utopic-updates
Changed in linux (Ubuntu Trusty):
milestone: none → trusty-updates
Andy Whitcroft (apw)
Changed in linux (Ubuntu Vivid):
status: In Progress → Fix Committed
Revision history for this message
Andy Whitcroft (apw) wrote :

We are in a bit of a mess here. To clean this up and end up with a consistant fix applied to all the prime releases I am submitting patch kits to apply this fix for Trusty, and revert the current fix and apply this to Utopic. I have also applied this fix to both Vivid v3.18 and v3.19 based kernels going forward. Once this has all made it through process we should have a single common fix on all releases Trusty and later.

Brad Figg (brad-figg)
Changed in linux (Ubuntu Trusty):
status: In Progress → Fix Committed
Changed in linux (Ubuntu Utopic):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux - 3.18.0-9.10

---------------
linux (3.18.0-9.10) vivid; urgency=low

  [ Colin Ian King ]

  * SAUCE: drivers/rtc/interface.c: ignore exprired times when enqueing new
    timers
    - LP: #1333569

  [ Joseph Salisbury ]

  * [Config] Enable CONFIG_N_GSM as module.
    - LP: #1404670

  [ K. Y. Srinivasan ]

  * SAUCE: storvsc: force SPC-3 compliance on win8 and win8 r2 hosts
    - LP: #1406867

  [ Leann Ogasawara ]

  * rebase to v3.18.2
  * Release Tracking Bug
    - LP: #1409794

  [ Upstream Kernel Changes ]

  * Drivers: hv: util: make struct hv_do_fcopy match Hyper-V host messages
    - LP: #1401903
  * rebase to v3.18.2
 -- Leann Ogasawara <email address hidden> Mon, 12 Jan 2015 08:53:12 -0800

Changed in linux (Ubuntu Vivid):
status: Fix Committed → Fix Released
Revision history for this message
Brad Figg (brad-figg) 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-trusty' to 'verification-done-trusty'.

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-trusty
tags: added: verification-needed-utopic
Revision history for this message
Brad Figg (brad-figg) 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-utopic' to 'verification-done-utopic'.

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!

Jeff Leung (jleung)
tags: added: verification-done-trusty
removed: verification-needed-trusty
Jeff Leung (jleung)
tags: added: verification-done-utopic
removed: verification-needed-utopic
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (14.2 KiB)

This bug was fixed in the package linux - 3.16.0-30.40

---------------
linux (3.16.0-30.40) utopic; urgency=low

  [ Seth Forshee ]

  * Release Tracking Bug
    - LP: #1409890

  [ Andy Whitcroft ]

  * Revert "SAUCE: scsi: hyper-v storsvc switch up to SPC-3"
  * [Packaging] uploadnum should be the remainder of the version
    - LP: #1407755

  [ K. Y. Srinivasan ]

  * SAUCE: storvsc: force SPC-3 compliance on win8 and win8 r2 hosts
    - LP: #1406867

  [ Upstream Kernel Changes ]

  * Revert "xhci: clear root port wake on bits if controller isn't wake-up
    capable"
    - LP: #1408697
  * KVM: PPC: BOOK3S: HV: CMA: Reserve cma region only in hypervisor mode
    - LP: #1400209
  * powerpc/powernv: Ignore smt-enabled on Power8 and later
    - LP: #1402141
  * net/mlx4_en: Add VXLAN ndo calls to the PF net device ops too
    - LP: #1407760
  * net/mlx4_core: Enable CQE/EQE stride support
    - LP: #1400127
  * net/mlx4_core: Cache line EQE size support
    - LP: #1400127
  * net/mlx4_en: Add mlx4_en_get_cqe helper
    - LP: #1400127
  * net/mlx4_core: Introduce mlx4_get_module_info for cable module info
    reading
    - LP: #1400127
  * ethtool, net/mlx4_en: Cable info, get_module_info/eeprom ethtool
    support
    - LP: #1400127
  * net/mlx4_core: Introduce ACCESS_REG CMD and eth_prot_ctrl dev cap
    - LP: #1400127
  * net/mlx4_core: Add ethernet backplane autoneg device capability
    - LP: #1400127
  * ethtool, net/mlx4_en: Add 100M, 20G, 56G speeds ethtool reporting
    support
    - LP: #1400127
  * net/mlx4_en: Use PTYS register to query ethtool settings
    - LP: #1400127
  * net/mlx4_en: Use PTYS register to set ethtool settings (Speed)
    - LP: #1400127
  * net/mlx4_en: Add support for setting rxvlan offload OFF/ON
    - LP: #1400127
  * net/mlx4_en: Add ethtool support for [rx|tx]vlan offload set to OFF/ON
    - LP: #1400127
  * net/mlx4_core: Prevent VF from changing port configuration
    - LP: #1400127
  * net/mlx4_en: mlx4_en_set_settings() always fails when autoneg is set
    - LP: #1400127
  * sparc64: Fix constraints on swab helpers.
    - LP: #1408697
  * inetdevice: fixed signed integer overflow
    - LP: #1408697
  * ipv4: Fix incorrect error code when adding an unreachable route
    - LP: #1408697
  * ieee802154: fix error handling in ieee802154fake_probe()
    - LP: #1408697
  * qmi_wwan: Add support for HP lt4112 LTE/HSPA+ Gobi 4G Modem
    - LP: #1408697
  * bonding: fix curr_active_slave/carrier with loadbalance arp monitoring
    - LP: #1408697
  * pptp: fix stack info leak in pptp_getname()
    - LP: #1408697
  * ipx: fix locking regression in ipx_sendmsg and ipx_recvmsg
    - LP: #1408697
  * net/mlx4_en: Advertize encapsulation offloads features only when VXLAN
    tunnel is set
    - LP: #1408697
  * target: Don't call TFO->write_pending if data_length == 0
    - LP: #1408697
  * vhost-scsi: Take configfs group dependency during
    VHOST_SCSI_SET_ENDPOINT
    - LP: #1408697
  * srp-target: Retry when QP creation fails with ENOMEM
    - LP: #1408697
  * ASoC: fsi: remove unsupported PAUSE flag
    - LP: #1408697
  * ASoC: rsnd: remove unsupported PAUSE flag
    - LP: #1408697
  * ib_isert: Add max_send_sge...

Changed in linux (Ubuntu Utopic):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (9.0 KiB)

This bug was fixed in the package linux - 3.13.0-45.74

---------------
linux (3.13.0-45.74) trusty; urgency=low

  [ Seth Forshee ]

  * Release Tracking Bug
    - LP: #1410384

  [ Jesse Barnes ]

  * SAUCE: drm/i915/vlv: assert and de-assert sideband reset at boot and
    resume v3
    - LP: #1401963

  [ K. Y. Srinivasan ]

  * SAUCE: storvsc: force SPC-3 compliance on win8 and win8 r2 hosts
    - LP: #1406867

  [ Timo Aaltonen ]

  * SAUCE: Switch VLV/BYT to use i915_bdw.
    - LP: #1401963

  [ Upstream Kernel Changes ]

  * Revert "xhci: clear root port wake on bits if controller isn't wake-up
    capable"
    - LP: #1408779
  * KVM: PPC: BOOK3S: HV: CMA: Reserve cma region only in hypervisor mode
    - LP: #1400209
  * e1000e: Fix no connectivity when driver loaded with cable out
    - LP: #1400365
  * net/mlx4_core: Enable CQE/EQE stride support
    - LP: #1400127
  * net/mlx4_core: Cache line EQE size support
    - LP: #1400127
  * net/mlx4_en: Add mlx4_en_get_cqe helper
    - LP: #1400127
  * net/mlx4_core: Introduce mlx4_get_module_info for cable module info
    reading
    - LP: #1400127
  * ethtool, net/mlx4_en: Cable info, get_module_info/eeprom ethtool
    support
    - LP: #1400127
  * net/mlx4_core: Introduce ACCESS_REG CMD and eth_prot_ctrl dev cap
    - LP: #1400127
  * net/mlx4_core: Add ethernet backplane autoneg device capability
    - LP: #1400127
  * ethtool, net/mlx4_en: Add 100M, 20G, 56G speeds ethtool reporting
    support
    - LP: #1400127
  * net/mlx4_en: Use PTYS register to query ethtool settings
    - LP: #1400127
  * net/mlx4_en: Use PTYS register to set ethtool settings (Speed)
    - LP: #1400127
  * net/mlx4_en: Add support for setting rxvlan offload OFF/ON
    - LP: #1400127
  * net/mlx4_en: Add ethtool support for [rx|tx]vlan offload set to OFF/ON
    - LP: #1400127
  * net/mlx4_core: Prevent VF from changing port configuration
    - LP: #1400127
  * net/mlx4_en: mlx4_en_set_settings() always fails when autoneg is set
    - LP: #1400127
  * ipv4: fix nexthop attlen check in fib_nh_match
    - LP: #1408779
  * vxlan: fix a use after free in vxlan_encap_bypass
    - LP: #1408779
  * vxlan: using pskb_may_pull as early as possible
    - LP: #1408779
  * vxlan: fix a free after use
    - LP: #1408779
  * ipv4: fix a potential use after free in ip_tunnel_core.c
    - LP: #1408779
  * ax88179_178a: fix bonding failure
    - LP: #1408779
  * tcp: md5: do not use alloc_percpu()
    - LP: #1408779
  * ipv4: dst_entry leak in ip_send_unicast_reply()
    - LP: #1408779
  * drivers/net, ipv6: Select IPv6 fragment idents for virtio UFO packets
    - LP: #1408779
  * drivers/net: macvtap and tun depend on INET
    - LP: #1408779
  * ip6_tunnel: Use ip6_tnl_dev_init as the ndo_init function.
    - LP: #1408779
  * vti6: Use vti6_dev_init as the ndo_init function.
    - LP: #1408779
  * sit: Use ipip6_tunnel_init as the ndo_init function.
    - LP: #1408779
  * gre6: Move the setting of dev->iflink into the ndo_init functions.
    - LP: #1408779
  * vxlan: Do not reuse sockets for a different address family
    - LP: #1408779
  * net: sctp: fix memory leak in auth key management
    - LP: #1408779
  * smsc911x: power-...

Read more...

Changed in linux (Ubuntu Trusty):
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.