Category: Scripts

php html dropdown menu handling

Currently I do write a very simple PHP based web tool to alter VLAN configuration on a Cisco switch with php-snmp. Now I would like to have a coll button to do that. And this is the way forward: Links:…

VLC – multicast sender vbscript

To start VLC as a multicast sender I wrote a simple vbscript. It checks the folder “d:\movies”and shows all files included in a input box and tries to start vlc with the selected source file. I downloaded some Free Movies…

Obtain information from Cisco via powershell and SSH

Just to see how many concurrent VPN sessions are open an a Cisco router the following OIDs should help: cikeGlobalActiveTunnels – .1.3.6.1.4.1.9.9.171.1.2.1.1.0 cipSecGlobalActiveTunnels – .1.3.6.1.4.1.9.9.171.1.3.1.1.0 If it still doesn’t work, try to walk the following object: .1.3.6.1.4.1.9.9.171 Ttaken from https://supportforums.cisco.com/thread/180508…

Putty Logfiles with timestamp

I am just trying to automate my Cisco telnet and SSH connection to get nice information that is not provided by the Cisco SNMP Mib jet. I am talking about the “show crypto session” command. The output looks a little…

up count with fix character length

Sometimes it is quite important to have all the time the same length of characters. A small bash script can help and with “printf” the beginning indicated has always the same length. #!/bin/bash count=0 #counter equals zero # star loop…

Get external IP via bash

To get your external IP via a small bash script #!/bin/bash # Define parameters LOGFILE=”/tmp/extip.log” DATE=$(date “+%Y%m%d-%H%M”) GETIP=$(wget -q -O – checkip.dyndns.org | sed -e ‘s/[^[:digit:]|.]//g’) test -f $LOGFILE || echo “no LOGFILE” touch $LOGFILE GETLOGIP=$(tail -n 1 $LOGFILE |…

Ping – Host Check

A short script to perform a continuous ping to check the availability of a certain server / host. execute: ./pingscript.sh <ping count> <target> <additional delay> ./pingscript 5 192.168.0.1 25   #!/bin/bash # set varables COUNT=$1 TARGET=$2 DELAY=$3 COUNT=0 LOGFILE=”./host_check.log” #…