Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: [SOLVED] KDE Plasma "set date and time automatically" greyed (inactive) (Read 205 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

[SOLVED] KDE Plasma "set date and time automatically" greyed (inactive)

Adjust Date and time - set date and time automatically check box is inactive in KDE Plasma 5.19.5

Artix OpenRC
rc (OpenRC) 0.42.1 (Artix Linux)
Kernel Version 5.8.6-artix1-1

I can still change the time with hwclock config file and the time works correctly, but it takes no effect on the set date and time automatically check box anyway.

I installed Artix from base: artix-base-openrc-20200214-x86_64.iso NOT the ISO with plasma (artix-plasma-openrc-20200210-x86_64.iso). And after the clean installation i installed xorg, SDDM and KDE Plasma packages.

On Arch wiki in Network Time Protocol daemon - https://wiki.archlinux.org/index.php/Network_Time_Protocol_daemon is said that:
"KDE can use NTP (ntp must be installed) by right clicking the clock and selecting Adjust date/time. However, this requires the ntp daemon to be disabled before configuring KDE to use NTP". But is there any possibility how to fix it now?


Thank you
MatMac

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #1

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #2
I've been looking at it, and the solution is not simple, KDE need ntpdate (which we have in the system), but then it can't recognize it for some reason.
This is written on the KDE man page:

Quote
If you check Set date and time automatically this module will use systemd to fetch date and time.
On a computer without systemd the NTP utilities rdate or ntpdate are used. If these utilities are missing please install them.
When you log in to the Plasma™ session while being online or when you later connect to the Internet the access to one or more NTP servers happens.

Anyway, a better solution than this is to install ntp and ntp-openrc/runit/s6 and add the time synchronization service as startup service (rc-update add ntp-client default).

Simple, KDE-independent and functional solution...

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #3
Thank you for the quick answer alium.

This is not a big deal since it is possible to update the time with the config files.

Anyway when I'm trying to start the NTP service manually i get this error:

Code: [Select]
[[email protected] ~]$ sudo pacman -S ntp
[sudo] password for MatMac:
warning: ntp-4.2.8.p15-1 is up to date -- reinstalling
resolving dependencies...
looking for conflicting packages...

Packages (1) ntp-4.2.8.p15-1

Total Installed Size:  4.46 MiB
Net Upgrade Size:      0.00 MiB

:: Proceed with installation? [Y/n]
(1/1) checking keys in keyring                                               [############################################] 100%
(1/1) checking package integrity                                             [############################################] 100%
(1/1) loading package files                                                  [############################################] 100%
(1/1) checking for file conflicts                                            [############################################] 100%
(1/1) checking available disk space                                          [############################################] 100%
:: Processing package changes...
(1/1) reinstalling ntp                                                       [############################################] 100%
:: Running post-transaction hooks...
(1/1) Creating system user accounts...
[[email protected] ~]$ sntp --version
sntp [email protected] Wed Jul  1 22:47:02 UTC 2020 (1)
[[email protected] ~]$ rc-service hwclock status
 * status: started
[[email protected] ~]$ rc-service ntp status
 * rc-service: service `ntp' does not exist
[[email protected] ~]$ rc-service ntpd status
 * rc-service: service `ntpd' does not exist
[[email protected] ~]$ rc-service ntpdate status
 * rc-service: service `ntpdate' does not exist
[[email protected] ~]$ sudo pacman -S ntpdate
error: target not found: ntpdate

This is a bit off topic but I'm curious how the ntp works.

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #4
To see what "services" are included in package run:
Code: [Select]
$ pacman -Ql ntp-openrc
ntp-openrc /etc/
ntp-openrc /etc/conf.d/
ntp-openrc /etc/conf.d/ntp-client
ntp-openrc /etc/conf.d/ntpd
ntp-openrc /etc/conf.d/sntp
ntp-openrc /etc/init.d/
ntp-openrc /etc/init.d/ntp-client
ntp-openrc /etc/init.d/ntpd
ntp-openrc /etc/init.d/sntp

From this list you can see 3 services (init.d) with respective config files (conf.d):
  • ntp-client
  • ntpd
  • sntp

you probably wish to start ntpd:
Code: [Select]
rc-service ntpd start
Man is as good as his tools.

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #5
as wrote SGOrava...

I use 'ntp-client' and 'networkmanager-dispatcher-ntp-client' from our universe repo (networkmanager-dispatcher-ntp-client re-start ntp-client, if i will have internet access)

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #6
OK, thank you guys. I installed the NTP with "pacman -S ntp-openrc" instead of "pacman -S ntp" and it works well.

So, if I have installed the "artix-plasma-openrc-20200210-x86_64.iso" would I get the same issue with "set date and time automatically" check box?

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #7
OK, thank you guys. I installed the NTP with "pacman -Ql ntp-openrc" instead of "pacman -S ntp" and it works well.

So, if I have installed the "artix-plasma-openrc-20200210-x86_64.iso" would I get the same issue with "set date and time automatically" check box?
Yes. you must just install ntp and his service again

Re: KDE Plasma "set date and time automatically" greyed (inactive)

Reply #8
since Plasma 5.20 is this option (feature) available again!