Re: setting time in QEMU image

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/30/2017 02:33 AM, Robert Moskowitz wrote:
I have a F21 QEMU image.  Use it for a number of things and not too
interested in updating it.  I like gthumb from back then.  They have
ruined a nice simple image viewer.

Anyway, the issue is system time when I resume the image.  The image was
paused, as I have learned that if I suspend the system without pausing
this QEMU F21 image, said image runs at 100% cpu and will not respond
unless I kill it.   Pausing it avoids this most of the time.

When I reenter the image, the clock is off and it rarely resets.  So far
I have used system-config-time to kick off ntpdate, or whatever it is
using.  This is a time consuming process and it locks the system,
requiring me to reenter my password (which I had to do for
system-config-time).

Is there some cli that I can easily use to reset the time of the image.

Note that the main image, F24 always has the right time.

How about fetching the time from F24 and using that to set the current local time, then leave it up to ntp to make it exact?

Something like:

#!/bin/bash

# fetch date from a current time source
DATE=$(ssh -t user@F24 date +%m%d%H%M%S)

# ssh appends a \r to its results; this will trim it
DATE="${DATE%"${DATE##*[![:space:]]}"}"

# set the date
date $(echo -n $DATE)
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux