ceph - sort osds by utilisation

Posted on Thu 20 September 2018 in Ceph • Tagged with ceph, crush, linux, notepad, code • 1 min read

Version 1: keep it simple

$ ceph osd df  | awk '{ print "osd."$1, "size: "$5, "usage: " $8 }' | sort -nk5

OSDs can be listed twice - depends on the crushmap.

Version 2: json + python

$ ceph osd df tree -f json | python sort_hdd_osds.py
osd.28  utilization: 15.278888
osd.15  utilization: 19.700484 …

Continue reading

ceph - wrong osd id with lvm+filestore

Posted on Wed 04 July 2018 in Ceph • Tagged with bluestore, ceph, ceph-ansible, LVM, linux, notepad, howto • 2 min read

Not sure why...but i've found a strange ceph-volume behavior with lvm and filestore.

ceph-volume lvm list shows the wrong osd id while the affected osd is online with a another id.

$ mount | grep ceph-2
/dev/mapper/vg00-datalv1 on /var/lib/ceph/osd/ceph-2 type xfs (rw,relatime,seclabel,attr2 …

Continue reading

selinux - change default type

Posted on Thu 12 April 2018 in Linux • Tagged with selinux, linux • 1 min read

$ matchpathcon /tftpboot
/tftpboot       system_u:object_r:tftpdir_t:s0
$ semanage fcontext -a -t tftpdir_rw_t "/srv/tftp(/.*)?"
$ restorecon -Rv /srv/tftp

ceph-ansible: minimal containerized deployment (docker)

Posted on Wed 28 February 2018 in Ceph • Tagged with ansible, ceph, Linux, Openstack • 1 min read

tested with v3.0.26

group_vars/all.yml

monitor_interface: eth1
radosgw_interface: eth1
public_network: 10.20.30.0/24
cluster_network: 192.168.121.0/24
ceph_conf_overrides:
    osd:
        osd scrub during recovery: false
ceph_docker_image: "ceph/daemon"
ceph_docker_image_tag: latest
ceph_docker_registry: 10.20.30.1:5000
containerized_deployment: true

group_vars/osds.yml

crush_location: true
osd_crush_location …

Continue reading

SUSE Cloud – missing cinder key on computes - part2

Posted on Thu 07 December 2017 in openstack • Tagged with ceph, Openstack, suse cloud, SUSE Linux Enterprise Server, cinder, notepad, linux • 1 min read

I've found the root cause for the missing cinder key on the computes.

chef-client output - without any files:

[2017-11-30T09:37:33+01:00] INFO: Processing package[ceph-common] action install (nova::ceph line 50)
[2017-11-30T09:37:33+01:00] INFO: Ceph configuration file is …

Continue reading

ovirt/rhev/rhv - stucked/locked task

Posted on Wed 06 December 2017 in ovirt • Tagged with ovirt, RHEV, notepad, linux • 1 min read

Query locked elements:

PGPASSWORD=password /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -d engine -u engine -t [all|disk|vm|template] -q

Remove lock:

PGPASSWORD=password /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -d engine -u engine -t [all|disk|vm|template] -r

SUSE Cloud - missing cinder key on computes

Posted on Fri 17 November 2017 in openstack • Tagged with ceph, Openstack, suse cloud, SUSE Linux Enterprise Server, cinder, notepad, linux • 1 min read

2017-11-01 14:30:53.970 27835 ERROR nova.virt.libvirt.driver [instance: c5618826-98cb-4fd6-9d6f-b8899bd320b7] libvirtError: Secret not found: no secret with matching uuid '5b7c1b36-
9093-4a13-b14d-da8b8cbdd8a6'
2017-11-01 14:30:53.970 27835 ERROR nova.virt.libvirt.driver [instance: c5618826 …

Continue reading

SUSE Openstack Cloud - debugging sleshammer

Posted on Fri 10 November 2017 in openstack • Tagged with Openstack, suse cloud, SUSE Linux Enterprise Server, cinder, notepad, linux • 1 min read

Slug: suse-openstack-cloud-debugging-sleshammer Status: published

To get a login shell during the discovery and [before]{.underline} the nfs is mounted:

Add the DISCOVERY_ROOT_PASSWORD parameter

root@admin:~ # crowbarctl proposal edit provisioner default
{
  "id": "provisioner-default",
  "description": "Created on Thu, 09 Nov 2017 15:43:20 +0100",
  "attributes": {
    "provisioner": {
[...]
      "discovery": {
        "append": "DISCOVERY_ROOT_PASSWORD=replace-with-your-password"
      }
[...]
    }
}
root …

Continue reading

chrony - adjust time manually

Posted on Fri 22 September 2017 in Linux • Tagged with chrony, Linux, Notepad, Work • 1 min read

$ chronyc -m "password $( awk '{ print $2 }' /etc/chrony/chrony.keys  )" makestep

openstack kolla - docker dependency tree

Posted on Thu 29 June 2017 in openstack • Tagged with openstack, kolla, linux, notepad • 1 min read

kolla dependency tree created via 

# kolla-build --save-dependency /tmp/kolla-dependency -p fullbuild