Skip to content

Instantly share code, notes, and snippets.

Avatar
👨‍💻

Antony Messerli antonym

👨‍💻
View GitHub Profile
View gist:42a00bc331e23d402f08ca4610d7e2a4
FROM ubuntu:focal
ENV DEBIAN_FRONTEND=noninteractive
RUN \
apt-get update && \
apt-get install -y \
dosbox \
dosfstools \
git \
View gist:c62bcaae55437934901f6c2d6aa1e175
| raid_interface | idrac-wsman
| target_raid_config | {'logical_disks': [{'controller': 'RAID.Slot.6-1', 'physical_disks': ['Disk.Bay.0:Enclosure.Internal.0-1:RAID.Slot.6-1', 'Disk.Bay.1:Enclosure.Internal.0-1:RAID.Slot.6-1'], 'size_gb': 'MAX', 'raid_level': '1', 'volume_name': 'RAID', 'is_root_volume': True}]}
Clean Steps
[{
"interface": "raid",
"step": "delete_configuration"
},
View gist:984ea40c84fb0f3e3286b7492bf7226d
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage Traceback (most recent call last):
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage File "/openstack/venvs/cinder-19.0.0.0rc2.dev60/lib/python2.7/site-packages/cinder/cmd/manage.py", line 354, in _run_migration
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage found, done = migration_meth(ctxt, count)
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage File "/openstack/venvs/cinder-19.0.0.0rc2.dev60/lib/python2.7/site-packages/cinder/cmd/manage.py", line 128, in shared_targets_online_data_migration
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage non_shared_hosts, total_vols_to_update = _get_non_shared_target_hosts(ctxt)
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage File "/openstack/venvs/cinder-19.0.0.0rc2.dev60/lib/python2.7/site-packages/cinder/cmd/manage.py", line 111, in _get_non_shared_target_hosts
2019-05-29 13:29:28.075 118434 ERROR cinder.cmd.manage capabilities = rpcapi.get_capabilities(ctxt, servic
View gist:9c5c55b3d6ba169e07ae90c9783675d7
rroot@infra1:/etc/systemd/network# systemctl restart nspawn-macvlan
root@infra1:/etc/systemd/network# ls -al
total 20
drwxr-xr-x 2 root root 4096 Jul 11 17:44 .
drwxr-xr-x 7 root root 4096 Jul 11 17:42 ..
-rw-r--r-- 1 root root 81 Jul 11 17:44 0-nspawn_host-mv-nspawn0.netdev
-rw-r--r-- 1 root root 147 Jul 11 17:44 0-nspawn_host-mv-nspawn0.network
-rw-r--r-- 1 root root 99 Jul 11 17:44 99-default.link
root@infra1:/etc/systemd/network# systemctl status nspawn-macvlan
● nspawn-macvlan.service - nspawn host macvlan integrations
View gist:5abc72114d23649d905e6a6c178a7324
7:29:38 echo "#### BEGIN LOG COLLECTION ###"
17:29:38 #### BEGIN LOG COLLECTION ###
17:29:38
17:29:38 collect_logs_cmd="ansible-playbook"
17:29:38 collect_logs_cmd+=" --ssh-common-args='-o StrictHostKeyChecking=no'"
17:29:38 collect_logs_cmd+=" --extra-vars='artifacts_dir=${RE_HOOK_ARTIFACT_DIR}'"
17:29:38 collect_logs_cmd+=" --extra-vars='result_dir=${RE_HOOK_RESULT_DIR}'"
17:29:38
17:29:38 if [[ $RE_JOB_IMAGE =~ .*mnaio.* ]]; then
17:29:38 collect_logs_cmd+=" --extra-vars='target_hosts=pxe_servers'"
View gist:129375dd9705b23aa6cf6abace8f49de
PR_{repo_name}-{series}-{image}-{scenario}-{action}
PM_{repo_name}-{branch}-{image}-{scenario}-{action}
#### rpc-upgrades-newton-aio (series newton_aio)
PR_rpc-upgrades-newton_aio-trusty-swift-liberty
PR_rpc-upgrades-newton_aio-trusty-swift-r12.2.8
PM_rpc-upgrades-master-trusty-swift-liberty
PM_rpc-upgrades-master-trusty-swift-r12.2.8
#### rpc-upgrades-r14.5.0-aio (series r14.5.0_aio)
View gist:7140b6e22b89f424ec91bb404b4ec6ba
root@rpco-liberty:/opt/rpc-leapfrog/openstack-ansible-ops/leap-upgrades/upgrade-utilities# export | grep -i CONT
##### SOURCE DEFAULT VAR ######
root@rpco-liberty:/opt/rpc-leapfrog/openstack-ansible-ops/leap-upgrades/upgrade-utilities# source ../lib/vars.sh
root@rpco-liberty:/opt/rpc-leapfrog/openstack-ansible-ops/leap-upgrades/upgrade-utilities# cat ../lib/vars.sh | grep -i CONTAINERS_TO_DESTROY
export CONTAINERS_TO_DESTROY="${CONTAINERS_TO_DESTROY:-all_containers:!galera_all:!neutron_agent:!ceph_all:!rsyslog_all}"
root@rpco-liberty:/opt/rpc-leapfrog/openstack-ansible-ops/leap-upgrades/upgrade-utilities# export | grep -i CONT
declare -x CONTAINERS_TO_DESTROY="all_containers:!galera_all:!neutron_agent:!ceph_all:!rsyslog_all"
##### Uses multiple single quotes, correct hosts added ####### 'destroy_hosts='${CONTAINERS_TO_DESTROY}''
View gist:a11b007512fbbb883d8d0456763483d0
root@rpco-liberty:~# cp /etc/openstack_deploy/user_variables.yml /etc/openstack_deploy/user_variables.yml.orig
root@rpco-liberty:~# # Remove horizon static files variables from user_variables.yml as this is now
root@rpco-liberty:~# # maintained in group_vars.
root@rpco-liberty:~# if grep '^rackspace_static_files_folder\:' /etc/openstack_deploy/user_variables.yml; then
> sed -i '/^rackspace_static_files_folder:.*/d' /etc/openstack_deploy/user_variables.yml
> fi
rackspace_static_files_folder: /opt/rpc-openstack/rpcd/playbooks/roles/horizon_extensions/files
root@rpco-liberty:~#
root@rpco-liberty:~# # Remove horizon_custom_uploads block from user_variables.yml as this is maintained in
root@rpco-liberty:~# # group_vars
@antonym
antonym / gist:4d0254ea3c68f5d1f78ad458a40fcff3
Created September 26, 2017 13:58
Liberty->Newton Issues
View gist:4d0254ea3c68f5d1f78ad458a40fcff3
Fails on last playbook (os-cinder-install.yml) need a flag?
TASK [Perform online data migrations] ******************************************
fatal: [rpco-liberty_cinder_api_container-e0e91887]: FAILED! => {"failed": true, "msg": "The conditional check 'ansible_local['openstack_ansible']['cinder']['need_online_data_migrations'] | bool' failed. The error was: error while evaluating conditional (ansible_local['op
enstack_ansible']['cinder']['need_online_data_migrations'] | bool): 'dict object' has no attribute 'need_online_data_migrations'\n\nThe error appears to have been in '/opt/leap42/openstack-ansible-14.2.7/playbooks/os-cinder-install.yml': line 215, column 7, but may\nbe el
sewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n tasks:\n - name: Perform online data migrations\n ^ here\n"}
View gist:fa75c91118a98c665c619431f4b48ed6
root@localhost:/tasks# cat /etc/lldpd.conf
unconfigure lldp custom-tlv
root@localhost:/tasks# systemctl restart lldpd
root@localhost:/tasks# lldpctl -f keyvalue
lldp.eno1.via=LLDP
lldp.eno1.rid=4
lldp.eno1.age=0 day, 00:00:08
lldp.eno1.chassis.mac=54:7f:ee:a5:79:6c
lldp.eno1.chassis.name=servers-lab-1.sat6
lldp.eno1.chassis.descr=Cisco Nexus Operating System (NX-OS) Software 6.0(2)U5(1)