Skip to content

Instantly share code, notes, and snippets.

View FlorianHeigl's full-sized avatar

Florian Heigl FlorianHeigl

View GitHub Profile
@FlorianHeigl
FlorianHeigl / log4j block
Created December 12, 2021 21:10
elender mist
209.141.45.227
209.127.17.234
197.246.171.111
195.123.247.209
185.107.47.215
178.17.171.102
150.158.189.96
145.220.24.19
121.5.219.20
103.103.0.141
#!/bin/sh
# source in blogpost comment at
# https://technicalexperiments.wordpress.com/2015/10/30/zte-mf831-for-use-with-openwrt-serial-modem-instead-of-cdc_ether/comment-page-1/
wLog(){
case $debug in
0)
logger "${0##*/}: $1"
;;
esac
return 0
@FlorianHeigl
FlorianHeigl / cobextractor.c
Created September 25, 2021 21:09
cobextractor
/*
cobextractor v1.0 - (C)2005 Eddy L O Jansson <srm_dfr@hotmail.com>
THIS SOFTWARE IS DONATED TO THE PUBLIC DOMAIN AND FREELY REDISTRIBUTABLE
Purpose:
cobextractor will extract the individual resources from the .COB resource
files[0] used by the IBM-PC version of the old computer game Ascendancy.
Some of the music is stored as raw 22KHz mono samples, which can be
converted to RIFF WAVE using sox like so:
sox -c1 -u -b -t raw -r 22050 theme04.raw theme04.wav
I wrote this to hunt for the music, which I remembered as being very
@FlorianHeigl
FlorianHeigl / local_check_quota.ps1
Last active May 4, 2021 21:35
check_mk local quota check - extended version
#Requires -Modules @{ ModuleName='FileServerResourceManager'; ModuleVersion='2.0' }
<#
.SYNOPSIS
Check_MK Plugin to monitor Quotas
.DESCRIPTION
Check_MK Plugin to monitor Quotas with FSRM Module.
.EXAMPLE
PS C:\> ./local_check_quota.ps1
@FlorianHeigl
FlorianHeigl / prereqs.md
Last active April 24, 2021 21:20
access checkliste

Frontend Node:

  • ssh key generated (tested format: rsa, 4k, no passphrase)
  • ssh key of the array is stored in .ssh/known_hosts
  • ssh key converted to ietf format
  • ~oneadmin/.ssh/config has been setup
  • ssh host key of both array controllers has been scanned
  • IQN from /etc/iscsi/initiatorname.iscsi has been collected
@FlorianHeigl
FlorianHeigl / rsync-copy.sh
Created April 18, 2021 13:35
fault tolerant rsync backup script
#!/bin/bash -u
STOREDIR=/srv/backup
NICE="ionice -c3 nice -n 19"
run_rsync()
{
# use -vv to gather options for remote server to put in .ssh/authorized_keys
# that way you can limit rsync to intended use (sender will be fixed)
@FlorianHeigl
FlorianHeigl / vagrant-box-extract.sh
Created April 13, 2021 01:23
on-the-fly extracting images from vagrant box
gzip -dc windows2019-server-packer-template-libvirt-1618183429.box | tar -C /mnt/upload -xvf - box.img
@FlorianHeigl
FlorianHeigl / gist:f0cb46d95dfa69634ad64d0e36f51290
Created March 9, 2021 20:28
docker netbox napalm und co issues
```
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
napalm-s350 0.3.1 requires napalm>=3.0.0, but you have napalm 2.5.0 which is incompatible.
napalm-s350 0.3.1 requires netmiko>=3.1.0, but you have netmiko 2.4.2 which is incompatible.
napalm-procurve 0.6.0 requires napalm>=3.0.0, but you have napalm 2.5.0 which is incompatible.
napalm-aos 0.2.1 requires napalm==2.3.1, but you have napalm 2.5.0 which is incompatible.
```
@FlorianHeigl
FlorianHeigl / junos-netflow.cmd
Last active March 6, 2024 12:41
Configure Juniper NFX NexGen NetFlow (inline)
set system ntp server ntp1.ispname.net
set interfaces ge-1/0/2 unit 0 family inet sampling input
set interfaces ge-1/0/2 unit 0 family inet sampling output
set services flow-monitoring version9 template ipv4-test ipv4-template
set forwarding-options sampling instance test-ins family inet input rate 100
set forwarding-options sampling instance test-ins family inet input run-length 19
set forwarding-options sampling instance test-ins family inet output flow-server 172.16.xx.xx port 2055
set forwarding-options sampling instance test-ins family inet output flow-server 172.16.xx.xx version9 template ipv4-test
set forwarding-options sampling instance test-ins family inet output inline-jflow source-address 192.168.x.x