Localization & Clock Not Displaying Properly Questions...

Hi guys. I need a little help.

First is: My fresh KDE opensuse 13.1 install seems to be properly localized, but my username in the kickoff menu is not displayed properly. See here:
http://i58.tinypic.com/wtvblk.png - you can see some characters after ‘atinovi’. It’s supposed to be letter ć there. Now, usually UTF-8 takes care of it, but how can i set it to work in Kickoff?

And Two:

My clock is not displaying properly. It’s set to UTC (as suggested when installing) and my timezone is picked correctly, but it’s two hours ahead:

openSUSE:/home/nenad # date
Thu Jun 26 13:50:26 CEST 2014


CET is NOT 13:50, it’s 11:50.

etc/sysconfig/clock:

## Path:        System/Environment/Clock
## Description:        Information about your timezone and time
#
# Be aware that the time reference of the CMOS/HW clock has been
# forwarded to /etc/adjtime, the file used by hwclock(8),
# systemd(1), and the kernel as reference for the CMOS/HW clock.

## Type:        list(yes,no,)
## Description:        Write back system time to the hardware clock
#
# Is set to "yes" write back the system time to the hardware
# clock at reboot or shutdown. Usefull if hardware clock is
# much more inaccurate than system clock.  Set to "no" if
# system time does it wrong due e.g. missed timer interrupts.
# If set to "no" the hardware clock adjust feature is also
# skipped because it is rather useless without writing back
# the system time to the hardware clock.
#
# Note that you need to enable boot.clock for this feature to take
# effect.
#
# defaults to 'yes' if unset
#
SYSTOHC=""
## Description:        Write back system time if if already done by kernel
## Type:        list(no,yes)
#
# Is set to "yes" write back the system time to the hardware
# clock at reboot or shutdown eveb if this is done by the kernel
# in the so called ``Eleven Minute Mode''.
#
FORCE_SYSTOHC="no"
## Description:        HW clock is not able to use years outside 1994-1999.
## Type:        string
## Type:        list(yes,no)
#
# Indicates that the Hardware Clock is incapable of storing years
# outside the range 1994-1999.
#
BADYEAR="no"
## Description:        Overrides the default device file name
## Type:        string
#
# Overrides the default /dev file name, which is /dev/rtc on many
# platforms but may be /dev/rtc0, /dev/rtc1, and so on.
#
HCTOSYS_DEVICE=""
## Description:        Do or do not not run hwclock(8)
## Type:        list(yes,no,)
#
# Set this to yes if it is possible to access the hardware clock,
# or no if it is not.  On some platforms (s390 or xen) this may
# overwritten by the service its self.
#
USE_HWCLOCK="yes"
## Description:        Correct systematic drift of the HW clock
## Type:        list(yes,no,)
#
# Add or subtract time from the Hardware Clock to account for
# systematic drift since the last time the clock was set or
# adjusted. By default off as this can cause trouble.  For
# systems using localtime for HW clock this will ignored.
#
USE_ADJUST="no"

## Type:        string(Europe/Berlin,Europe/London,Europe/Paris)
## ServiceRestart:    boot.clock
## Command:        /sbin/refresh_initrd
#
# Timezone (e.g. CET or Asia/Tokyo). The value should correspond
# to the contents of the /etc/localtime file and is for internal
# YaST use only.
#
TIMEZONE="Europe/Ljubljana"
DEFAULT_TIMEZONE="Europe/Ljubljana"


You can see below, the timezone is set correctly.

and

/etc/adjtime

0.000000 1403779132 0.000000
1403779132
UTC

I am NOT dual booting, it’s only openSUSE 13.1.

Thankful in advance for your help.

Kickoff should just use KDE’S Locale settings. So have a look in “Configure Desktop”->Locale.

But maybe it is a fonts issue? Try to choose a different font in “Configure Desktop”->“Application Appearance”->Fonts.

And check that your locale settings are really UTF-8, run this as user:

locale

And Two:

My clock is not displaying properly. It’s set to UTC (as suggested when installing) and my timezone is picked correctly, but it’s two hours ahead:

You can explicitely configure which timezone the panel’s clock should display. Just right-click on it and select “Digital Clock Settings…”.

It should show the local time by default, but maybe your country is not configured properly in KDE’s locale settings?

Btw, it is possible to enable more than one time zone for the clock, and then switch between them with the mouse wheel. It can happen that this is done accidentally, though… :wink:

Hi wolfi, thanks for your answers.

With the first, the output is here:

nenad@openSUSE:~> locale
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=sl_SI.UTF-8
LC_CTYPE="sl_SI.UTF-8"
LC_NUMERIC="sl_SI.UTF-8"
LC_TIME=sl_SI-UTF.8
LC_COLLATE="sl_SI.UTF-8"
LC_MONETARY="sl_SI.UTF-8"
LC_MESSAGES="sl_SI.UTF-8"
LC_PAPER="sl_SI.UTF-8"
LC_NAME="sl_SI.UTF-8"
LC_ADDRESS="sl_SI.UTF-8"
LC_TELEPHONE="sl_SI.UTF-8"
LC_MEASUREMENT="sl_SI.UTF-8"
LC_IDENTIFICATION="sl_SI.UTF-8"
LC_ALL=


