| Summary: | Improve error message when requested dump directory does not exist | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 6 | Reporter: | Doron Fediuck <dfediuck> |
| Component: | libvirt | Assignee: | Eric Blake <eblake> |
| Status: | CLOSED DUPLICATE | QA Contact: | Virtualization Bugs <virt-bugs> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 6.5 | CC: | acathrow, berrange, bili, dallan, dfediuck, dyuan, eblake, jdenemar, jtomko, mjenner, mzhan, tlavigne |
| Target Milestone: | rc | ||
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | 1004400 | Environment: | |
| Last Closed: | 2014-04-02 07:03:12 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Bug Depends On: | 1004400 | ||
| Bug Blocks: | |||
|
Description
Doron Fediuck
2013-09-16 14:38:00 UTC
Hi Doron, How did you get the situation that dir missing? It will be created automatically after start libvirtd in my test. A clean rhel6.4 os, install libvirt, and the start libvirtd: # cat /etc/redhat-release Red Hat Enterprise Linux Server release 6.4 (Santiago) # yum install -y libvirt # ll /var/lib/libvirt/qemu/ total 0 # service libvirtd start Starting libvirtd daemon: [ OK ] # ll /var/lib/libvirt/qemu/ total 12 drwxr-xr-x. 2 root root 4096 Sep 24 05:52 dump drwxr-xr-x. 2 qemu qemu 4096 Sep 24 05:52 save drwxr-xr-x. 2 qemu qemu 4096 Sep 24 05:52 snapshot I think you should start libvirtd service to do the action of crashing guest. But that dump path is created automatically. Thanks, EricLee I've confirmed that 'virsh dump' autocreates the directory for libvirt-1.1.2-2.fc19.x86_64; I still need to play with watchdog dumps (if that's a different directory that forgets to auto-create) as well as test older libvirt versions. (In reply to Eric Blake from comment #3) > I've confirmed that 'virsh dump' autocreates the directory for > libvirt-1.1.2-2.fc19.x86_64; I still need to play with watchdog dumps (if > that's a different directory that forgets to auto-create) as well as test > older libvirt versions. Hi Eric, I have tested that in RHEL6.5 libvirt-0.10.2-26.el6.x86_64, 'virsh dump' will not autocreate directory if not existing, and will throw error: # virsh dump aa /dir/not/exist/aa.dump error: Failed to core dump domain aa to /dir/not/exist/aa.dump error: Failed to create file '/dir/not/exist/aa.dump': Operation not permitted and I got the same error log in libvirtd.log when use watchdog to dump the guest to not existing dir. Thanks, EricLee (In reply to EricLee from comment #5) > (In reply to Eric Blake from comment #3) > > I've confirmed that 'virsh dump' autocreates the directory for > > libvirt-1.1.2-2.fc19.x86_64; I still need to play with watchdog dumps (if > > that's a different directory that forgets to auto-create) as well as test > > older libvirt versions. > > Hi Eric, > > I have tested that in RHEL6.5 libvirt-0.10.2-26.el6.x86_64, 'virsh dump' > will not autocreate directory if not existing, and will throw error: > > # virsh dump aa /dir/not/exist/aa.dump > error: Failed to core dump domain aa to /dir/not/exist/aa.dump > error: Failed to create file '/dir/not/exist/aa.dump': Operation not > permitted > > and I got the same error log in libvirtd.log when use watchdog to dump the > guest to not existing dir. > > Thanks, > EricLee Explicitly requesting to dump to /dir/not/exist is not the same as automatic dumping to a default of /var/lib/libvirt/qemu/dump/. Since no one is able to prove that the automatic directory creation on watchdog action is not working, I'm closing this as not a bug. We can reopen it if someone provides evidence of an actual problem. I did some git spelunking; we have been autocreating since at least commit e123e1ee (v0.9.4). I will also point out that we do not install the /var/lib/libvirt/qemu/save/ directory in the spec file (used by managedsave) - if automatic creation isn't working, I would suspect that it would be a problem for more than just dump images. Hi Eric, I think the error message for not exist directory is not specific.Is it possible to change it to "cannot access /dir/not/exist/: No such file or directory"? (In reply to hyao from comment #7) > Hi Eric, > > I think the error message for not exist directory is not specific.Is it > possible to change it to "cannot access /dir/not/exist/: No such file or > directory"? Yes, it's probably possible to enhance the error message quality, but it's lower priority than the original report. The bug in the error message is already tracked by bug 851411. *** This bug has been marked as a duplicate of bug 851411 *** |