[sles-beta] A Problem with KVM Guest ?

Michal Svec msvec at suse.com
Thu Sep 4 09:47:28 MDT 2014


On Thu, 4 Sep 2014, Günther J. Niederwimmer wrote:

> Am Donnerstag, 4. September 2014, 16:47:23 schrieb Antoine Ginies:
>> Günther J. Niederwimmer:
>>> Hello Antoine,
>>>
>>> Am Donnerstag, 4. September 2014, 16:23:29 schrieb Antoine Ginies:
>>>> Günther J. Niederwimmer:
>>>>> Am Donnerstag, 4. September 2014, 13:57:01 schrieb Antoine Ginies:
>>>>>> Günther J. Niederwimmer:
>>>>>>> Am Donnerstag, 4. September 2014, 12:24:02 schrieb Antoine Ginies:
>>>>>>>> Günther J. Niederwimmer:
>>>>>>>>> Hello,
>>>>>>>>> I found a Problem with KVM_clock?
>>>>>>>>> on my Installation I have a KVM Server and KVM Clients all
>>>>>>>>> SLES 12
>>>>>>>>> Server
>>>>>>>>> The KVM Host have a NTP Server configured and have a correct
>>>>>>>>> time
>>>>>>>>>
>>>>>>>>> date
>>>>>>>>> Don Sep  4 12:00:19 CEST 2014
>>>>>>>>> all clients have this Time
>>>>>>>>> date
>>>>>>>>> Don Sep  4 02:15:24 CEST 2014
>>>>>>>>>
>>>>>>>>> the timezone is correct but the time is wrong ?
>>>>>>>>
>>>>>>>> Hello,
>>>>>>>> Can you check that your VM is currently using kvm_clock?
>>>>>>>
>>>>>>> akerb:~ # dmesg | grep kvm-clock
>>>>>>> [    0.000000] kvm-clock: Using msrs 4b564d01 and 4b564d00
>>>>>>> [    0.000000] kvm-clock: cpu 0, msr 1:3ff18001, boot clock
>>>>>>> [    0.000000] kvm-clock: cpu 0, msr 1:3ff18001, primary cpu clock
>>>>>>> [    0.004000] kvm-clock: cpu 1, msr 1:3ff18041, secondary cpu
>>>>>>> clock
>>>>>>> [    0.004000] kvm-clock: cpu 2, msr 1:3ff18081, secondary cpu
>>>>>>> clock
>>>>>>> [    0.004000] kvm-clock: cpu 3, msr 1:3ff180c1, secondary cpu
>>>>>>> clock
>>>>>>> [    0.134685] Switched to clocksource kvm-clock
>>>>>>>
>>>>>>> This is the client
>>>>>>>
>>>>>>> root# cat
>>>>>>> /sys/devices/system/clocksource/clocksource0/current_clocksource
>>>>>>
>>>>>> You forget the value, but according to dmesg it was kvm-clock at
>>>>>> 0.134685 until something else has switched to another value.
>>>>>
>>>>> I mean we miss understand  use
>>>>>
>>>>> The behind is from a CLIENT
>>>>
>>>> kvm-clock clocksource is for the VM guest.
>>>>
>>>>> This is from the HOST !!
>>>>
>>>> The host doesn't provide kvm-clock source:
>>>> -----------------------------------------
>>>> root # cat
>>>> /sys/devices/system/clocksource/clocksource0/available_clocksource tsc
>>>> hpet
>>>> acpi_pm
>>>> -----------------------------------------
>>>>
>>>> It's tsc by default.
>>>> So everything is ok.
>>> :
>>> :-))).
>>>
>>> why I have then a wrong Time !
>>
>> Perhaps the ntpd service was not started on the host before the VM guest
>> start? have you tried to start the ntpd server on the host, then
>> start a VM guest and check if time are synchronized?
>
> Yes, you are right, this is the Problem, NTP Server is starting to late for
> the VM clients
>
> always this Problems with systemd :-(.
>
> Now I have to check what can I do, a kerberos test in the moment is not the
> best Timing ;-)
>
> Thanks, I hope you find a way to clear this Problem.

This indeed sounds like a bug (in boot order dependencies), please open a 
Service Request and we will have a look at a fix.

Thanks!
Michal



> Thanks again.
>
>>> anything must be wrong, the question is what?
>>>
>>>>>  dmesg | grep clocksource
>>>>>
>>>>> [    0.560063] Switched to clocksource hpet
>>>>> [    2.329666] tsc: Refined TSC clocksource calibration: 3700.000 MHz
>>>>> [    3.645349] Switched to clocksource tsc
>>>>>
>>>>> and I like to change this for Tests.
>>>>>
>>>>>> ------------
>>>>>> root # dmesg | grep clocksource
>>>>>> ------------
>>>>>> will let you know if there is any change.
>>>>>>
>>>>>>> I have on the Server
>>>>>>> tsc
>>>>>>>
>>>>>>> This is a original YaSt Installation
>>>>>>>
>>>>>>> can I change this manual ?
>>>>>>
>>>>>> On VM guest you can change it with echo:
>>>>>> ----------
>>>>>> echo tsc >
>>>>>> /sys/devices/system/clocksource/clocksource0/current_clocksource
>>>>>> echo kvm-clock >
>>>>>> /sys/devices/system/clocksource/clocksource0/current_clocksource
>>>>>> ----------
>>>>>>
>>>>>> You should see a dmesg in the console of your VM guest saying that
>>>>>> clocksource has switched.
>>>>>
>>>>> Have I to open a SR ?
>
> -- 
> mit freundlichen Grüßen / best Regards,
>
>  Günther J. Niederwimmer
> _______________________________________________
> sles-beta mailing list
> sles-beta at lists.suse.com
> http://lists.suse.com/mailman/listinfo/sles-beta
>


More information about the sles-beta mailing list