The first line is what worries me. Any ideas why it’s like that?

And for the second, i did that also, and it doesn’t work. :frowning:

On 2014-06-26 11:56, holden87 wrote:

> My clock is not displaying properly. It’s set to UTC (as suggested when
> installing)

No, it is not.

The suggestion on install is to set the hardware aka cmos clock to UTC.

> and my timezone is picked correctly, but it’s two hours
> ahead:
>
>
> Code:
> --------------------
> openSUSE:/home/nenad # date
> Thu Jun 26 13:50:26 CEST 2014

> --------------------
>
>
> CET is NOT 13:50, it’s 11:50.

Please run and paste back here (starting in a terminal as plain user):


date
date --utc
locale
ls -l /etc/localtime
cat /etc/adjtime
su -
hwclock --debug
date
date --utc
locale

And also print the correct wall clock time (local, and utc if you know it).

That’s all I can think at the minute :-))


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

On 2014-06-26 12:06, wolfi323 wrote:
> You can explicitely configure which timezone the panel’s clock should
> display. Just right-click on it and select “Digital Clock Settings…”.

Not yet, as the time shown by the terminal is wrong. We have to correct
that one first, and forget KDE completely for the time being.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

On 2014-06-26 12:26, holden87 wrote:

> The first line is what worries me. Any ideas why it’s like that?

Because sl_SI.UTF-8 locale does not exist. it is “sl_SI.utf8”


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

Well, that’s definitely not normal.

Can you check whether /etc/localtime exists and is a valid link to a timezone file?

ls -l /etc/localtime

And as the locales are contained in the package “glibc-locale”, verify it:

rpm -V glibc-locale

No output means that everything should be OK.

And for the second, i did that also, and it doesn’t work. :frowning:

You did what?
Is your country set in KDE’s locale settings?
What gets shown in the popup when you hover over the clock?

nenad@openSUSE:~> date
Thu Jun 26 14:40:57 CEST 2014


nenad@openSUSE:~> date --utc
Thu Jun 26 12:41:17 UTC 2014


nenad@openSUSE:~> locale
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=sl_SI.UTF-8
LC_CTYPE="sl_SI.UTF-8"
LC_NUMERIC="sl_SI.UTF-8"
LC_TIME=sl_SI-UTF.8
LC_COLLATE="sl_SI.UTF-8"
LC_MONETARY="sl_SI.UTF-8"
LC_MESSAGES="sl_SI.UTF-8"
LC_PAPER="sl_SI.UTF-8"
LC_NAME="sl_SI.UTF-8"
LC_ADDRESS="sl_SI.UTF-8"
LC_TELEPHONE="sl_SI.UTF-8"
LC_MEASUREMENT="sl_SI.UTF-8"
LC_IDENTIFICATION="sl_SI.UTF-8"
LC_ALL=


nenad@openSUSE:~> ls -l /etc/localtime
lrwxrwxrwx 1 root root 38 Jun 26 12:41 /etc/localtime -> ../usr/share/zoneinfo/Europe/Ljubljana


nenad@openSUSE:~> su -
Password: 
-bash: warning: setlocale: LC_TIME: cannot change locale (sl_SI-UTF.8): No such file or directory


openSUSE:~ # hwclock --debug
hwclock from util-linux 2.23.2
Using /dev interface to clock.
Last drift adjustment done at 1403779132 seconds after 1969
Last calibration done at 1403779132 seconds after 1969
Hardware clock is on UTC time
Assuming hardware clock is kept in UTC time.
Waiting for clock tick...

...got clock tick
Time read from Hardware Clock: 2014/06/26 12:43:19
Hw clock time : 2014/06/26 12:43:19 = 1403786599 seconds since 1969
Thu Jun 26 14:43:19 2014  -0.531985 seconds


openSUSE:~ # date
Thu Jun 26 14:44:08 CEST 2014


openSUSE:~ # date --utc
Thu Jun 26 12:44:31 UTC 2014


openSUSE:~ # locale
LANG=POSIX
LC_CTYPE=sl_SI.UTF-8
LC_NUMERIC="POSIX"
LC_TIME="POSIX"
LC_COLLATE="POSIX"
LC_MONETARY="POSIX"
LC_MESSAGES="POSIX"
LC_PAPER="POSIX"
LC_NAME="POSIX"
LC_ADDRESS="POSIX"
LC_TELEPHONE="POSIX"
LC_MEASUREMENT="POSIX"
LC_IDENTIFICATION="POSIX"
LC_ALL=


