Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
if [ "$#" -lt 1 ]; then
echo "usage: $0 <kernel_function> [<kernel_function> ...]"
echo "kernel_function - functions to trace (separated by spaces), all should be in #available_filter_functions list"
exit 1
fi
KFUNCS="${@:1}"
for KFUNC in $KFUNCS
@codersquid
codersquid / another_example.py
Last active June 25, 2024 00:56
a learning example for using a pushgateway with prometheus
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2017 Canonical Ltd.
#
# This program is free software: you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free
# Software Foundation, version 3 of the License.
#
# This program is distributed in the hope that it will be useful, but WITHOUT