Score:4

How to disable redshift (service) on startup

cn flag

I have redshift installed on a XUbuntu 21.04. Apparently it's a service systemd[4048]: redshift.service: Failed with result 'exit-code' and it runs at startup.

I'd like to disable redshift on startup, but I can't find where and in which format it's started:

> systemctl stop redshift
> Failed to stop redshift.service: Unit redshift.service not loaded.

systemctl list-units --type=service Doesn't list it

The only thing that worked so far was a couple of sudo killall redshift calls right after booting

Score:2
zw flag

According to RedShift filelists it has systemd service for users.
To disable it use command below:

systemctl --user mask redshift.service redshift-gtk.service

and then reboot.

Also it is known that redshift service is broken at least on Ubuntu MATE 21.04, so really we can prevent its start on LightDM startup by executing the following commands for manual masking:

sudo mkdir -p /var/lib/lightdm/.config/systemd/user
sudo ln -sf /dev/null /var/lib/lightdm/.config/systemd/user/redshift.service  
sudo ln -sf /dev/null /var/lib/lightdm/.config/systemd/user/redshift-gtk.service
sudo chown -R lightdm: /var/lib/lightdm/.config

Note: Xubuntu also uses LightDM, so the above will work for it too.

DarkTrick avatar
cn flag
Didn't work for me. Service kept starting.
N0rbert avatar
zw flag
Use `mask` instead of `disable`.
DarkTrick avatar
cn flag
Removing is no option, as I'm actually using it - just not as service.
Greg Hilston avatar
cn flag
This worked for me using redshift 1.12 on Pop OS 21.04
Score:1
cn flag

@N0rbert's solution did not work for me, although it was a pointer in the right direction.

I found user services in /usr/lib/systemd/user and changed redshift.service to redshift.service.disabled. That stopped running on boot.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.