You are not logged in.

#1 2021-10-15 02:32

Tolkem
Member
Registered: 2019-10-06
Posts: 487

Prevent password dialog from appearing when adjusting time.

Hi everyone! Hope you're all having a nice life! smile

In another thread https://www.q4os.org/forum/viewtopic.php?id=3809 I said I installed Q4OS in a friend's desktop PC, my friend's a 60-year-old lady, and doesn't know much about computers, so I'm setting Q4OS in a way she doesn't need to type in passwords or any of that sort, however, I noticed that whenever the PC's turned off and on again, the clock is reset, seems the CMOS battery is dead, so once in the desktop time and date must be set up every time this happens, but a password dialog appears. I could explain my friend this, and I think it's a fairly easy procedure she could follow, but I was wondering whether there's a way she doesn't have to, is there?

Any help/advice is much appreciated. smile

Offline

#2 2021-10-15 06:03

bin
Member
From: U.K.
Registered: 2016-01-28
Posts: 1,298

Re: Prevent password dialog from appearing when adjusting time.

First of all - please do not do anything else with UA on that machine. You've already seen what happens to updates if the date and time are wrong.

Investigate a replacement CMOS battery. You say it's a desktop machine - most of the time that's a 5 minute job. If you cannot fix it or it cannot be replaced then a used ex corporate machine would be a cheap alternative.

Offline

#3 2021-10-15 08:09

hchiper
Member
From: Belgium
Registered: 2020-07-28
Posts: 371

Re: Prevent password dialog from appearing when adjusting time.

bin wrote:

You say it's a desktop machine - most of the time that's a 5 minute job.

bin's suggestion is really the best you can do. At least open the box and look at the battery. I've always seen they are common CR2032 or alike, easy to remove and replace.

Otherwise your friend will end up in no more setting the date and time at each power on, problems will arise and you'll have to solve them endlessly.


Q4OS machines: [Samsung R519 - Pentium T4200 2.0 GHz - 4 GB RAM - 500 GB SSD] & [Sony Vaio - Pentium P6000 1.87 GHz - 8 GB RAM - 500 GB SSD]

Offline

#4 2021-10-15 12:10

Tolkem
Member
Registered: 2019-10-06
Posts: 487

Re: Prevent password dialog from appearing when adjusting time.

Thank you both for your replies. Yes, of course replacing the CMOS battery is the ideal solution, and that's what I plan to do, however, I wanted to know if it was possible to prevent the password dialog from appearing, so it stops bothering until the battery gets replaced, Is it possible?

Offline

#5 2021-10-15 12:44

Midas
Member
Registered: 2017-12-15
Posts: 167

Re: Prevent password dialog from appearing when adjusting time.

I'm way out of my depth here, but maybe a script to set the time via terminal (with the required permissions) could be called every time the PC comes on...?

Offline

#6 2021-10-15 14:40

Tolkem
Member
Registered: 2019-10-06
Posts: 487

Re: Prevent password dialog from appearing when adjusting time.

Midas wrote:

I'm way out of my depth here

So am I lol

but maybe a script to set the time via terminal (with the required permissions) could be called every time the PC comes on...?

Yes, a script might work, but I think this could be better handled by editing some policy file, but I don't know where or how to do that. I'm reading about it
https://wiki.debian.org/PolicyKit
https://www.freedesktop.org/software/po … cs/latest/

Offline

#7 2021-10-15 17:08

bin
Member
From: U.K.
Registered: 2016-01-28
Posts: 1,298

Re: Prevent password dialog from appearing when adjusting time.

Well - one way would be to look at /opt/trinity/share/applications/clock.desktop

The date and time is controlled via /opt/trinity/bin/tdecmshell calling clock.desktop - this requires root/sudo permission

Looking at clock.desktop you can see X-TDE-Rootonly=true

This suggests that it could be false or no or just commented out. Not sure but it may be a way to allow that to be called via a bsah script at startup........but TBH just fix the flippin clock!!!

Offline

#8 2021-10-16 13:58

Tolkem
Member
Registered: 2019-10-06
Posts: 487

Re: Prevent password dialog from appearing when adjusting time.

bin wrote:

Well - one way would be to look at /opt/trinity/share/applications/clock.desktop

The date and time is controlled via /opt/trinity/bin/tdecmshell calling clock.desktop - this requires root/sudo permission

Looking at clock.desktop you can see X-TDE-Rootonly=true

This suggests that it could be false or no or just commented out. Not sure but it may be a way to allow that to be called via a bsah script at startup........but TBH just fix the flippin clock!!!

The tool tdecmshell is something like kdialog or zenity used to create dialog boxes. Yes, I already tried editing that file with no luck. Of course, fixing the CMOS battery is the ideal, thing is, I don't know whether they  sell them somewhere around here, so it'd probably need to be bought downtown, and right now I don't have time to do that, and she won't go on her own. That's why I'd like to do this as a workaround until the battery is replaced. I'll try this https://wiki.archlinux.org/title/Polkit … ord_prompt

Offline

Board footer

Powered by FluxBB