Merge "Enable metadata cleaning by default"
This commit is contained in:
commit
be7f82e6c6
@ -153,6 +153,7 @@ def cmd_install(args):
|
|||||||
use_public_urls=args.enable_keystone,
|
use_public_urls=args.enable_keystone,
|
||||||
noauth_mode=not args.enable_keystone,
|
noauth_mode=not args.enable_keystone,
|
||||||
enabled_hardware_types=args.hardware_types,
|
enabled_hardware_types=args.hardware_types,
|
||||||
|
cleaning_disk_erase=args.cleaning_disk_erase,
|
||||||
testing=args.testenv,
|
testing=args.testenv,
|
||||||
use_cirros=args.testenv,
|
use_cirros=args.testenv,
|
||||||
use_tinyipa=args.testenv,
|
use_tinyipa=args.testenv,
|
||||||
@ -212,6 +213,10 @@ def parse_args():
|
|||||||
default='ipmi,redfish,manual-management',
|
default='ipmi,redfish,manual-management',
|
||||||
help='a comma separated list of enabled bare metal '
|
help='a comma separated list of enabled bare metal '
|
||||||
'hardware types')
|
'hardware types')
|
||||||
|
install.add_argument('--cleaning-disk-erase',
|
||||||
|
action='store_true', default=False,
|
||||||
|
help='enable full disk cleaning between '
|
||||||
|
'deployments (can take a lot of time)')
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
if getattr(args, 'func', None) is None:
|
if getattr(args, 'func', None) is None:
|
||||||
|
@ -25,10 +25,6 @@ Command::
|
|||||||
|
|
||||||
Note:
|
Note:
|
||||||
|
|
||||||
- Cleaning mode is explicitly disabled in the ``test-bifrost.yaml``
|
|
||||||
playbook due to the fact that is an IO-intensive operation that can
|
|
||||||
take a great deal of time.
|
|
||||||
|
|
||||||
- In order to cap requirements for installation, an ``upper_constraints_file``
|
- In order to cap requirements for installation, an ``upper_constraints_file``
|
||||||
setting is defined. This is consuming the ``UPPER_CONSTRAINTS_FILE`` env
|
setting is defined. This is consuming the ``UPPER_CONSTRAINTS_FILE`` env
|
||||||
var by default, to properly integrate with CI systems, and will default
|
var by default, to properly integrate with CI systems, and will default
|
||||||
|
@ -384,14 +384,16 @@ to prompt for the sudo password::
|
|||||||
|
|
||||||
ansible-playbook -K -vvvv -i inventory/target install.yaml
|
ansible-playbook -K -vvvv -i inventory/target install.yaml
|
||||||
|
|
||||||
With regard to testing, ironic's node cleaning capability is disabled by
|
With regard to testing, ironic's node cleaning capability is enabled by
|
||||||
default as it can be an unexpected surprise for a new user that their test
|
default, but only metadata cleaning is turned on, as it can be an unexpected
|
||||||
node is unusable for however long it takes for the disks to be wiped.
|
surprise for a new user that their test node is unusable for however long it
|
||||||
|
takes for the disks to be wiped.
|
||||||
|
|
||||||
If you wish to enable cleaning, you can achieve this by passing the option
|
If you wish to enable full cleaning, you can achieve this by passing the option
|
||||||
``-e cleaning=true`` to the command line or executing the command below::
|
``-e cleaning_disk_erase=true`` to the command line or executing the command
|
||||||
|
below::
|
||||||
|
|
||||||
ansible-playbook -K -vvvv -i inventory/target install.yaml -e cleaning=true
|
ansible-playbook -K -vvvv -i inventory/target install.yaml -e cleaning_disk_erase=true
|
||||||
|
|
||||||
After you have performed an installation, you can edit
|
After you have performed an installation, you can edit
|
||||||
``/etc/ironic/ironic.conf`` to enable or disable cleaning as desired.
|
``/etc/ironic/ironic.conf`` to enable or disable cleaning as desired.
|
||||||
|
@ -30,10 +30,11 @@ removes the previous contents of a node once it has been moved from an
|
|||||||
active to available state, such as setting the provision state to deleted.
|
active to available state, such as setting the provision state to deleted.
|
||||||
Bifrost disables this by default in order to allow initial users to not be
|
Bifrost disables this by default in order to allow initial users to not be
|
||||||
impacted by node cleaning operations upfront when they are testing and
|
impacted by node cleaning operations upfront when they are testing and
|
||||||
evaluating bifrost. In the event of a production deployment, cleaning
|
evaluating bifrost. Only metadata cleaning is enabled by default, but any
|
||||||
should be enabled.
|
production environment should have full cleaning enabled.
|
||||||
|
|
||||||
cleaning: false
|
cleaning: true
|
||||||
|
cleaning_disk_erase: false
|
||||||
|
|
||||||
The ironic python client and openstacksdk libraries can be installed directly
|
The ironic python client and openstacksdk libraries can be installed directly
|
||||||
from Git. The default is to utilize pip to install the current versions in pypi,
|
from Git. The default is to utilize pip to install the current versions in pypi,
|
||||||
@ -319,7 +320,6 @@ Example Playbook
|
|||||||
gather_facts: yes
|
gather_facts: yes
|
||||||
roles:
|
roles:
|
||||||
- role: bifrost-ironic-install
|
- role: bifrost-ironic-install
|
||||||
cleaning: false
|
|
||||||
testing: true
|
testing: true
|
||||||
network_interface: "virbr0"
|
network_interface: "virbr0"
|
||||||
|
|
||||||
|
@ -1,7 +1,9 @@
|
|||||||
---
|
---
|
||||||
# Cleaning turns on ironic conductor clean_nodes flag
|
# Cleaning turns on ironic conductor clean_nodes flag
|
||||||
# which causes the nodes to be wiped after deletion.
|
# which causes the nodes to be wiped after deletion.
|
||||||
cleaning: false
|
cleaning: true
|
||||||
|
# Wipe all data from the disks rather than only the metadata.
|
||||||
|
cleaning_disk_erase: false
|
||||||
|
|
||||||
# Enable fast_track mode for ironic which allows skipping a power
|
# Enable fast_track mode for ironic which allows skipping a power
|
||||||
# cycle
|
# cycle
|
||||||
|
@ -65,9 +65,15 @@ http_url = http://{{ internal_ip }}:{{ file_url_port }}/
|
|||||||
http_root = {{ http_boot_folder }}
|
http_root = {{ http_boot_folder }}
|
||||||
default_boot_option = local
|
default_boot_option = local
|
||||||
fast_track = {{ fast_track }}
|
fast_track = {{ fast_track }}
|
||||||
|
{% if cleaning_disk_erase | bool %}
|
||||||
|
erase_devices_priority = 10
|
||||||
|
erase_devices_metadata_priority = 0
|
||||||
|
{% else %}
|
||||||
|
erase_devices_priority = 0
|
||||||
|
erase_devices_metadata_priority = 10
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
[conductor]
|
[conductor]
|
||||||
clean_nodes = {{ cleaning | lower }}
|
|
||||||
automated_clean = {{ cleaning | lower }}
|
automated_clean = {{ cleaning | lower }}
|
||||||
deploy_kernel = {{ ipa_kernel_url }}
|
deploy_kernel = {{ ipa_kernel_url }}
|
||||||
deploy_ramdisk = {{ ipa_ramdisk_url }}
|
deploy_ramdisk = {{ ipa_ramdisk_url }}
|
||||||
|
@ -100,7 +100,6 @@ Example Playbook
|
|||||||
- role: bifrost-prep-for-install
|
- role: bifrost-prep-for-install
|
||||||
when: not (skip_install | default(false) | bool)
|
when: not (skip_install | default(false) | bool)
|
||||||
- role: bifrost-ironic-install
|
- role: bifrost-ironic-install
|
||||||
cleaning: false
|
|
||||||
testing: true
|
testing: true
|
||||||
|
|
||||||
License
|
License
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
---
|
---
|
||||||
ironic_url: "http://localhost:6385/"
|
ironic_url: "http://localhost:6385/"
|
||||||
noauth_mode: true
|
noauth_mode: true
|
||||||
|
wait_for_node_undeploy: false
|
||||||
|
@ -43,3 +43,4 @@
|
|||||||
name: "{{ name | default() }}"
|
name: "{{ name | default() }}"
|
||||||
state: absent
|
state: absent
|
||||||
instance_info: "{}"
|
instance_info: "{}"
|
||||||
|
wait: "{{ wait_for_node_undeploy }}"
|
||||||
|
@ -47,7 +47,6 @@
|
|||||||
roles:
|
roles:
|
||||||
- role: bifrost-keystone-install
|
- role: bifrost-keystone-install
|
||||||
- role: bifrost-ironic-install
|
- role: bifrost-ironic-install
|
||||||
cleaning: false
|
|
||||||
testing: true
|
testing: true
|
||||||
# NOTE(TheJulia): While the next step creates a ramdisk, some elements
|
# NOTE(TheJulia): While the next step creates a ramdisk, some elements
|
||||||
# do not support ramdisk-image-create as they invoke steps to cleanup
|
# do not support ramdisk-image-create as they invoke steps to cleanup
|
||||||
@ -132,6 +131,7 @@
|
|||||||
gather_facts: no
|
gather_facts: no
|
||||||
roles:
|
roles:
|
||||||
- role: bifrost-unprovision-node-dynamic
|
- role: bifrost-unprovision-node-dynamic
|
||||||
|
wait_for_node_undeploy: true
|
||||||
- role: ironic-delete-dynamic
|
- role: ironic-delete-dynamic
|
||||||
|
|
||||||
# The following tasks are intended to test DHCP functionality
|
# The following tasks are intended to test DHCP functionality
|
||||||
|
12
releasenotes/notes/cleaning-9b4241342320f315.yaml
Normal file
12
releasenotes/notes/cleaning-9b4241342320f315.yaml
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
---
|
||||||
|
features:
|
||||||
|
- |
|
||||||
|
Metadata cleaning is now enabled by default, set ``cleaning`` to ``false``
|
||||||
|
to disable completely.
|
||||||
|
- |
|
||||||
|
To enable full disk cleaning, set ``cleaning_disk_erase`` to ``true``.
|
||||||
|
upgrade:
|
||||||
|
- |
|
||||||
|
If you use ``cleaning=true`` to enable full disk cleaning, you need to
|
||||||
|
also set ``cleaning_disk_erase=true`` now. Omitting it will result in
|
||||||
|
only metadata cleaning enabled.
|
Loading…
Reference in New Issue
Block a user