Is it fine to disable man-db.service?

i have disabled man-db.service for some reason and ive been searching answers if its okay because now I am trying to re-enable it and seems like I cant unless I needed to do as symlink as required

It is generally advised to keep that running. It periodically updates the database with the man pages ─ i.e. the formatted help pages for command-line tools.

sudo systemctl unmask man-db.service && sudo systemctl enable --now man-db.service

I got this prompt though same as early ;
The unit files have no installation config (WantedBy=, RequiredBy=, Also=,
Alias= settings in the [Install] section, and DefaultInstance= for template
units). This means they are not meant to be enabled using systemctl.

Possible reasons for having this kind of units are:
• A unit may be statically enabled by being symlinked from another unit's
  .wants/ or .requires/ directory.
• A unit's purpose may be to act as a helper for some other unit which has
  a requirement dependency on it.
• A unit may be started when needed via activation (socket, path, timer,
  D-Bus, udev, scripted systemctl call, ...).
• In case of template units, the unit is meant to be enabled with some
  instance name specified.

Ah, I see now ─ and I should have guessed it already ─ it’s a systemd timer, which will invoke the .service file when needed.

What is the output of… :arrow_down:

systemctl status man-db.timer

…?

1 Like
● man-db.timer - Daily man-db regeneration
 Loaded: loaded (/usr/lib/systemd/system/man-db.timer; disabled; vendor preset: disabled)
 Active: active (waiting) since Sun 2020-11-08 01:53:41 PST; 33min ago
Trigger: Mon 2020-11-09 00:00:00 PST; 21h left
   Triggers: ● man-db.service
 Docs: man:mandb(8)

Nov 08 01:53:41 manjaro systemd[1]: Started Daily man-db regeneration.

Well, then you don’t have to worry, because it’s running. :wink:

1 Like
 man-db.service - Daily man-db regeneration
 Loaded: loaded (/usr/lib/systemd/system/man-db.service; static)
 Active: inactive (dead) since Sun 2020-11-08 02:23:03 PST; 6min ago
TriggeredBy: ● man-db.timer
   Docs: man:mandb(8)
Process: 32944 ExecStart=/usr/bin/install -d -o root -g root -m 0755 /var/cache/man (code=exited, status=0/SUCC>
Process: 32945 ExecStart=/usr/bin/find /var/cache/man -type f -name *.gz -atime +6 -delete (code=exited, status>
Process: 32946 ExecStart=/usr/bin/mandb --quiet (code=exited, status=0/SUCCESS)
   Main PID: 32946 (code=exited, status=0/SUCCESS)

Nov 08 02:23:00 manjaro systemd[1]: Starting Daily man-db regeneration...
Nov 08 02:23:03 manjaro systemd[1]: man-db.service: Succeeded.
Nov 08 02:23:03 manjaro systemd[1]: Finished Daily man-db regeneration.

Thats kinda weird, by the way I think It was you on the other forum about boot time. and I saw that I can disable the man-db.service because it was eating my boot time when I generated the plot. so I was thinking if it may afffect any performance , because if not I may have to use sudo mandb everytime

Well, don’t recall ever having told anyone to disable that, but just in case it was me after all, maybe it was eating your boot time, and if so, then that’s because you don’t keep your system running 24/7.

GNU/Linux and all other UNIX systems are designed to keep running 24/7, and to conduct maintenance tasks in the background when the system is expected to be idle most of the time, e.g. at midnight, or at 04:00 in the morning. But if your system isn’t running when a certain task is scheduled, then this task will be executed upon the next boot.

Now, in the event of some of these tasks, you can get away with it happening only once a week, but other things are normally run at midnight every day, and so they will be run at every next boot if your system wasn’t up at midnight (or whenever it was scheduled to be running).

1 Like

Oh I sorry btw, I did not mean it was you who told to disable man-db.service. It was just me trying to figure things out.

Quick question though, is it alright that I will not be seeing the man-db.service in systemd when I boot up.?

because when I looked up this earlier, it was not there;

Nov 08 02:23:00 manjaro systemd[1]: Starting Daily man-db regeneration...
Nov 08 02:23:03 manjaro systemd[1]: man-db.service: Succeeded.
Nov 08 02:23:03 manjaro systemd[1]: Finished Daily man-db regeneration.

but if I will not see that and enable doesnt work as it should? What should I do other than running it manually as sudo mandb?

You don’t need to run it manually. You have man-db.timer running, and the timer will invoke man-db.service if and when it’s needed. That’s how it works.

As for whether you see that at boot or not, that may be due to a change in the verbosity level since you installed the system, usually due to a GRUB update ─ specifically to /etc/default/grub.

Don’t worry about it. Your post higher up states that everything is functioning normally… :arrow_down:

man-db.service - Daily man-db regeneration
 Loaded: loaded (/usr/lib/systemd/system/man-db.service; static)
 Active: inactive (dead) since Sun 2020-11-08 02:23:03 PST; 6min ago
TriggeredBy: ● man-db.timer
   Docs: man:mandb(8)
Process: 32944 ExecStart=/usr/bin/install -d -o root -g root -m 0755 /var/cache/man (code=exited, status=0/SUCC>
Process: 32945 ExecStart=/usr/bin/find /var/cache/man -type f -name *.gz -atime +6 -delete (code=exited, status>
Process: 32946 ExecStart=/usr/bin/mandb --quiet (code=exited, status=0/SUCCESS)
   Main PID: 32946 (code=exited, status=0/SUCCESS)

Nov 08 02:23:00 manjaro systemd[1]: Starting Daily man-db regeneration...
Nov 08 02:23:03 manjaro systemd[1]: man-db.service: Succeeded.
Nov 08 02:23:03 manjaro systemd[1]: Finished Daily man-db regeneration.
1 Like

Got it, thanks a lot man. Maybe one day, I’ll be back here. Have a good one.

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.