Skip to content

Instantly share code, notes, and snippets.

@suuhm
suuhm / zabbix-swap-fix.sh
Created December 28, 2021 12:35
zabbix swap file missing fix
#!/bin/sh
sudo dd if=/dev/zero of=/var/swapfile bs=1M count=1048 && \
sudo chmod 600 /var/swapfile && \
sudo mkswap /var/swapfile && \
echo /var/swapfile none swap defaults 0 0 | sudo tee -a /etc/fstab && \
sudo swapon -a
exit 0
@suuhm
suuhm / kali-linux-grub2-efi-fix.sh
Last active December 28, 2021 11:51
Kali / Ubuntu / Debian Linux update efi grub/ grub2 bootloader and set correct bios systime
#!/bin/bash
#
# Kali / Ubuntu / Debian Linux update efi bootloader and set correct bios systime
# (C) 2021 suuhm
#
apt clean; apt update && apt install os-prober ntpdate
echo "Set up correct time:"
ntpdate pool.ntp.org && hwclock --systohc
@suuhm
suuhm / unifi-control-led.sh
Created October 27, 2021 22:32
Unifi set Controller inform in different Subnet and LCD Color Changer
# ssh in AP and run:
# set-inform http://ip.of.the.controller:8080/inform
#
# suuhm 2021
# echo '2' >/proc/gpio/led_pattern
mgmt.is_default=false
mgmt.led_enabled=true
mgmt.cfgversion=x
mgmt.authkey=x
@suuhm
suuhm / odhclient.sh
Created October 27, 2021 22:27
openwrt dhclient replacement script to renew dhcp addresses - chmod +x ./odhclient.sh && ./odhclient.sh <DEVICE> <MAC>
#!/bin/bash
#eth0.23 - MAC: 9C:80:DF:22:11:11
#
# suuhm (c) 2021
#
# ./odhclient.sh <DEVICE> <MAC>
#
echo "Settings up now... Device $1 - MAC $2"
udhcpcd -k $1
@suuhm
suuhm / Aplitube_Runner_v0.1.bat
Last active October 26, 2021 21:20
Amplitube Runner and Driver Activator - needs to run as Admin and terratec-ts22-driver-start-stop.bat
@echo off
echo check for TS PCI State...
C:\Windows\System32\cmd.exe /c start C:\terratec-ts22-driver-start-stop.bat enable
echo run aplitube now...
ping -w 2000 -n 1 2.0.0.0 >nul
cd "C:\Program Files\IK Multimedia\AmpliTube 4"
start "C:\Program Files\IK Multimedia\AmpliTube 4" "AmpliTube 4.exe"
@suuhm
suuhm / winxp-activate-extend.bat
Created September 22, 2021 20:21
Windows XP Professional Activate and extend activation period (OOBE method) with logfile write
@echo off
echo
echo ****************************************
echo **** now activating - by suuhm 2020 ****
echo ****************************************
echo
REM seleeping here:
@ping -n 2 localhost> nul
reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WPAEvents" /v OOBETimer /t REG_BINARY /d EB548CC60E451759555BF4 /f
@suuhm
suuhm / terratec-ts22-driver-start-stop.bat
Last active October 26, 2021 21:17
Terratec TS22 Windows 7 x64 Driver fix to bypass the Shutdown bug. Just create shortcuts or set in sheduler
@echo off
SETLOCAL EnableDelayedExpansion
::
:: (c) Suuhmer - 2021
:: All rights reserved
::
:: call: terratec-ts22-driver-start-stop.bat [enable|disable]
::
:: YOU HAVE TO RUN AS ADMIN THIS SCRIPT!
::
@suuhm
suuhm / azuread-autosync.ps1
Last active July 8, 2021 17:50
Azure AD Auto synchronisation on startup - AD365
Write-Host "Starting Sync on Prem"
net stop AdSync
net start AdSync
#@ping 127.0.0.1 -n2 >nul
sleep 2
Start-ADSyncSyncCycle -PolicyType Initial
Write-Host "Done"
@suuhm
suuhm / frox_backupdater.sh
Last active September 18, 2024 22:14
Froxlor Smart Backup - (Auto) Update - Restore Script
#!/bin/bash
#
# FROX_BACKUPDATER SCRIPT
#
# FEATURES: BACKUP (DEFUALT) / UPDATE LATEST VERSION / RESTORE BACKUP
#
# COPYRIGHT 2020 SUUHMER
# DEV.COLDWAREVERYDAY.COM
#
# USAGE:
@suuhm
suuhm / remove-android-bloatware.sh
Created April 1, 2021 22:14
Removing Bloatware from Samsung Android Devices with adb shell
# More infos Infos from https://technastic.com/remove-samsung-bloatware-safe-to-remove-apps/
# To get a list of all packages:
# pm list packages
# shell pm list packages | grep -i 'samsung'
echo "Vodafone ebay amazon etc first..."
pm uninstall -k --user 0 com.ebay.carrier
pm uninstall -k --user 0 com.vodafone.vodafone360updates
pm uninstall -k --user 0 com.vodafone.smhs