4

On my lubuntu 22.04 I have installed the package unclutter by the command:

sudo apt-get install unclutter

A description of this package is the following:

unclutter hides your X mouse cursor when you don’t need it, to prevent it from getting in the way. You have only to move the mouse to restore the mouse cursor.

After the installation and the reboot I could see the following unclutter process by ps aux:

$ ps aux | grep unclutter
myuser  926  0.0  0.1   4704  2784 ?  S    09:39   0:00 /usr/bin/unclutter -idle 1 -root

Furthermore by systemctl status I can suppose that unclutter has been started by systemd because the output of the command systemctl status contains:

$ systemctl status

├─user.slice 
|       ├─user-1000.slice 
|       │   ├─[email protected]
|       |   ...
|       └─session-1.scope 
|          │     ├─ ...
|          │     ├─ ...
|          │     ├─ 926 /usr/bin/unclutter -idle 1 -root
...       ...    ...

unclutter-startup

By the command apt list --installed I have found that, with unclutter, is also installed the package unclutter-startup, and in the documentation the description of this other package is:

autostart infrastructure for unclutter and unclutter-xfixes

This sentence explains that unclutter, by the package unclutter-startup, has an autostart infrastructure which is responsible of it startup.

My question

Probably the program unclutter is started by a service, but I can't understand what is the service which starts it. So how can I disable unclutter without remove the package?

5
  • 1
    What does systemctl status <pid-of-unclutter> show?
    – muru
    Dec 6, 2023 at 9:04
  • @muru I think that the most important info which systemctl status <pid-of-unclutter> shows are: 1) session-1.scope, 2) Loaded: loaded (/run/systemd/transient/session-1.scope; transient) 3) CGroup: /user.slice/user-1000.slice/session-1.scope
    – User051209
    Dec 6, 2023 at 9:11
  • 1
    Then it's not started by systemd, but by some other mechanism. Probably XDG autostart. According to the file list of unclutter-startup, I'd say that's the /etc/X11/Xsession.d/90unclutter script.
    – muru
    Dec 6, 2023 at 9:20
  • @muru Thank you very much. I have found the solution. I'll write an answer to share it.
    – User051209
    Dec 6, 2023 at 9:29
  • Actually I can disable unclutter by the file /etc/default/unclutter and not directly by the file /etc/X11/Xsession.d/90unclutter.
    – User051209
    Dec 6, 2023 at 9:51

1 Answer 1

4

By the help of @muru I have found the solution for my question.

The file /etc/default/unclutter

By the file /etc/default/unclutter is possible to select if to start unclutter after X has been started and so it is possible to disable its start.

The content of the file /etc/default/unclutter is the following:

# /etc/default/unclutter - configuration file for unclutter

# Set this option to 'true' if you want to start unclutter
# automagically after X has been started for a user.
# Otherwise, set it to 'false'.
START_UNCLUTTER="true"

# Options passed to unclutter, see 'man unclutter' for details.
EXTRA_OPTS="-idle 1 -root"

As we can read in the comments, to disable the start of unclutter I have to set the value of the variable START_UNCLUTTER to "false":

START_UNCLUTTER="false"

Restart display manager

After made the previous change value I have to restart the display manager by the following command:

sudo systemctl restart display-manager

without need of reboot.

systemd is not involved

As explained by @muru with this comment:

Then it's not started by systemd, but by some other mechanism. Probably XDG autostart. According to the file list of unclutter-startup, I'd say that's the /etc/X11/Xsession.d/90unclutter script.

systemd is not involved in the unclutter startup.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .