Archive

Archive for the ‘BashScripts’ Category

Reverse SSH script

July 20th, 2009 No comments

This script allow us to connect to a remote server. It can be usefull when a client need remote support.
We can mail the script and ask him to execute it.

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

Linux connection check

March 20th, 2009 No comments

Ubuntu 8.10 Hardy Connectivity Check, Internet Connection test and repair.
I am not sure why but my ubuntu at home keeps losing the connection and I have to manualy disable and enable Network Manager.
So I wrote this:

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

Linux .bashrc script

March 18th, 2009 No comments

Login script to set nice prompt, colors,alias, history.

Download

Read more…

VN:F [1.7.5_995]
Rating: 5.0/5 (1 vote cast)

Currency rate monitor script

December 10th, 2008 1 comment

Using Nagios I am able to monitor the currency conversion rate, so I can know exactly when to sell my currency and to buy my currency. I wrote a creative plugin to nagios that does just that!
Its not my best bash code, I should really rewrite in perl. But the idea is here, and it works.
Anyone wants to build a nagios just to monitor and graph currency exchange rates? I am up for it.
Example:
bash currencymon.sh
Usage: currencymon.sh [--minwarn value] [--maxwarn value] [--mincrit value] [--maxcrit value] [-v|--verbose]
# bash currencymon.sh 2.65 2.95 2.55 3.15
MONEYX OK: Value of EURO is – 3.1623
The current conversion is from Euro x Real, inside the script there is a parameter to change it.
currencymon.sh

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

CheckFileSize VBS for Nagios

October 22nd, 2008 10 comments

Nagio/NRPE_NT VBS Script to check the size of file(s) inside a Folder.

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

Backup nagios

October 21st, 2008 No comments

.
.
Nagios/Linux easy backup method
No backup tapes, no FTP. Just simple, mount a remote share and put files there.
The important part is to mount the share when the system starts up, so we
will could also edit the /etc/fstab file. But before editing make sure to try the mount
commands to make sure they work. I konw old kernels did not support smbfs or cifs,
and in that case maybe best to just use old FTP. I choose to mount and then
unmount when done.

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

Nagios script to load host

October 9th, 2008 No comments

.
.
.
When you have to load 400 IPs into Nagios/Centreon configuration, how do you do it? By hand?
Well, I wrote a script that pulls all hosts from a CVS file with the fields (HOSTNAME,INFO,IP)
and generates de hosts.cfg file that can afterwards be Loaded by the web frontend of Centreon.

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

Install BackTrack USB

September 2nd, 2008 1 comment

BackTrack is one of the best Live Linux out there, it is complete with many network secuirty tools.
Yes you can also just burn the CD version, but the USB is more complete its RW and smaller to carry around.

Download BackTrack3 Final USB bt3final_usb.iso (783MB):

Read more…

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)

Backup MySQL

June 5th, 2008 No comments

The will backup MySQL running under Linux
Schedulle it to run using crontab:

# crontab -e


#!/bin/bash
# Backup MYSQL DB

Read more...

VN:F [1.7.5_995]
Rating: 0.0/5 (0 votes cast)
Tags: