I started using Ubuntu and didn't really like how fast the mouse moved, so I found out the command to change it

xinput --set-prop 11 "Device Accel Constant Deceleration" 4

Which will make it slow, but it's annoying having to type that in every time. I made a normal new gedit file "mouse_sensitivity" in my ~/Documents folder, and in /etc/rc.local I put:

sh "home/dylan/Documents/mouse_sensitivity"

Obviously, my problem is that this doesn't do anything when I restart my computer.

Quick note about the command I'm trying to use. It works and everything in the terminal or when I execute /etc/rc.local. If anyone else was looking for that command, beware that '11' is the associated number for my mouse, but probably not yours. And '4' is a really really slow speed for a pointer, but I just wanted to be sure that I'd notice the difference.

Also, I haven't edited it but when I execute /etc/init.d/rc.local it doesn't work. I can get those errors for you if you need.

2 Answers 2


Just add your command-line

xinput --set-prop 11 "Device Accel Constant Deceleration" 4

to the file ~/.profile.

  • Sorry for being so inept, but I can't find that file
    – Dylan D.B
    Sep 25, 2016 at 8:50
  • the file .profile is located in your home-directory. In your file-manager enable the option Show hidden files to see the file.
    – mook765
    Sep 25, 2016 at 9:08
  • Thank you. I opened it using the command xdg-open ~/.profile and just put my command at the bottom. It's working now. Thank you so much
    – Dylan D.B
    Sep 25, 2016 at 9:21

There might be a simpler method to your mouse speed issues. From the Launcher select System Settings and then click on Mouse & Touchpad to bring up this screen:

enter image description here

From here you can set your mouse speed.

  • Thanks for the idea but this was the first thing I tried. I don't know whether it's because it's wireless or because it shares a transceiver with my keyboard, or something entirely different, but that option isn't available.
    – Dylan D.B
    Sep 25, 2016 at 3:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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