LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-01-2019, 01:16 AM   #1
LMINTUSER
LQ Newbie
 
Registered: Apr 2019
Posts: 14

Rep: Reputation: Disabled
cupsd starts at boot even when I disabled the service


Hi everybody at LQ,

I am running linux mint 19 tessa.

I did my research before posting here on how to disable the cupsd at boot. I tried these two commands so far

Code:
sudo systemctl disable cups
and then the next day I tried

Code:
sudo systemctl disable cups.service
Despite trying these two commands, cupsd still starts at boot.

Am I doing something wrong in the systax or does mint has a different way of disabling services at boot?

I appreciate any help. Thanks

Last edited by LMINTUSER; 05-01-2019 at 03:17 AM.
 
Old 05-01-2019, 03:21 AM   #2
LMINTUSER
LQ Newbie
 
Registered: Apr 2019
Posts: 14

Original Poster
Rep: Reputation: Disabled
I tried many distros for years and this is the first time that a service still starts at boot when I didn't want it to.

I did more research online and on youtube and the systax is correct. Must be a bug in linux mint 19.
 
Old 05-01-2019, 06:20 AM   #3
dc.901
Senior Member
 
Registered: Aug 2018
Location: Atlanta, GA - USA
Distribution: CentOS/RHEL, openSuSE/SLES, Ubuntu
Posts: 1,005

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
What is the output of:
Code:
sudo systemctl is-enabled cups
Do you have any service running that requires cups and might be enabling it?

When you run these, is there any output:
Code:
sudo systemctl stop cups
sudo systemctl disable cups
Then, run dmesg and review syslog; is there anything there about cups?
 
Old 05-01-2019, 07:49 AM   #4
LMINTUSER
LQ Newbie
 
Registered: Apr 2019
Posts: 14

Original Poster
Rep: Reputation: Disabled
After I did a reboot, i typed this

sudo systemctl is-enabled cups
disabled

However

Code:
service cups status
● cups.service - CUPS Scheduler
   Loaded: loaded (/lib/systemd/system/cups.service; disabled; vendor preset: en
   Active: active (running) since Wed 2019-05-01 08:39:12 EDT; 9s ago
     Docs: man:cupsd(8)
 Main PID: 3458 (cupsd)
    Tasks: 1 (limit: 4915)
   CGroup: /system.slice/cups.service
           └─3458 /usr/sbin/cupsd -l
It shows it is was disable in RED, But it shows active and running. Next, I ran the other commands

sudo systemctl stop cups
dmesg | grep -i cups

sudo systemctl disable cups
Synchronizing state of cups.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install disable cups

dmesg | grep -i cups

No output from dmesg after stopping and disabling cups

I rebooted again and it is active and running again. lol

Last edited by LMINTUSER; 05-01-2019 at 07:52 AM.
 
Old 05-01-2019, 08:19 AM   #5
joe_2000
Senior Member
 
Registered: Jul 2012
Location: Aachen, Germany
Distribution: Void, Debian
Posts: 1,016

Rep: Reputation: 308Reputation: 308Reputation: 308Reputation: 308
Maybe cups is started by a depending unit. Run

Code:
systemctl --reverse list-dependencies cups
to find it.

On a debian system I just tested on, this returned cups-browsed.service.

Is that enabled on your system? If so, try disabling it and reboot.
 
2 members found this post helpful.
Old 05-01-2019, 08:24 AM   #6
sgrlscz
Member
 
Registered: Aug 2008
Posts: 123

Rep: Reputation: 84
The systemctl disable command prevents auto-starting of the service at boot, but it doesn't prevent the service from being started. If the service is a dependency of another service, it will be started when that other service is started.

To completely prevent a service from starting, you can mask it, but you should be very careful with that because I've read that unmasking may not work reliably, so it can be difficult to restore the service if necessary. Masking completely disables a service by making its unit file a symlink to /dev/null, which means there is no way to start the service, so even it's a dependency, it won't be able to start.
 
Old 05-01-2019, 09:11 AM   #7
LMINTUSER
LQ Newbie
 
Registered: Apr 2019
Posts: 14

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by joe_2000 View Post
Maybe cups is started by a depending unit. Run

Code:
systemctl --reverse list-dependencies cups
to find it.

On a debian system I just tested on, this returned cups-browsed.service.

Is that enabled on your system? If so, try disabling it and reboot.
Hi Joe,

I tried your command at it was depended on cups-browsed.service

Code:
systemctl --reverse list-dependencies cups
cups.service
● └─cups-browsed.service
I then ran
Code:
sudo systemctl disable cups-browsed.service
And rebooted.

Happily the cupsd did not start at boot.

Thank you, Thank you, and THANK YOU JOE !!!!!!!!!!!!!!!



Thanks dc.901 and sgrlscz for the replies and suggestions!

Last edited by LMINTUSER; 05-01-2019 at 11:36 AM.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
systemctl status postgresql-tst.service starts the service if service is stopped MarianForums Linux - Newbie 7 11-03-2018 03:02 PM
[SOLVED] Disabled nagios service starts on update (CentOS 6) genese Linux - Server 7 12-15-2017 10:12 AM
Restart service or even reboot upon service stopping NotionCommotion Linux - Newbie 10 06-06-2017 11:56 AM
named Starts at Boot Even When Disabled? sancho Fedora 4 09-15-2006 12:48 PM
cannot start cupsd: cupsd: Child exited with status 127! kpachopoulos Debian 0 08-25-2006 08:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:25 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration