Check These Out
It colors the machine name and current directory different colors for easy viewing.
Requires software found at: http://lpccomp.bc.ca/remserial/
Remote [A] (with physical serial port connected to device)
$./remserial -d -p 23000 -s "115200 raw" /dev/ttyS0 &
Local [B] (running the program that needs to connect to serial device)
Create a SSH tunnel to the remote server:
$ssh -N -L 23000:localhost:23000 user@hostwithphysicalserialport
Use the locally tunnelled port to connect the local virtual serial port to the remote real physical port:
$./remserial -d -r localhost -p 23000 -l /dev/remser1 /dev/ptmx &
Example: Running minicom on machine B using serial /dev/remser1 will actually connect you to whatever device is plugged into machine A's serial port /dev/ttyS0.
This provides a list of shared object names (sonames) that are exported by a given tree. This is usually useful to make sure that a given required dependency (NEEDED entry) is present in a firmware image tree.
The shorter (usable) version for it would be
$ scanelf -RBSq -F "+S#f"
But I used the verbose parameters in the command above, for explanation.
clears the history
swap out "80" for your port of interest. Can use port number or named ports e.g. "http"
underline() will print $1, followed by a series of '=' characters the width of $1. An optional second argument can be used to replace '=' with a given character.
This function is useful for breaking lots of data emitted in a for loop into sections which are easier to parse visually. Let's say that 'xxxx' is a very common pattern occurring in a group of CSV files.
You could run
$ grep xxxx *.csv
This would print the name of each csv file before each matching line, but the output would be hard to parse visually.
$ for i in *.csv; do printf "\n"; underline $i; grep "xxxx" $i; done
Will break the output into sections separated by the name of the file, underlined.
This command will return a full list of Error 404 pages in the given access log. The following variables have been given to awk
Hostname ($2), ERROR Code ($9), Missing Item ($7), Referrer ($11)
You can then send this into a file (>> /path/to/file), which you can open with OpenOffice as a CSV
Exports the result of query in a csv file
Use this command if you want to rename all subtitles for them to have the same name as the mp4 files.
NOTE: The order of "ls -1 *.mp4" must match the order of "ls -1 *.srt", run the command bellow to make sure the *.srt files will really match the movies after run this command:
paste -d: