Skip to content

Instantly share code, notes, and snippets.

View Millnert's full-sized avatar

Martin Millnert Millnert

  • BrainMill AB
  • Sweden
View GitHub Profile
@Millnert
Millnert / gist:b6dd2c7d5d1b94f661b9
Created February 8, 2016 09:54
Updating forks to new stable release
1. clone our fork: git clone git@github.com:IPnett/puppet-keystone.git
2. add upstream remote: git remote add upstream git@github.com:openstack/puppet-keystone.git
3. git remote update
4. in case our fork has become lobotimzed and had branch switched, get master: git checkout -t -b master origin/master
5. update master from upstream: git merge upstream/master
1. i had to do git merge -s recursive -Xtheirs upstream/master
2. git push
6. sync stable/kilo if it exists in our fork:
1. git checkout -t -b stable/kilo origin/stable/kilo
2. git merge -s recursive -Xtheirs upstream/stable/kilo
@Millnert
Millnert / derived_static_if.pp
Created January 23, 2016 17:43
Puppet defined type execution order issues
# IPnett defined type for a so called 'derived' static interface:
# It clones the settings of a master interface
#
# The master interface may or may not be managed automatically.
# The derived interface will change according to changes done to the
# master interface. Manual changes only: the derived interface will
# follow suit. Automatic changes: the derived interface will follow.
#
# $target_interface:
# - the interface to clone settings *to*
@Millnert
Millnert / testqueries.sql
Created January 7, 2016 16:04
puppetdb SQL queries
SELECT DISTINCT certname FROM factsets WHERE producer_timestamp > now()::timestamp - interval '1 week';
SELECT DISTINCT fs.certname, f.factset_id, f.fact_path_id, f.fact_value_id FROM facts f
INNER JOIN factsets fs ON fs.id = f.factset_id
INNER JOIN fact_values fv ON f.fact_value_id = fv.id
INNER JOIN fact_paths fp ON f.fact_path_id = fp.id
WHERE fs.producer_timestamp > now()::timestamp - interval '1 hour';
@Millnert
Millnert / service.pp
Created January 3, 2016 00:49
quagga/service.pp
# Configures a service for quagga
class millnert::quagga::service {
if $millnert::quagga::restart_on_change {
$subscription_base = [
File['daemons'],
File['debian.conf'],
File['zebra.conf']
]
@Millnert
Millnert / contrailcontroller_bugs_closed_in_master_but_not_R2.21.x.txt
Created December 3, 2015 13:34
contrail 2015-12-03 - bugs closed in master but not in R2.21.x
1380750: Floating IP and service chaining do not work together
1430089: Make service chaining and static route code address family agnostic
1438434: NOT ACCESSIBLE FROM LAUNCHPAD
1440269: config: Use introspection more than code autogeneration for better maintainability
1455666: NOT ACCESSIBLE FROM LAUNCHPAD
1459473: discovery server not load balancing newly added publishers
1461163: Flow Drop Reason or Cause Code - ER
1462056: NOT ACCESSIBLE FROM LAUNCHPAD
1466731: QFX does not handle transient duplicate VxLAN id for two different VNs
1469415: NOT ACCESSIBLE FROM LAUNCHPAD
@Millnert
Millnert / ceph.spec.in
Created November 11, 2015 23:06
ceph.spec.in for local builds
# vim: set noexpandtab ts=8 sw=8 :
#IPnett modifications
%define LOCAL_BUILD 1
%define LOCAL_PREFIX ipnett-
%if %{LOCAL_BUILD}
%global pkgprefix %{LOCAL_PREFIX}
%global origpkgprefix ceph-
%else
%global pkgprefix %{nil}
@Millnert
Millnert / nfs_lock_stack_trace
Last active February 28, 2017 13:18
Stack trace and source code references from a RHEL 7.1 NFS lock bug
Apr 18 21:01:26 tsm1 kernel: [<ffffffffa07045a0>] ? nfs_pageio_doio+0x50/0x50 [nfs] http://lxr.free-electrons.com/source/fs/nfs/pagelist.c?v=3.10#L394
Apr 18 21:01:26 tsm1 kernel: [<ffffffff8160954d>] io_schedule+0x9d/0x130 http://lxr.free-electrons.com/source/kernel/sched/core.c?v=3.10#L4512
Apr 18 21:01:26 tsm1 kernel: [<ffffffffa07045ae>] nfs_wait_bit_uninterruptible+0xe/0x20 [nfs] http://lxr.free-electrons.com/source/fs/nfs/pagelist.c?v=3.10#L261
Apr 18 21:01:26 tsm1 kernel: [<ffffffff81607320>] __wait_on_bit+0x60/0x90 http://lxr.free-electrons.com/source/kernel/sched/wait.c#L387
Apr 18 21:01:26 tsm1 kernel: [<ffffffffa07045a0>] ? nfs_pageio_doio+0x50/0x50 [nfs] http://lxr.free-electrons.com/source/fs/nfs/pagelist.c?v=3.10#L394
Apr 18 21:01:26 tsm1 kernel: [<ffffffff816073d7>] out_of_line_wait_on_bit+0x87/0xb0 http://lxr.free-electrons.com/source/kernel/wait.c?v=3.10#L209
Apr 18 21:01:26 tsm1 kernel: [<ffffffff81098260>] ? autoremove_wake_function+0x40/0x40 http://lxr.free-electrons.com/source/ker