Suspend not working

Bug #1629197 reported by Slither
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Expired
Low
Unassigned

Bug Description

I'm running a fresh installation of 16.04 running the latest updates.

When I `pm-suspend` the computer remains powered on but is completely unresponsive. There is no signal going to my monitor and I can't enter a tty shell or ctrl+alt+del to restart. I'm forced to press the the physical reset button. This happens every time I perform a suspend.

I can shutdown and reboot at the moment. I really wish DSDT loading was still available, I could have attempted to fix this myself with a patched bios (if a bung ACPI call is the culprit).

WORKAROUND: Execute the following prior to suspend:
/etc/init.d/tvheadend stop
modprobe -r dvb_usb_dib0700

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: linux-image-4.4.0-38-generic 4.4.0-38.57
ProcVersionSignature: Ubuntu 4.4.0-38.57-generic 4.4.19
Uname: Linux 4.4.0-38-generic x86_64
NonfreeKernelModules: zfs zunicode zcommon znvpair zavl
ApportVersion: 2.20.1-0ubuntu2.1
Architecture: amd64
AudioDevicesInUse: Error: command ['fuser', '-v', '/dev/snd/by-path', '/dev/snd/hwC0D3', '/dev/snd/hwC0D0', '/dev/snd/pcmC0D7p', '/dev/snd/pcmC0D2p', '/dev/snd/pcmC0D3p', '/dev/snd/pcmC0D0c', '/dev/snd/pcmC0D0p', '/dev/snd/controlC0', '/dev/snd/seq', '/dev/snd/timer'] failed with exit code 1:
CurrentDesktop: Unity
Date: Fri Sep 30 16:48:54 2016
HibernationDevice: RESUME=UUID=94b7cd61-7e7a-41a7-a8ec-e3b9b7e2eb87
InstallationDate: Installed on 2016-05-18 (134 days ago)
InstallationMedia: Ubuntu 16.04 LTS "Xenial Xerus" - Release amd64 (20160420.1)
IwConfig:
 lo no wireless extensions.

 enp3s0 no wireless extensions.
MachineType: System manufacturer System Product Name
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.4.0-38-generic root=UUID=48e60eed-d92a-4a36-86dd-0c839f9a63d0 ro quiet splash vt.handoff=7
PulseList: Error: command ['pacmd', 'list'] failed with exit code 1: No PulseAudio daemon running, or not running as session daemon.
RelatedPackageVersions:
 linux-restricted-modules-4.4.0-38-generic N/A
 linux-backports-modules-4.4.0-38-generic N/A
 linux-firmware 1.157.3
RfKill:
 0: hci0: Bluetooth
  Soft blocked: no
  Hard blocked: no
SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 02/01/2013
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 1001
dmi.board.asset.tag: To be filled by O.E.M.
dmi.board.name: P8H77-I
dmi.board.vendor: ASUSTeK COMPUTER INC.
dmi.board.version: Rev X.0x
dmi.chassis.asset.tag: Asset-1234567890
dmi.chassis.type: 3
dmi.chassis.vendor: Chassis Manufacture
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr1001:bd02/01/2013:svnSystemmanufacturer:pnSystemProductName:pvrSystemVersion:rvnASUSTeKCOMPUTERINC.:rnP8H77-I:rvrRevX.0x:cvnChassisManufacture:ct3:cvrChassisVersion:
dmi.product.name: System Product Name
dmi.product.version: System Version
dmi.sys.vendor: System manufacturer

Revision history for this message
Slither (stephen-ohair) wrote :
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
Revision history for this message
penalvch (penalvch) wrote :

Slither, thank you for reporting this and helping make Ubuntu better.

In order to allow additional upstream developers to examine the issue, at your earliest convenience, could you please test the latest upstream kernel available from http://kernel.ubuntu.com/~kernel-ppa/mainline/?C=N;O=D ? Please keep in mind the following:
1) The one to test is at the very top line at the top of the page (not the daily folder).
2) The release names are irrelevant.
3) The folder time stamps aren't indicative of when the kernel actually was released upstream.
4) Install instructions are available at https://wiki.ubuntu.com/Kernel/MainlineBuilds .

