[Yahoo-eng-team] [Bug 1464991] [NEW] Errors are not handled correctly during image updates
Public bug reported: To reproduce: Log in to horizon as unprivileged user. Navigate to image editing, try to mark an image as public. Observed result: an error message, stating: Danger: There was an error submitting the form. Please try again. Logs indicate, that an UnboundLocalError occurrs File /Users/teferi/murano/horizon/openstack_dashboard/api/glance.py, line 129, in image_update return image UnboundLocalError: local variable 'image' referenced before assignment This is because image variable is not handled correctly in image_update function. ** Affects: horizon Importance: Undecided Assignee: Kirill Zaitsev (kzaitsev) Status: New ** Changed in: horizon Assignee: (unassigned) = Kirill Zaitsev (kzaitsev) -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Dashboard (Horizon). https://bugs.launchpad.net/bugs/1464991 Title: Errors are not handled correctly during image updates Status in OpenStack Dashboard (Horizon): New Bug description: To reproduce: Log in to horizon as unprivileged user. Navigate to image editing, try to mark an image as public. Observed result: an error message, stating: Danger: There was an error submitting the form. Please try again. Logs indicate, that an UnboundLocalError occurrs File /Users/teferi/murano/horizon/openstack_dashboard/api/glance.py, line 129, in image_update return image UnboundLocalError: local variable 'image' referenced before assignment This is because image variable is not handled correctly in image_update function. To manage notifications about this bug go to: https://bugs.launchpad.net/horizon/+bug/1464991/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp
[Yahoo-eng-team] [Bug 1464979] [NEW] VMware: _get_power_state does not set correct power state
Public bug reported: In the event that an instance is deleted during the driver get_info method then the instance may not be correctly set. This is due to the fact that the VMware driver does not raise the correct exception. ** Affects: nova Importance: Undecided Assignee: Gary Kotton (garyk) Status: In Progress -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Compute (nova). https://bugs.launchpad.net/bugs/1464979 Title: VMware: _get_power_state does not set correct power state Status in OpenStack Compute (Nova): In Progress Bug description: In the event that an instance is deleted during the driver get_info method then the instance may not be correctly set. This is due to the fact that the VMware driver does not raise the correct exception. To manage notifications about this bug go to: https://bugs.launchpad.net/nova/+bug/1464979/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp
[Yahoo-eng-team] [Bug 1465016] [NEW] nova uses suds, which is to be removed from Debian/Ubuntu
Public bug reported: Suds is a library which isn't maintained upstream. Please switch to something else. As you may have seen, someone filed a bug against the nova package in Debian because of this: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=788081 As mentioned on the bug report: Please consider to migrate your package to use a maintained soap library (like pysimplesoap, at the time of writing in NEW). ** Affects: nova Importance: Undecided Status: New -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Compute (nova). https://bugs.launchpad.net/bugs/1465016 Title: nova uses suds, which is to be removed from Debian/Ubuntu Status in OpenStack Compute (Nova): New Bug description: Suds is a library which isn't maintained upstream. Please switch to something else. As you may have seen, someone filed a bug against the nova package in Debian because of this: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=788081 As mentioned on the bug report: Please consider to migrate your package to use a maintained soap library (like pysimplesoap, at the time of writing in NEW). To manage notifications about this bug go to: https://bugs.launchpad.net/nova/+bug/1465016/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp
[Yahoo-eng-team] [Bug 1465016] Re: nova uses suds, which is to be removed from Debian/Ubuntu
suds is no longer listed in the requirements for nova. ** Changed in: nova Status: New = Invalid ** Also affects: nova/kilo Importance: Undecided Status: New -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Compute (nova). https://bugs.launchpad.net/bugs/1465016 Title: nova uses suds, which is to be removed from Debian/Ubuntu Status in OpenStack Compute (Nova): Invalid Status in OpenStack Compute (nova) kilo series: New Bug description: Suds is a library which isn't maintained upstream. Please switch to something else. As you may have seen, someone filed a bug against the nova package in Debian because of this: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=788081 As mentioned on the bug report: Please consider to migrate your package to use a maintained soap library (like pysimplesoap, at the time of writing in NEW). To manage notifications about this bug go to: https://bugs.launchpad.net/nova/+bug/1465016/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp
[Yahoo-eng-team] [Bug 1442174] Re: can not print request_id in some logs when booting an instance
Already fixed in: https://review.openstack.org/#/c/171299/ ** Changed in: nova Status: Confirmed = Fix Released -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Compute (nova). https://bugs.launchpad.net/bugs/1442174 Title: can not print request_id in some logs when booting an instance Status in OpenStack Compute (Nova): Fix Released Bug description: nova keeps the RequestConext in threading.local, so it can print the request_id in the logs. But when booting an instance, it spawns a new greenthread to build the instance. The RequestContext is not kept in the threading.local of the new greenthread, so we can not print the request_id in the logs. To manage notifications about this bug go to: https://bugs.launchpad.net/nova/+bug/1442174/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp
[Yahoo-eng-team] [Bug 1413142] Re: bad configuration for libguestfs
** Also affects: nova Importance: Undecided Status: New -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Compute (nova). https://bugs.launchpad.net/bugs/1413142 Title: bad configuration for libguestfs Status in devstack - openstack dev environments: New Status in OpenStack Compute (Nova): New Bug description: An error is reported by guestfs when exercising but hidden by an except reported in a log level DEBUG: http://git.openstack.org/cgit/openstack/nova/tree/nova/virt/disk/api.py#n214 In Nova a clean is in progress on this part of code; We normally would like to break the process if something goes wrong at this step. However the CI failed since the except has been removed: https://review.openstack.org/#/c/119104/18/nova/virt/disk/api.py,cm 2015-01-15 15:19:35.840 28636 ERROR nova.compute.manager [-] [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] Instance failed to spawn 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] Traceback (most recent call last): 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/compute/manager.py, line 2290, in _build_resources 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] yield resources 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/compute/manager.py, line 2160, in _build_and_run_instance 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] flavor=flavor) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/libvirt/driver.py, line 2391, in spawn 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] admin_pass=admin_password) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/libvirt/driver.py, line 2790, in _create_image 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] project_id=instance['project_id']) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/libvirt/imagebackend.py, line 201, in cache 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] *args, **kwargs) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/libvirt/imagebackend.py, line 478, in create_image 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] copy_qcow2_image(base, self.path, size) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /usr/local/lib/python2.7/dist-packages/oslo_concurrency/lockutils.py, line 431, in inner 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] return f(*args, **kwargs) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/libvirt/imagebackend.py, line 444, in copy_qcow2_image 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] disk.extend(target, size, use_cow=True) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/disk/api.py, line 167, in extend 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] if not is_image_extendable(image, use_cow): 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/disk/api.py, line 217, in is_image_extendable 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] fs = vfs.VFS.instance_for_image(image, 'qcow2', None) 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File /opt/stack/new/nova/nova/virt/disk/vfs/api.py, line 57, in instance_for_image 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] vfs.inspect_capabilities() 2015-01-15 15:19:35.840 28636 TRACE nova.compute.manager [instance: 162caeb6-5a8e-413f-8df2-300cf4e66202] File
[Yahoo-eng-team] [Bug 1414530] Re: cwd might be set incorrectly when exceptions are thrown
Fixed in: https://review.openstack.org/#/c/155847/ ** Changed in: oslo.concurrency Status: In Progress = Fix Released -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Compute (nova). https://bugs.launchpad.net/bugs/1414530 Title: cwd might be set incorrectly when exceptions are thrown Status in OpenStack Compute (Nova): Fix Released Status in Oslo Concurrency Library: Fix Released Bug description: CWD might be set incorrectly when exceptions are thrown The call to utils.execute ends up in /opt/stack/nova/nova/utils.py which ultimately calls processutils.execute() in the oslo_concurrency module. If there's an error when executing the command which calls an bash script then an exception ProcessExecutionError will be raised at #1. This means that the code at #2 will never be reached resulting in the Exception being propagated up to the call-stack but now one is still stuck with the wrong working directory which can lead to problems. One should catch the Exception and make sure that in all cases the working directory is reset to the original one. /opt/stack/nova/nova/crypto.py def ensure_ca_filesystem(): Ensure the CA filesystem exists. ca_dir = ca_folder() if not os.path.exists(ca_path()): genrootca_sh_path = os.path.abspath( os.path.join(os.path.dirname(__file__), 'CA', 'genrootca.sh')) start = os.getcwd() fileutils.ensure_tree(ca_dir) os.chdir(ca_dir) utils.execute(sh, genrootca_sh_path) --- #1 os.chdir(start)--- #2 One can see in https://github.com/openstack/oslo.concurrency/blob/master/oslo_concurrency/processutils.py that this Exception can indeed be thrown. Analogously there's a similar issue also in the aforementioned file in _ensure_project_folder. def _ensure_project_folder(project_id): if not os.path.exists(ca_path(project_id)): geninter_sh_path = os.path.abspath( os.path.join(os.path.dirname(__file__), 'CA', 'geninter.sh')) start = os.getcwd() os.chdir(ca_folder()) utils.execute('sh', geninter_sh_path, project_id, _project_cert_subject(project_id)) os.chdir(start) I'm not sure whether this has a potential security vulnerability impact or not. The potential risk is definitely there but it remains to be seen whether an attacker can actually reliably trigger this and then possibly gain something else by having a different working directory. That's why I didn't tag it as a security bug. To manage notifications about this bug go to: https://bugs.launchpad.net/nova/+bug/1414530/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp