Bug 208413 - No error message when image file creation fails
No error message when image file creation fails
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: virt-manager (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Hugh Brock
Martin Jenner
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-09-28 10:05 EDT by Mark McLoughlin
Modified: 2008-03-12 15:51 EDT (History)
3 users (show)

See Also:
Fixed In Version: 0.5.2
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-03-12 15:51:58 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Mark McLoughlin 2006-09-28 10:05:36 EDT
When creating a new domain, if you enter a path to a file in a directory which
doesn't exist, then domain creation fails with no error message.

Just this traceback on the console:

Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib64/python2.4/threading.py", line 442, in __bootstrap
    self.run()
  File "/usr/share/virt-manager/virtManager/asyncjob.py", line 35, in run
    threading.Thread.run(self)
  File "/usr/lib64/python2.4/threading.py", line 422, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/usr/share/virt-manager/virtManager/create.py", line 358, in do_install
    guest.start_install(False)
  File "/usr/lib/python2.4/site-packages/xeninst/ParaVirtGuest.py", line 194, in
start_install
    return XenGuest.XenGuest.start_install(self, consolecb)
  File "/usr/lib/python2.4/site-packages/xeninst/XenGuest.py", line 278, in
start_install
    self._create_devices()
  File "/usr/lib/python2.4/site-packages/xeninst/XenGuest.py", line 192, in
_create_devices
    disk.setup()
  File "/usr/lib/python2.4/site-packages/xeninst/XenGuest.py", line 53, in setup
    fd = os.open(self.path, os.O_WRONLY | os.O_CREAT)
OSError: [Errno 2] No such file or directory: '/foo/bar.img'
Comment 1 Daniel Berrange 2006-10-27 10:40:29 EDT
We need to prompt the user to confirm whether they want us to create the
directory, or let then choose a different directory. Also need to check the dir
is writable too, and warn them if they choose something which is not /xen when
SELinux is enabled.

Comment 2 Hugh Brock 2007-06-14 12:31:59 EDT
You know, none of this was a problem when we made the user use the file chooser
dialog to choose their file, rather than entering the path and the file by hand.
Now we are slowly re-implementing the file chooser dialog in our own code. Are
we sure we don't want to just remove the manual path entry?
Comment 3 Daniel Berrange 2007-06-14 12:34:07 EDT
We need to have validation here. Medium term the file chooser will have to go
away because its useless when managing a remote maachine. We'll have storage
maangement APIs in libvirt to enumerate existing images in directories, and/or
allocate new ones.
Comment 4 Hugh Brock 2007-06-18 12:58:43 EDT
OK, fine, but in that case I think we ought to wait for the storage management
APIs to be finished before we start implementing validation. One hopes that that
will keep us from having to do things like "warn them if they choose something
which is not /xen when SELinux is enabled" and other horrible spaghetti...
Comment 5 Red Hat Bugzilla 2007-07-24 22:06:03 EDT
change QA contact
Comment 6 Cole Robinson 2008-03-12 15:51:58 EDT
The validation for this has been present for some time, and is definitely
present in f7 and f8. Closing as CURRENTRELEASE.

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