meh

Power-consumption of mostly Juniper EX switches

2019/09/19 hardware, meh, network

Measured using Voltcraft Energy-Logger 4000; when JunOS is fully booted. No cables, no SFPs, no POE consumption.

  • Juniper EX3400-24T 30 watt
  • Juniper EX3300-24T 30 watt
  • Juniper EX3400-48T 40 watt
  • Juniper EX4200-24T 90 watt
  • Juniper EX4200-24F 85 watt
  • Juniper EX4200-48T 120 watt
  • Juniper QFX5100-48T-6Q 175 watt
  • Dell Force10 S4810 110 watt
  • Dell R430 (dual 2650v4, 256GB) 70 watt
  • Dell R430 (dual 2650v3, 96GB) 130 watt
  • Dell R630 (dual 2697A, 512GB) 220 watt

Openstack retardedness

2019/07/30 meh

ID vs id

So, when you list shit, the column is ID with capitals. When you show an object, it’s in lower-case. Totally logic…

[root@controller01 ~]# openstack server list -f value -c id
No recognized column names in [u'id']. Recognized columns are ('ID', 'Name', 'Status', 'Networks', 'Image', 'Flavor').
[root@controller01 ~]# openstack server list -f value -c ID
4df5dc54-40a5-440d-8ee1-3217b562d079
[root@controller01 ~]# openstack server show test-lb -f value -c id
4df5dc54-40a5-440d-8ee1-3217b562d079
[root@controller01 ~]# openstack server show test-lb -f value -c ID
No recognized column names in [u'ID']. Recognized columns are (u'OS-DCF:diskConfig', u'OS-EXT-AZ:availability_zone', u'OS-EXT-SRV-ATTR:host', u'OS-EXT-SRV-ATTR:hypervisor_hostname', u'OS-EXT-SRV-ATTR:instance_name', u'OS-EXT-STS:power_state', u'OS-EXT-STS:task_state', u'OS-EXT-STS:vm_state', u'OS-SRV-USG:launched_at', u'OS-SRV-USG:terminated_at', u'accessIPv4', u'accessIPv6', u'addresses', u'config_drive', u'created', u'flavor', u'hostId', u'id', u'image', u'key_name', u'name', u'progress', 'project_id', 'properties', 'security_groups', u'status', u'updated', u'user_id', 'volumes_attached').

Parameter vs field

A subnet pool has parameter named max_prefixlen and default_prefixlen. On the CLI however you need to address them by their proper names: –default-prefix-length and –min-prefix-length. Can’t the devs keep this shit straight? Why am I bothering with internal field names?

[root@controller01 ~]# openstack subnet pool show POOL-SHARED-EXTERNAL
+-------------------+--------------------------------------+
| Field | Value |
+-------------------+--------------------------------------+
| address_scope_id | 1b728ba2-0a6a-4be6-9236-f8868201e68d |
| created_at | 2019-07-30T08:29:38Z |
| default_prefixlen | 8 |
| default_quota | None |
| description | |
| id | ec1010b5-c97c-4d63-82e6-291d695f5cfe |
| ip_version | 4 |
| is_default | False |
| max_prefixlen | 32 |
| min_prefixlen | 8 |
| name | POOL-SHARED-EXTERNAL |
| prefixes | 93.115.169.128/25 |
| project_id | ac72608158bd4752a8fcbf8434c24065 |
| revision_number | 0 |
| shared | False |
| tags | |
| updated_at | 2019-07-30T08:29:38Z |
+-------------------+--------------------------------------+

[root@controller01 ~]# openstack subnet pool set --default-prefix-length 28 --min-prefix-length 26 POOL-SHARED-EXTERNAL

stop commenting

2014/06/04 meh

Sometimes comments are annoying. Like the default Debian squid.conf or samba.conf. This one-liner hides the output of comments. It won’t print any lines starting with # (or empty lines).

sed -e '/^[^#]./!d' /etc/squid/squid.conf