OpenStack:由于多个以 "default" 命名的安全组,添加安全规则失败

OpenStack: add security rules failed due to multiple security groups named with "default"

安装devstack后,我按照doc设置安全规则:

$ openstack security group rule create --proto icmp --dst-port 0 default
More than one security_group exists with the name 'default'.

它声称我有多个 security_group 以 default 命名,但我检查 nova secgroup-list:

$ nova secgroup-list
WARNING: Command secgroup-list is deprecated and will be removed after Nova 15.0.0 is released. Use python-neutronclient or python-openstackclient instead.
+--------------------------------------+---------+------------------------+
| Id                                   | Name    | Description            |
+--------------------------------------+---------+------------------------+
| e5466481-f656-46fa-ac72-56f7ab118c70 | default | Default security group |
+--------------------------------------+---------+------------------------+

因此,只有一个安全组以 default 命名...

有人可以给我一些建议吗?

是的,当您有多个租户时,每个租户都有一个 "default" 组,这是一个常见问题。我之前应用的解决方案是在"default"组时使用组ID而不是组名。