diff options
-rw-r--r-- | Changing the volume type of a Cinder volume.md | 24 | ||||
-rw-r--r-- | OTF Code Style.md | 13 | ||||
-rw-r--r-- | OTF Files.md | 17 | ||||
-rw-r--r-- | OTF OpenStack Provider.md | 19 | ||||
-rw-r--r-- | OTF Providers.md | 8 | ||||
-rw-r--r-- | OTF versioning.md | 16 | ||||
-rw-r--r-- | OpenTofu and Terraform.md | 5 | ||||
-rw-r--r-- | Terraform Style Guide.md | 13 | ||||
-rw-r--r-- | Terraform block.md | 7 | ||||
-rw-r--r-- | The volume type of a Cinder volume can be changed.md | 7 | ||||
-rw-r--r-- | daily/01-May-2025.md | 6 | ||||
-rw-r--r-- | daily/06-May-2025.md | 29 |
12 files changed, 157 insertions, 7 deletions
diff --git a/Changing the volume type of a Cinder volume.md b/Changing the volume type of a Cinder volume.md new file mode 100644 index 0000000..6a786d9 --- /dev/null +++ b/Changing the volume type of a Cinder volume.md @@ -0,0 +1,24 @@ +--- +tags: + - openstack + - cinder + - howto +--- +Shelve server, force volume into being available rather than reserved, set new volume type, unshelve server. + +**Retype command** +` as-project c7ae9902423a4fa5b68bc789f861016c os3 volume set --type mcs-vtype-5000 --migration-policy on-demand 2003c43b-ec96-42db-8890-1bacf979389e` + +**Why shelve?** +Because Nova seems to not generate the new QoS properties in the domain when we simply stop/start. + +**Migration** +The retype commands copies the volume to a new one with the correct QoS. + +**Migration fails in Cinder when trying to call Nova (keystone auth error)** +It calls Nova to update attachment but there is no need for this, so to bypass this error I tried deleting the volume attachment outright. After that it went smooth. +That forces us to poke in the database to "undelete" the volume_attachment. + +*The above may be faster* +It is probably faster to skip unnecessary migration and such by just changing the volume type in the database outright and unshelve then, because the only thing that changes are QoS properties in the libvirt domain. +**This is untested**
\ No newline at end of file diff --git a/OTF Code Style.md b/OTF Code Style.md new file mode 100644 index 0000000..d957949 --- /dev/null +++ b/OTF Code Style.md @@ -0,0 +1,13 @@ +--- +tags: + - opentofu +--- +`#` for both single and multiline comments +Resource names: nouns without specifying resource type +snake_case +Define resources in the same order as their dependency ordering +Include type and description for every variable +Describe every output +Avoid overuse of variables and local values +Always include default provider config +use `count` and `for_each` sparingly diff --git a/OTF Files.md b/OTF Files.md new file mode 100644 index 0000000..f48ea0b --- /dev/null +++ b/OTF Files.md @@ -0,0 +1,17 @@ +--- +tags: + - opentofu +--- +`backend.tf` containing backend configuration. +`main.tf` containing all resource and data source blocks. +`outputs.tf` containing all output blocks in alphabetical order +`providers.tf` contains all `provider` configuration +`terraform.tf` [[Terraform block]] +`variables.tf` for variable blocks in alphabetical order +`locals.tf` containing local values +`override.tf` contains overrides. This file and others postfixed with `_override.tf` are loaded with lowest prio. + +When bigger VPC +`network.tf` containing network resources +`storage.tf` containing object storage volumes etc +`compute.tf` containing instances diff --git a/OTF OpenStack Provider.md b/OTF OpenStack Provider.md new file mode 100644 index 0000000..92d6afd --- /dev/null +++ b/OTF OpenStack Provider.md @@ -0,0 +1,19 @@ +--- +tags: + - opentofu +--- +https://search.opentofu.org/provider/terraform-provider-openstack/openstack/latest +--- + +[[OTF Files]] +```providers.tf +provider "openstack" { + user_name = "admin" + tenant_name = "admin" + password = "pwd" + auth_url = "http://myauthurl:5000/v3" + region = "RegionOne" +} +``` +It is also possible to just specify "cloud" referring to a clouds.yml. + diff --git a/OTF Providers.md b/OTF Providers.md new file mode 100644 index 0000000..4572ca9 --- /dev/null +++ b/OTF Providers.md @@ -0,0 +1,8 @@ +--- +tags: + - opentofu + - terraform +--- +The registry is found at https://search.opentofu.org + +[[OTF OpenStack Provider]]
\ No newline at end of file diff --git a/OTF versioning.md b/OTF versioning.md new file mode 100644 index 0000000..6d7efc5 --- /dev/null +++ b/OTF versioning.md @@ -0,0 +1,16 @@ +--- +tags: + - opentofu +--- +Looks like semver. + +`version = ">= 1.2.0, < 2.0.0"` + +Operators: +- `=` (can also be left out) +- `!=` +- `>` +- `>=` +- `<` +- `<=` +- `~>` Allows only the patch version to be increased. diff --git a/OpenTofu and Terraform.md b/OpenTofu and Terraform.md new file mode 100644 index 0000000..12d6eed --- /dev/null +++ b/OpenTofu and Terraform.md @@ -0,0 +1,5 @@ +--- +tags: + - opentofu +--- +OpenTofu is an open source alternative to Terraform, the latter of which has been acquired by IBM and is prone to licence changes.
\ No newline at end of file diff --git a/Terraform Style Guide.md b/Terraform Style Guide.md new file mode 100644 index 0000000..db8480d --- /dev/null +++ b/Terraform Style Guide.md @@ -0,0 +1,13 @@ +--- +tags: + - terraform + - opentofu +--- +Use `terraform-fmt` & `terraform-validate`. +`TFLint` is a linter. + +The formatted, validator and linter seem to work for OpenTofu ([[OpenTofu and Terraform]]) as well. + +[[OTF Code Style]] +[[OTF Files]] + diff --git a/Terraform block.md b/Terraform block.md new file mode 100644 index 0000000..6a84913 --- /dev/null +++ b/Terraform block.md @@ -0,0 +1,7 @@ +--- +tags: + - opentofu +--- +This block is mandatory and it specifies the version of terraform that is required and which providers are required. + +`required_version` has to follow [[OTF versioning]].
\ No newline at end of file diff --git a/The volume type of a Cinder volume can be changed.md b/The volume type of a Cinder volume can be changed.md deleted file mode 100644 index 8ee52ad..0000000 --- a/The volume type of a Cinder volume can be changed.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -tags: - - openstack - - cinder - - howto ---- -Shelve server, set new volume type, unshelve server.
\ No newline at end of file diff --git a/daily/01-May-2025.md b/daily/01-May-2025.md new file mode 100644 index 0000000..bd368d6 --- /dev/null +++ b/daily/01-May-2025.md @@ -0,0 +1,6 @@ +# Manila +Share network +Cinder + +**dhss = driver_handles_share_server** +Means that Manilla creates a share server, requiring a share network and a service image.
\ No newline at end of file diff --git a/daily/06-May-2025.md b/daily/06-May-2025.md new file mode 100644 index 0000000..2568441 --- /dev/null +++ b/daily/06-May-2025.md @@ -0,0 +1,29 @@ +Checklist for maintenance OVN upgrade- [ ] Make +- [x] xping all public router ips +- [x] Open Grafana dashboard for OVN leaders +- [x] Open Grafana dashboard for network metrics +- [x] xping one vm on every compute node +- [x] check ovn cluster status +- [x] make sure ansible inventory covers all compute nodes +- [x] make sure ansible inventory covers all network nodes +- [x] make sure ansible inventory covers all ovn cluster database nodes +- [x] Make sure network nodes are reboot proof +- [x] Check ansible netconf for reboot proofness as well +- [x] Check puppet status on all network nodes + + +Xping: window 3 +Ansible playbook: window 4 +OVN db cluster nodes: window 4 +Neutron server tail: window 5 + + +Note +- Moet ff iets slimmers om te xpingen. Freenet veelste veel pub router ips; liefst gwn 1 of ip per netwerk en compute node. + - Query OVN? +- Ff proberen vast te leggen hoe we OVN databases automatisch kunnen checken op compleet up zijn, ipv arbitrair wachten en zelf kijken. +- OVN upgrade 1: ongeveer om 2 uur begonnen, dingen recoveren volledig vanaf mijn POV: 2:09 + - OVN db upgrade stap wacht: check -> lijkt allemaal goed, cluster status OK + - eerste ovn-controller upgrade (n01) -> shit blijft down hoe lang ik ook lijk te wachten: br-int connection timeout + - Besloten om toch gewoon proberen door te duwen + - Zodra ik continue met de volgende lijkt eigenlijk meteen br-int te connecten (toeval?) en gaan dingen recoveren
\ No newline at end of file |