)]}'
{"nova/virt/libvirt/driver.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b2fe73d75f3e55cb54b6ce695a7289e8019810f8","unresolved":false,"context_lines":[{"line_number":7098,"context_line":"        self.firewall_driver.setup_basic_filtering(instance, nw_info)"},{"line_number":7099,"context_line":""},{"line_number":7100,"context_line":"    def _debug_lsof_output(self, path):"},{"line_number":7101,"context_line":"        out, err \u003d utils.execute(\u0027lsof\u0027, \u0027+D\u0027, path)"},{"line_number":7102,"context_line":"        return out"},{"line_number":7103,"context_line":""},{"line_number":7104,"context_line":"    def delete_instance_files(self, instance):"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_a073ccb0","line":7101,"updated":"2015-09-14 21:16:50.000000000","message":"This pretty much always fails:\n\nhttp://logs.openstack.org/25/223125/1/check/gate-tempest-dsvm-full/ad560d2/logs/screen-n-cpu.txt.gz?level\u003dTRACE\n\nI\u0027m wondering if you need to run it as root in case there permission denied errors happening traversing the entire tree?  You can do that by passing run_as_root\u003dTrue to execute.\n\nIf you run it as root, note you\u0027ll need to update the compute.filters rootwrap file:\n\nhttps://github.com/openstack/nova/blob/master/etc/nova/rootwrap.d/compute.filters","commit_id":"67d88190efcd0db869e24d7d50bdd37cd91f1108"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b2fe73d75f3e55cb54b6ce695a7289e8019810f8","unresolved":false,"context_lines":[{"line_number":7149,"context_line":"                        out, instance\u003dinstance)"},{"line_number":7150,"context_line":"                shutil.rmtree(target_del)"},{"line_number":7151,"context_line":"            except OSError as e:"},{"line_number":7152,"context_line":"                LOG.error(_LE(\u0027Failed to cleanup directory %(target)s: \u0027"},{"line_number":7153,"context_line":"                              \u0027%(e)s\u0027), {\u0027target\u0027: target_del, \u0027e\u0027: e},"},{"line_number":7154,"context_line":"                            instance\u003dinstance)"},{"line_number":7155,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_20601cce","line":7152,"updated":"2015-09-14 21:16:50.000000000","message":"I\u0027d probably only run lsof if we hit an EBUSY error.","commit_id":"67d88190efcd0db869e24d7d50bdd37cd91f1108"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6ec6c5282e6617ffdaa9a40dfe73b562e9a955a4","unresolved":false,"context_lines":[{"line_number":7098,"context_line":"        self.firewall_driver.setup_basic_filtering(instance, nw_info)"},{"line_number":7099,"context_line":""},{"line_number":7100,"context_line":"    def _debug_lsof_output(self, path):"},{"line_number":7101,"context_line":"        out, err \u003d utils.execute(\u0027lsof\u0027, \u0027+D\u0027, path, run_as_root\u003dTrue)"},{"line_number":7102,"context_line":"        return out"},{"line_number":7103,"context_line":""},{"line_number":7104,"context_line":"    def delete_instance_files(self, instance):"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba15a1d1_639d6209","line":7101,"updated":"2015-09-16 16:46:32.000000000","message":"This is still exiting with 1:\n\nhttp://logs.openstack.org/48/219448/4/check/gate-tempest-dsvm-full/87919e2/logs/screen-n-cpu.txt.gz#_2015-09-15_20_02_14_829\n\nCan we use something other than the +D?  Maybe we should just iterate the files in the directory and run lsof on those?","commit_id":"9373e7cdeba608798e4e0868e141dfb19817eb8f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fd3ade61589d5a11aa09dc55ebc0a2e67ebd6f2b","unresolved":false,"context_lines":[{"line_number":7098,"context_line":"        self.firewall_driver.setup_basic_filtering(instance, nw_info)"},{"line_number":7099,"context_line":""},{"line_number":7100,"context_line":"    def _debug_lsof_output(self, path):"},{"line_number":7101,"context_line":"        out, err \u003d utils.execute(\u0027lsof\u0027, \u0027+D\u0027, path, run_as_root\u003dTrue)"},{"line_number":7102,"context_line":"        return out"},{"line_number":7103,"context_line":""},{"line_number":7104,"context_line":"    def delete_instance_files(self, instance):"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba15a1d1_dca732bb","line":7101,"in_reply_to":"ba15a1d1_2f68abb8","updated":"2015-09-17 17:20:21.000000000","message":"Cool, let\u0027s try that then.","commit_id":"9373e7cdeba608798e4e0868e141dfb19817eb8f"},{"author":{"_account_id":18247,"name":"Mark Doffman","email":"mdoffman@linux.vnet.ibm.com","username":"doffm"},"change_message_id":"7d43844046f8871f80486a75f72ead9bb53e4f1c","unresolved":false,"context_lines":[{"line_number":7098,"context_line":"        self.firewall_driver.setup_basic_filtering(instance, nw_info)"},{"line_number":7099,"context_line":""},{"line_number":7100,"context_line":"    def _debug_lsof_output(self, path):"},{"line_number":7101,"context_line":"        out, err \u003d utils.execute(\u0027lsof\u0027, \u0027+D\u0027, path, run_as_root\u003dTrue)"},{"line_number":7102,"context_line":"        return out"},{"line_number":7103,"context_line":""},{"line_number":7104,"context_line":"    def delete_instance_files(self, instance):"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba15a1d1_2f68abb8","line":7101,"in_reply_to":"ba15a1d1_639d6209","updated":"2015-09-16 18:10:30.000000000","message":"We can use +d directory instead of +D which does exactly this, just looks at the files in the top level of the directory.","commit_id":"9373e7cdeba608798e4e0868e141dfb19817eb8f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6ec6c5282e6617ffdaa9a40dfe73b562e9a955a4","unresolved":false,"context_lines":[{"line_number":7149,"context_line":"                LOG.error(_LE(\u0027Failed to cleanup directory %(target)s: \u0027"},{"line_number":7150,"context_line":"                              \u0027%(e)s\u0027), {\u0027target\u0027: target_del, \u0027e\u0027: e},"},{"line_number":7151,"context_line":"                            instance\u003dinstance)"},{"line_number":7152,"context_line":"                out \u003d self._debug_lsof_output(target_del)"},{"line_number":7153,"context_line":"                LOG.debug(\u0027Is anything using the target directory?\\n %s\u0027,"},{"line_number":7154,"context_line":"                        out, instance\u003dinstance)"},{"line_number":7155,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba15a1d1_63b48281","line":7152,"updated":"2015-09-16 16:46:32.000000000","message":"This should probably be wrapped in a try/except where we ignore any ProcessExecutionError.","commit_id":"9373e7cdeba608798e4e0868e141dfb19817eb8f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"326eef6e821e1bd5f82ca51d931d764a1c3eec1f","unresolved":false,"context_lines":[{"line_number":7100,"context_line":"    def _debug_lsof_output(self, path):"},{"line_number":7101,"context_line":"        out, err \u003d utils.execute(\u0027lsof\u0027, \u0027+d\u0027, path, run_as_root\u003dTrue)"},{"line_number":7102,"context_line":"        if err:"},{"line_number":7103,"context_line":"            LOG.error(\u0027LSOF failure on target directory.\\n %s\u0027, err)"},{"line_number":7104,"context_line":"        return out"},{"line_number":7105,"context_line":""},{"line_number":7106,"context_line":"    def delete_instance_files(self, instance):"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba15a1d1_ba2a1be6","line":7103,"updated":"2015-09-21 16:25:56.000000000","message":"You won\u0027t actually get here if lsof ends with a non-zero return code, that will trigger a ProcessExecutionError:\n\nhttp://logs.openstack.org/48/219448/4/check/gate-tempest-dsvm-full/a4724c8/logs/screen-n-cpu.txt.gz#_2015-09-18_18_27_39_229\n\nSo you could handle that and log the error, but it doesn\u0027t help with the debug really.  Plus the stderr in ^ doesn\u0027t show anything, just that lsof +d failed with rc 1.\n\nFrom the man page:\n\n\"Lsof returns a one (1) if any error was detected, including the failure to locate command names, file names, Internet addresses or files, login names, NFS files, PIDs, PGIDs, or UIDs it was asked to list. If the -V option is specified, lsof will indicate the search items it failed to list.\"\n\nSo add the -V option so we get some more information.","commit_id":"803de3895cfd06b52e2d9936116fe6bf24f5a0f9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9d6ddf2e988674b6cfa4c898e478120f710fe16f","unresolved":false,"context_lines":[{"line_number":7103,"context_line":"        if err:"},{"line_number":7104,"context_line":"            LOG.error(\u0027LSOF failure on target directory.\\n %s\u0027, err)"},{"line_number":7105,"context_line":""},{"line_number":7106,"context_line":"        out, err \u003d utils.execute(\u0027mountpoint\u0027, path, run_as_root\u003dTrue)"},{"line_number":7107,"context_line":"        LOG.debug(\u0027mountpoint on target directory?\\n %s\u0027, out, instance\u003dinstance)"},{"line_number":7108,"context_line":"        if err:"},{"line_number":7109,"context_line":"            LOG.error(\u0027mountpoint failure on target directory.\\n %s\u0027, err)"}],"source_content_type":"text/x-python","patch_set":5,"id":"ba15a1d1_be405d60","line":7106,"updated":"2015-09-23 18:16:03.000000000","message":"You won\u0027t get here if lsof exits with non-zero since utils.execute will raise a ProcessExecutionError.","commit_id":"07695f4f84704d46b34e1fc91faf8975f990f5ec"}]}
