Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

simple problem:

Touchpad stops working after suspend in Ubuntu 11.10. It is an annoying problem as I like to use my touchpad together with my mouse for convenience (unless I must use my touchpad because the mouse isn't available).

Can anyone help?

I also posted a comment under this unsolved question for a similar problem in 10.10: Touchpad stopped working after suspend, never woke up again

Laptop make and model: CLEVO M55N.

xinput list in terminal gives:

⎡ Virtual core pointer                      id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ Genius 2.4G Wireless Mouse and Keyboard   id=11   [slave  pointer  (2)]
⎜   ↳ ImPS/2 Elantech Touchpad                  id=13   [slave  pointer  (2)]
⎣ Virtual core keyboard                     id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]
    ↳ Power Button                              id=6    [slave  keyboard (3)]
    ↳ Video Bus                                 id=7    [slave  keyboard (3)]
    ↳ Power Button                              id=8    [slave  keyboard (3)]
    ↳ Sleep Button                              id=9    [slave  keyboard (3)]
    ↳ Genius 2.4G Wireless Mouse and Keyboard   id=10   [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=12   [slave  keyboard (3)]

Thanks beforehand.

share|improve this question
    
What's the make/model of your computer? Also, could you add to your question the output of running "xinput list" on a terminal? Thanks! –  roadmr Dec 20 '11 at 21:27
    
I edited my initial question accordingly. –  Ederico Dec 20 '11 at 23:30

5 Answers 5

Unfortunately, there are a lot of reasons why this could happen. A work-around that helped me in some cases is reloading the kernel module responsible for the mouse events:

sudo modprobe -r psmouse
sudo modprobe psmouse

You should also check if using the Fn-Keys makes any difference.

share|improve this answer
    
I'll check this out and get back to you, as I see this only now (0:30 CET) and it is late here. I'm tired, good night and thanks. –  Ederico Dec 20 '11 at 23:30
    
I've checked this out. Using the commands given solves the problem temporarily, that is when I suspend again the problem resurfaces. Thanks for the suggestion, that solves the problem, although I'd rather go for a permanent solution rather than using those commands each and every time. I don't understand what you mean as regards the function keys making any difference. Thanks again. –  Ederico Dec 21 '11 at 11:05
    
this worked out fine for me. thanks for the tip! –  altern Feb 25 '12 at 9:18

The Power Manager (dpkg -L pm-utils) is invoked at the beginning and end of your Suspend/Resume. Read man pm-powersave and man pm-suspend. Also read /usr/share/doc/pm-utils/README{,.debugging}.

Some helpful Power Manager script is probably causing your touchpad problem. Either it's not saving/restoring the touchpad state or not reloading a needed module.

Look at dmesg after a reboot, and try to see how your touchpad is initialized. Compare the output of lsmod both post-boot-pre-suspend (when it works) and post-suspend (when it doesn't). If a module is missing from the latter, you're on your way to a solution.

Another debugging technique is to begin in the post-boot-pre-suspend state, and do:

  1. touch /tmp/before-time-date
  2. Close the Lid and Suspend.
  3. Open the Lid and Resume.
  4. Find system logs that have changed since step 1:
    find /var/logs -type f -anewer /tmp/before-time-date
  5. Look at the last several-to-many lines of each of these files. I use less, and have my favorite settings in an environment variable, $LESS=-XMersj3. so I can do:
    sudo -v;find /var/logs -type f -anewer /tmp/before-date-time -print | xargs sudo less $LESS
    then use less's G (uppercase ) command to get to the end of each file.
share|improve this answer
    
I'll try this when I find the time, I've got a very important exam in a week's time and I can't experiment much and/or use time for anything else but studying and unavoidable activities. I'll get back to you in a comment hereunder as soon as I try it out. –  Ederico Dec 21 '11 at 11:07

Try this in terminal after resume:

synclient touchpadoff=0

If it works, you can write a script containing this command, and put the script in /etc/pm/sleep.d/.

share|improve this answer

I also have this bug on 10.04 (at me same Elantech touchpad)! I create script /etc/pm/sleep.d/66my-sleep-resume (66 - a start priority)

#!/bin/sh
case "${1}" in
        hibernate)
        # nothing   
                ;;
        resume|thaw)
        modprobe -r psmouse && modprobe psmouse
                ;;
esac

and now all works.

share|improve this answer
    
very good trick, do once and forget. –  dangra Nov 23 '12 at 14:15

Had a similar problem with my wireless USB mouse/ keyboard (Logitech) on (L)ubuntu 12.04 LTS. Mouse cursor was stuck after pm-suspend. unplugging and re-plugging the USB fixed the issue.

Above workaround, creating a script in /etc/pm/sleep.d, sorta worked. had to change the psmouse to hid_logitech.

With different hardware you will have to change the script accordingly, depending on what kernel modules you will need to reload.

/etc/pm/sleep.d/99_fixmouse

#!/bin/sh

case "${1}" in
  hibernate)
    #nothing
    ;;
  resume|thaw)
    modprobe -r hid_logitech
    modprobe  hid_logitech
    ;;
esac

don't forget to do a chmod +x on the above file.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.