function displaytime { local T=$1 local D=$((T/60/60/24)) local H=$((T/60/60%24)) local M=$((T/60%60)) local S=$((T%60)) (( $D > 0 )) && printf ‘%d days ‘ $D (( $H > 0 )) && printf ‘%dRead More…
Wrong Port Connected Check With ifconfig
We need to run ifconfig and look for the status line. Remember this about ifconfig output: * if “status: active“, the port is linked up and sending traffic (now you just needRead More…
My Favorite Partition Tool for Windows
Its free too: MiniTool Partition Wizard Free It does everything that EaseUS Partition Manager does (but MiniTool is free and therefore get more points). Tools like this in Linux are free (andRead More…
Grepping Thru All Rotated Logs
If your system gzips and rotates your logs. You can use this trick to search thru all of them. # zgrep -i — “SEARCHTERM” $(ls -1Str /var/log/messages*) Another way # zgrep -iRead More…
A good free syslog server
Personally, I just tried “Syslog Watcher” version 5.0.4 and it does a good job. I can start it by hitting “Start Server” then configured syslog clients to point at it. You canRead More…
Find UPNP devices on your network – ex: ReadyDLNA or UPnP routers
Got info from here: https://stackoverflow.com/questions/18363833/how-can-i-list-upnp-server-renderer-in-command-line-console-mode-on-linux Get the Upnp test tools # apt-get install gupnp-tools Example 1: Find all Upnp devices (note their target names start with urn:…. It will hint at what service itRead More…
bash simple variable substitution
You can use bash to do simple substitutions of variables, just like you can with sed. The bash trick turns out to take up less characters (bytes). Lets set some variable VAR1="thisRead More…
Windows – cmd – which domain controller is my PC joined to
Use this trick from cmd (command prompt) to see which Windows Active Directory Server you are connected to H:\>echo %logonserver% \\AD4 Also set l The end
Bash scripting dealing with any characters in strings or filenames
Imagine a file list, list.txt, like this one image1.jpg image2.jpg image3.jpg Naturally you could deal with it like so cat list.txt | while read i; do FILE="$i" dosomething "$FILE" done Or justRead More…
My Favorite X-Plane 10 / 11 Controls – Rudder, Joystick & Throttle Setup
I do not take credit for this controller layout. I really like it and would like to have a copy easily available so I hosted it here, also I would like toRead More…