summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2023-02-23 04:40:38 +0000
committerGerrit Code Review <review@openstack.org>2023-02-23 04:40:38 +0000
commit222a62e76c62dd39b40a4cc65b2268e11df31dc7 (patch)
tree8e5d97da952897b03c9f17d7093a89007aa1bd47
parent3231983b8d4a03f94f7452fd9f8072eb25528bab (diff)
parent88c4271a7030fca0333fcea84cf8702990b263ca (diff)
downloadironic-222a62e76c62dd39b40a4cc65b2268e11df31dc7.tar.gz
Merge "Relaxing console pid looking"
-rw-r--r--ironic/drivers/modules/console_utils.py2
-rw-r--r--releasenotes/notes/console-pid-file-6108d2775ef947fe.yaml6
2 files changed, 7 insertions, 1 deletions
diff --git a/ironic/drivers/modules/console_utils.py b/ironic/drivers/modules/console_utils.py
index 6e08b6712..c5e9e857a 100644
--- a/ironic/drivers/modules/console_utils.py
+++ b/ironic/drivers/modules/console_utils.py
@@ -90,7 +90,7 @@ def _get_console_pid(node_uuid):
with open(pid_path, 'r') as f:
pid_str = f.readline()
return int(pid_str)
- except (IOError, ValueError):
+ except (IOError, ValueError, FileNotFoundError):
raise exception.NoConsolePid(pid_path=pid_path)
diff --git a/releasenotes/notes/console-pid-file-6108d2775ef947fe.yaml b/releasenotes/notes/console-pid-file-6108d2775ef947fe.yaml
new file mode 100644
index 000000000..427d04da8
--- /dev/null
+++ b/releasenotes/notes/console-pid-file-6108d2775ef947fe.yaml
@@ -0,0 +1,6 @@
+---
+fixes:
+ - |
+ Fixes an issue that when a node has console enabled but pid
+ file missing, the console could not be disabled as well as be
+ restarted, which makes the console feature unusable.