Here it is.

I’d like to point out that where i live, utc is displaying the correct time of the two commands posted above…

Hm, where does that sl_SI-UTF.8 come from?

Strange enough, it seems to work fine here: (at least there’s no error message)

LC_ALL=sl_SI.UTF-8 locale
LANG=de_AT.UTF-8
LC_CTYPE="sl_SI.UTF-8"
LC_NUMERIC="sl_SI.UTF-8"
LC_TIME="sl_SI.UTF-8"
LC_COLLATE="sl_SI.UTF-8"
LC_MONETARY="sl_SI.UTF-8"
LC_MESSAGES="sl_SI.UTF-8"
LC_PAPER="sl_SI.UTF-8"
LC_NAME="sl_SI.UTF-8"
LC_ADDRESS="sl_SI.UTF-8"
LC_TELEPHONE="sl_SI.UTF-8"
LC_MEASUREMENT="sl_SI.UTF-8"
LC_IDENTIFICATION="sl_SI.UTF-8"
LC_ALL=sl_SI.UTF-8

So what about “rpm -V glibc-locale”?
Does /usr/lib/locale/sl_SI.utf8 exist?

Can you please post /etc/sysconfig/language as well?

Oh my, yes, sl_SI.utf8 worked. All correct now.

Any way, any idea about the clock? thanks!

Well, actually “sl_SI.UTF-8” should work as well.
But your error message talked about “sl_SI-UTF.8” (notice that the ‘-’ and ‘.’ are swapped)…

Any way, any idea about the clock? thanks!

Yes, what I wrote already.
Is the default set to “local time” in the clock’s settings?
Is the correct country set in KDE’s Locale settings?

What does the clock show when you hover over it with the mouse?

Does “date” show the correct time now?
If not, adjust the time (in YaST->System->Date and Time f.e.). Does it work for KDE’s clock then as well?

Hey.

Now I won’t be much of a help. I meddled around with the clock settings, not sure what i did, but it works now.

On 2014-06-26 12:46, holden87 wrote:
>
> Code:
> --------------------
> nenad@openSUSE:~> date
> Thu Jun 26 14:40:57 CEST 2014
> nenad@openSUSE:~> date --utc
> Thu Jun 26 12:41:17 UTC 2014

> nenad@openSUSE:~> su -
> Password:
> -bash: warning: setlocale: LC_TIME: cannot change locale (sl_SI-UTF.8): No such file or directory
>

> openSUSE:~ # hwclock --debug
> hwclock from util-linux 2.23.2

> Hardware clock is on UTC time
> Assuming hardware clock is kept in UTC time.
> Waiting for clock tick…
>
> …got clock tick
> Time read from Hardware Clock: 2014/06/26 12:43:19
> Hw clock time : 2014/06/26 12:43:19 = 1403786599 seconds since 1969
> Thu Jun 26 14:43:19 2014 -0.531985 seconds

> openSUSE:~ # date
> Thu Jun 26 14:44:08 CEST 2014

> openSUSE:~ # date --utc
> Thu Jun 26 12:44:31 UTC 2014
>
>
> --------------------

Well, both root and user get the same clock time, and the local to utc
time difference is correct, 2 hours. Cmos clock is consistent with the
settings.

What was the clock on the kitchen wall showing? 12:44?

My guess at this point is that you simply have set the time wrong on the
computer and that you have to correct it, simple as that.

DO NOT SET IT UP USING KDE.

Use YaST - I don’t remember this moment if you can “write” the hour in
there. If not, use the command “date” to set the hour, on the command
line, as root. “man date” says how. (1)

Once done, run:


rm /etc/adjtime
hwclock --systohc --utc
hwclock --debug
date

The last two commands should sow the correct time and date.

(1) Alternative:


rcntp ntptimeset

… assuming there are some time servers defined in /etc/ntp.conf, like
this:


server 0.pool.ntp.org
server 1.pool.ntp.org
server 2.pool.ntp.org
server 3.pool.ntp.org

and that Internet works.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

rm /etc/adjtime
hwclock --systohc --utc
hwclock --debug
date

Hey Robin. The problem reappeared upon boot, but this fixed it (and YaST).

Thank you once again!

On 2014-06-27 08:26, holden87 wrote:

> Code:
> --------------------
> > >
> > rm /etc/adjtime
> > hwclock --systohc --utc
> > hwclock --debug
> > date
> >
> --------------------

>
> Hey Robin. The problem reappeared upon boot, but this fixed it (and
> YaST).

Ha!

I knew :slight_smile:

You are not the first one to have that problem.

The “/etc/adjtime” keeps track of the adjustment that has to be done on
boot. If you adjust the clock manually one hour forward, it may think
that it has to speed up the clock one hour per day (quite incorrect
explanation, but approximate enough). So delete the file, then create it
again blank (second line). Then verify (next two lines).

> Thank you once again!

Welcome.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)