Skip to content

Instantly share code, notes, and snippets.

@jkullick
jkullick / ldap-query-filter-enabled-users-active-directory-ou.md
Last active January 17, 2017 08:46
LDAP Query to Filter enabled Users in Active Directory OU

(memberOf:1.2.840.113556.1.4.1941:=CN=admins,OU=security,DC=test,DC=org)

@jkullick
jkullick / show-login-sessions-remote-windows.md
Created January 16, 2017 16:12
Show Login Sessions on Remote Windows
query user /server:$TARGET
@jkullick
jkullick / check-mtu-ping-manual-pmtud.md
Last active January 12, 2017 14:56
Check MTU with Ping / Manual Path MTU Discovery
# Linux
ping -M do -s 1500 -c 1 $HOST

# macOS
ping -c 1 -D -s 1500 $HOST

# Windows
ping -n 1 -l 1500 -f $HOST
@jkullick
jkullick / show-tcpip-stats-windows.md
Last active January 12, 2017 10:12
Show TCP/IP Stats on Windows
netsh interface ipv4 show ipstats

netsh interface ipv4 show tcpstats

If In Errors, In Header Errors or Fragments Failed have a value >0, there is a physical wire problem.


Source

@jkullick
jkullick / openvpn-server-ubiquity-edgerouter.md
Last active January 11, 2017 15:03
OpenVPN Server on Ubiquity EdgeRouter
@jkullick
jkullick / enable-umlaute-archlinux-xorg-terminal-emulator.md
Last active January 12, 2017 15:14
Enable Umlaute in ArchLinux/Xorg Terminal Emulators
cat > /etc/locale.gen << EOF
de_DE.UTF-8 UTF-8  
en_US.UTF-8 UTF-8
EOF


cat > /etc/locale.conf << EOF 
LANG="en_US.utf8"
LC_COLLATE="C"
@jkullick
jkullick / sync-windows-time-ntp.md
Created January 10, 2017 14:33
Sync Windows Server Time with NTP
w32tm /resync /computer:time.windows.com /nowait
@jkullick
jkullick / sync-windows-time-domain-controller.md
Created January 10, 2017 14:31
Sync Windows Time with Domain Controller
net time /DOMAIN:$DOMAIN /set /y
@jkullick
jkullick / set-vmware-esxi-hardware-clock.md
Last active January 10, 2017 15:26
Set VMware ESXi Hardware Clock
esxcli system time set -y 2017 -M 01 -d 10 -H 15 -m 20 -s 01
esxcli hardware clock set -y 2017 -M 01 -d 10 -H 15 -m 20 -s 05

Note: Timezone is UTC


Source

@jkullick
jkullick / backup-restore-mbr-dd.md
Created January 9, 2017 16:39
Backup & Restore MBR with dd
# backup mbr to file
dd if=/dev/sda of=mbr.img bs=446 count=1

# restore mbr to disk
dd if=mbr.img of=/dev/sda bs=446 count=1