If testing on your main install would be inconvenient, one may:
1) Install Ubuntu to a different partition and then test this there.
2) Backup, or clone the primary install.

If the latest kernel did not allow you to test to the issue (ex. you couldn't boot into the OS) please make a comment in your report about this, and continue to test the next most recent kernel version until you can test to the issue. Once you've tested the upstream kernel, please comment on which kernel version specifically you tested. If this issue is fixed in the mainline kernel, please add the following tags by clicking on the yellow circle with a black pencil icon, next to the word Tags, located at the bottom of the report description:
kernel-fixed-upstream
kernel-fixed-upstream-X.Y-rcZ

Where X, and Y are the first two numbers of the kernel version, and Z is the release candidate number if it exists.

If the mainline kernel does not fix the issue, please add the following tags:
kernel-bug-exists-upstream
kernel-bug-exists-upstream-X.Y-rcZ

Please note, an error to install the kernel does not fit the criteria of kernel-bug-exists-upstream.

Also, you don't need to apport-collect further unless specifically requested to do so.

It is most helpful that after testing of the latest upstream kernel is complete, you mark this report Status Confirmed.

Lastly, to keep this issue relevant to upstream, please continue to test the latest mainline kernel as it becomes available.

Thank you for your help.

tags: added: bios-outdated-1102
Changed in linux (Ubuntu):
importance: Undecided → Low
status: Confirmed → Incomplete
Revision history for this message
Slither (stephen-ohair) wrote :
Download full text (3.7 KiB)

Hi Christopher,

I installed the latest mainline upstream kernel 4.8.1

Still have the same issue.

nas@NAS:/tmp$ sudo dpkg -i *.deb
[sudo] password for nas:
Selecting previously unselected package linux-headers-4.8.1-040801.
(Reading database ... 400410 files and directories currently installed.)
Preparing to unpack linux-headers-4.8.1-040801_4.8.1-040801.201610071031_all.deb ...
Unpacking linux-headers-4.8.1-040801 (4.8.1-040801.201610071031) ...
Selecting previously unselected package linux-headers-4.8.1-040801-generic.
Preparing to unpack linux-headers-4.8.1-040801-generic_4.8.1-040801.201610071031_amd64.deb ...
Unpacking linux-headers-4.8.1-040801-generic (4.8.1-040801.201610071031) ...
Selecting previously unselected package linux-image-4.8.1-040801-generic.
Preparing to unpack linux-image-4.8.1-040801-generic_4.8.1-040801.201610071031_amd64.deb ...
Done.
Unpacking linux-image-4.8.1-040801-generic (4.8.1-040801.201610071031) ...
Setting up linux-headers-4.8.1-040801 (4.8.1-040801.201610071031) ...
Setting up linux-headers-4.8.1-040801-generic (4.8.1-040801.201610071031) ...
Setting up linux-image-4.8.1-040801-generic (4.8.1-040801.201610071031) ...
Running depmod.
update-initramfs: deferring update (hook will be called later)
Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.8.1-040801-generic /boot/vmlinuz-4.8.1-040801-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.8.1-040801-generic /boot/vmlinuz-4.8.1-040801-generic
update-initramfs: Generating /boot/initrd.img-4.8.1-040801-generic
W: Possible missing firmware /lib/firmware/i915/kbl_dmc_ver1_01.bin for module i915
W: Possible missing firmware /lib/firmware/i915/kbl_guc_ver9_14.bin for module i915
W: Possible missing firmware /lib/firmware/i915/bxt_guc_ver8_7.bin for module i915
W: Possible missing firmware /lib/firmware/i915/skl_guc_ver6_1.bin for module i915
run-parts: executing /etc/kernel/postinst.d/pm-utils 4.8.1-040801-generic /boot/vmlinuz-4.8.1-040801-generic
run-parts: executing /etc/kernel/postinst.d/unattended-upgrades 4.8.1-040801-generic /boot/vmlinuz-4.8.1-040801-generic
run-parts: executing /etc/kernel/postinst.d/update-notifier 4.8.1-040801-generic /boot/vmlinuz-4.8.1-040801-generic
run-parts: executing /etc/kernel/postinst.d/zz-update-grub 4.8.1-040801-generic /boot/vmlinuz-4.8.1-040801-generic
Generating grub configuration file ...
Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
Found linux image: /boot/vmlinuz-4.8.1-040801-generic
Found initrd image: /boot/initrd.img-4.8.1-040801-generic
Found linux image: /boot/vmlinuz-4.4.0-38-generic
Found initrd image: /boot/initrd.img-4.4.0-38-generic
Found linux image: /boot/vmlinuz-4.4.0-34-generic
Found initrd image: /boot/initrd.img-4.4.0-34-generic
Found linux image: /boot/vmlinuz-4.4.0-31-generic
Found initrd image: /boot/initrd.img-4.4.0-31-generic
Found linux image: /boot/vmlinuz-4.4.0-28-generic
Found initrd image: /boot/initrd.img-4.4.0-28-generic
Found linux image: /boot/vmlinuz-4.4.0-24-generic
Found initrd image: /boot/initrd.img-4.4.0-24-generic
Found linux image: /boot/vmlinuz-4.4.0-22-g...

Read more...

Revision history for this message
penalvch (penalvch) wrote :

Slither, to clarify, did this issue not occur in a Ubuntu release prior to 16.04?

tags: added: kernel-bug-exists-upstream kernel-bug-exists-upstream-4.8.1
Revision history for this message
Slither (stephen-ohair) wrote :

This issue didnt occur on an earlier kernel of never had an issue on 14.04 and an earlier kernel official of 16.04. I don't know which one. I've only ever updated through the official ubuntu repos. After I updated to kernel 4.4.0.38 I started having the suspend issue.

Trying to boot into all the old previously installed kernels via grub didnt fix the issue. I also tried to uninstall the 4.4.0.38 and that stuffed my install forcing me to boot from a 16.04 livecd and chroot my os partion so I could update the kernel bandack to 4 4.0.38 and get it booting again.

Right now I'm going between 4.4.0.38 from the ubuntu repos and whatever upstream mainline kernel you suggest. One issue I noticed testing the upstream kernels is the zfs kernel module doesn't load so i have to rollback to 4.4.0.38 each time. A little annoying unfortunately.

Hope this helps.

Revision history for this message
penalvch (penalvch) wrote :

Slither, to clarify, which good kernel did you update from, to get to 4.4.0.38?

Revision history for this message
Slither (stephen-ohair) wrote :

It may have been 4.4.0.31 but booting to that via grub showed the same issue so i think it may a change in more than just the kernel that's caused this. Please note the only kernels installed on my machine now are 4.4.0.38. I went down a path of elimination a week ago trying to determine which was the good kernel. I did this by removing the lastest kernel the testing the previous and repeating this process until I had only 4.4.0.21 on my machine. This put ubuntu in a bad state where the network keyboard and mouse failed to work even in safe mode. To fix that i had to boot a livecd and then chroot to install the 4.4.0.38 kernel. Sorry if this sounds confusuing.

Revision history for this message
penalvch (penalvch) wrote :

Slither, could you please provide the missing information following https://wiki.ubuntu.com/DebuggingKernelSuspend ?

Revision history for this message
Slither (stephen-ohair) wrote :

While booted into the latest non-daily mainline kernel, execute at a terminal:

cat /proc/acpi/wakeup > wakeup

See attached file.

Revision history for this message
Slither (stephen-ohair) wrote :

Please provide the output of the following terminal command:

cat /sys/kernel/debug/suspend_stats

See attached file

Revision history for this message
Slither (stephen-ohair) wrote :

I've executed all the commands below and then attempted to create the resume trace this command as per the instructions :

sudo sh -c "sync && echo 1 > /sys/power/pm_trace && pm-suspend"

As expected my system froze. Display stilled showed my X11 session with browser and terminal open but the computer was completely unresponsive. I tried pressing the power button yet still no response. The computer was stuck in that limbo state again.

I had to press the physical restart button and boot into ubuntu again. I then executed:

sudo su && dmesg > dmesg.cat

See attached file.

Instructions executed prior to sleep and dmesg commands above:

While booted into the latest non-daily mainline kernel, execute at a terminal:

sudo su
echo freezer > /sys/power/pm_test
exit

Please attach to your report the resume trace mentioned below.

While booted into the latest non-daily mainline kernel, execute at a terminal:

sudo su
echo devices > /sys/power/pm_test
exit

Please attach to your report the resume trace mentioned below.

While booted into the latest non-daily mainline kernel, execute at a terminal:

sudo su
echo platform > /sys/power/pm_test
exit

Please attach to your report the resume trace mentioned below.

While booted into the latest non-daily mainline kernel, execute at a terminal:

sudo su
echo processors > /sys/power/pm_test
exit

Please attach to your report the resume trace mentioned below.

While booted into the latest non-daily mainline kernel, execute at a terminal:

sudo su
echo core > /sys/power/pm_test
exit

Please attach to your report the resume trace mentioned below.

While booted into the latest non-daily mainline kernel, execute at a terminal:

sudo su
echo none > /sys/power/pm_test
exit

Please attach to your report the resume trace mentioned below.

Revision history for this message
Slither (stephen-ohair) wrote :

In answer to the first 3 questions:

1. Which part of the process does the issue occur with, the suspend to ram, or resuming from? Instantly after suspend from gui or terminal is issued.

2. Please advise how you suspended specifically. For example:

    Executing at a terminal pm-suspend
    Clicking the word Suspend in the GUI.

3. Please advise how you resumed specifically. For example:

    I used to be able to resume by either the power button or or wake on usb via my MCE IR receiver.

Revision history for this message
penalvch (penalvch) wrote :

Slither, the article has been updated to better reflect what is requested. To advise, one is to attach a resume trace after each of those steps, not just run all the commands requested and then provide one dmesg at the end.

Revision history for this message
Slither (stephen-ohair) wrote :

Hi Christopher,

I'm happy to re-attempt the 6 pm-test commands again but to be clear on how the resume trace is generated can you please confirm if the steps below will suffice?

    sudo su
    echo freezer > /sys/power/pm_test
    exit

    sudo sh -c "sync && echo 1 > /sys/power/pm_trace && pm-suspend"

# at this point my machine will instantly freeze, do I wait or should I press the reset button?

# also do I run the dmesg command below after the restart?

    dmesg > dmesg.txt

Revision history for this message
Slither (stephen-ohair) wrote :

Btw I booted a livecd of Ubuntu 16.04.1 with kernel 4.4.0-31 and that can sleep/resume fine. So the issue seems to be with 4.4.0-38, at least with me.

Revision history for this message
Slither (stephen-ohair) wrote :

Hi Christopher,

I found the culprit and can confirm this is not a bug with the kernel 4.4.0.38. I attached a Sony PlayTV usb dvb tuner (dib0700) a little while ago. I use it with TVHeadend which is installed as a background service. After disconnecting it the system suspend/resume was working perfectly again.

To fix and allow me to keep the dvb adapter connected I had to create a pre-suspend/post-resume script in /lib/systemd/system-sleep/ directory that would first stop the TVHeadend service then unload the dvb module prior to suspend and the inverse upon waking.

/etc/init.d/tvheadend stop
modprobe -r dvb_usb_dib0700

While the fix works it's a bit strange that the livecd had no issue suspending with the usb dvb adapter attached since dmesg clearly showed it was able to unload the dvb adapter. Maybe it's the fact that TVHeadend was not loaded in the livecd and accessing the tuners??? Not sure...

Either way, I have a solution so happy for you to close this bug report.

Cheers,

Stephen

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for linux (Ubuntu) because there has been no activity for 60 days.]

Changed in linux (Ubuntu):
status: Incomplete → Expired
Revision history for this message
penalvch (penalvch) wrote :

Stephen, to clarify, do you have to do both of the following to WORKAROUND the suspend issue, or only one:
/etc/init.d/tvheadend stop
modprobe -r dvb_usb_dib0700

description: updated
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.