I have found this solution from a thread a while ago but its temporary fix only:
This seems to be a bug in 12.04.2. As stated in comments, a simple fix would be unloading the mouse driver and load it again like this:
sudo modprobe -r psmouse sudo modprobe psmouse proto=imps
This only keeps the touchpad working on this session. To make it permanent one can create a file like
/etc/modprobe.d/psmouse.conf
(you can choose the name you want, but you must keep the extension) with the following content:options psmouse proto=imps
~~ Salem's answer to Synaptic touchpad on laptop not working
My question is how to make a permanent file like he was talking about. I don't have any idea how to do that in Ubuntu.
That answer (sudo modprobe -r psmouse &&
sudo modprobe psmouse proto=imps
) works on my 12.04 system but after I have shut down my laptop the weird problem comes back. I don't really know how to make the solution permanent because what he said was that it is just a temporary fix.