Bug 831174 - qemu-ga default statedir should be /run
qemu-ga default statedir should be /run
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm (Show other bugs)
7.0
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Luiz Capitulino
Virtualization Bugs
:
: 836275 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-06-12 08:03 EDT by Paolo Bonzini
Modified: 2014-06-17 23:17 EDT (History)
6 users (show)

See Also:
Fixed In Version: qemu 1.3
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-06-13 08:12:28 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Paolo Bonzini 2012-06-12 08:03:20 EDT
Description of problem:
qemu-ga stores the fsfreeze state in /tmp.  For RHEL7, /run would be a better match.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. Run "qemu-ga --help"
  
Actual results:
The default statedir is shown to be /tmp.

Expected results:
The default statedir is shown to be /run.

Additional info:
Upstream we should probably make the default changeable at configure-time, so that the RHEL7 patch would touch the spec file only.
Comment 1 Luiz Capitulino 2012-10-08 12:02:58 EDT
Patches posted upstream and have already been accepted by qemu-ga's maintainer:

https://lists.gnu.org/archive/html/qemu-devel/2012-10/msg00476.html
Comment 2 Luiz Capitulino 2012-10-15 12:53:50 EDT
Merged upstream (commits 785c23ae5c and 6a3c8c14c). To test this, run latest qemu-ga in the guest, freeze the FS and do:

 # ls -la /var/run/ (or /usr/local/var/run)

And check if a file named qga.state.isfrozen has been created.
Comment 3 Paolo Bonzini 2012-10-25 09:51:00 EDT
*** Bug 836275 has been marked as a duplicate of this bug. ***
Comment 5 langfang 2014-01-25 22:38:44 EST
Verify this bug as follow version:
Host:
# uname -r
3.10.0-79.el7.x86_64
# rpm -q qemu-kvm
qemu-kvm-1.5.3-41.el7.x86_64

Guest:RHEl7

qemu-guest-agent-1.5.3-41.el7.x86_64.rpm 

Steps:
1.# qemu-ga --help
...
  -t, --statedir    specify dir to store state information (absolute paths
                    only, default is /var/run)
...
2.on host
#nc -U /tmp/qga.sock
{"execute":"guest-fsfreeze-freeze" }
{"return": 2}
3. check state file
# ll /var/run/qga.state 
-rw-r--r--. 1 root root 25 Jan 25 22:33 /var/run/qga.state

Results:
After step 1:The Paths is /var/run
After step 3: A file named qga.state.isfrozen has been created.


According to above test ,this bug fixed.
Comment 7 Ludek Smid 2014-06-13 08:12:28 EDT
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.

Note You need to log in before you can comment on or make changes to this bug.