Fail2Ban – From Temporary to Permanent Bans

I had problems with SSH brute force attempts.  I installed fail2ban, but it tends to allow the users to retry “eventually”.  So I looked for more permanent solutions and really, it couldn’t be any easier to implement permanent bans.  Fail2ban allows a dive into its own log to root out culprits and you can follow it below.  My preference is permanent ban with a script through crontab which is further below.

(more…)

Hammer Storage HZD4B Personal Storage Manager PSM

No tricks, no cost.

Download the Hammer Storage HZD4B Personal Storage Manager (PSM) from us directly.  Since the file is no longer available through Zeceta, Avnet, or Hammer-storage.com, we will provide it here, for free unlike those greedy people on eBay, and other sources (I bought it to provide it for you for free).  Please though, feel free to donate if you feel this site is a good service.

Hammer Storage, HZD4B Personal Storage Manager PSM PSM 1.5.4C (2811 downloads)

SSD & HDD Overprovisioning setting and removal

Sometimes a purchase of a SSD or HDD turns out to be over-provisioned.  Basically this mean some part of the drive is used for storage to replace bad spots that cause errors.  In linux this is fairly easy to check, set and remove.  Mac OSX and Windows, not so much.  Open a VM and install linux or boot to a USB key with linux to make life easier.  If I find an easy way in any other OS, I’ll post it here.

There are two methods for manual over-provisioning, HPA (Host Protected Area) and DCO (Disk Configuration Overlay), with DCO being the preferred method.  Both are configured with hdparm. (more…)

Removing GPT information from a drive

Removing GPT information from a drive


Linux/Unix:

Method #1:

1. Press CTRL-ALT-F2 or F3.
2. Type “parted /dev/<devicename>”, usually “parted /dev/sda”.
3. Once inside parted type “mktable”:
-> Table type: msdos
-> Destroy data: yes
-> quit
4. GPT should now be removed.
5. Continue with install.

Method #2:

1. fdisk -s /dev/<devicename> — This gets the blocksize of the device.
Make the last five digits of this number zeros. Example: fdisk -s /dev/sda
Will show an error about GPT, and then the block size: 39078144
Change to 39000000 which equals our blockcount
2. dd if=/dev/zero of=/dev/devicename bs=1k seek=blockcount
3. dd if=/dev/zero of=/dev/devicename bs=1k count=20

Method #3:

1. Press CTRL-ALT-F2 or F3.
2. Type: “dd if=/dev/<devicename” of=/dev/zero bs=4k”
3. When done, continue with install.

Windows Vista/7/2008/BartPE/WinPE/WinXP Live:

Method #1:

1. Boot up to installation DVD/CD.
2. Click install but don’t follow through.
3. Press SHIFT-F10 to bring up console.
4. Type “diskpart”
5. Once inside diskpart type:
-> list disk (find the one you want to convert)
-> select disk 0 (select the one you want from the list)
-> convert mbr (should take a second or two)
-> quit
6. Continue with install

Method #2:

1. Boot up to installation DVD/CD.
2. Click install but don’t follow through.
3. Press SHIFT-F10 to bring up console.
4. Type “diskpart”
5. Once inside diskpart type:
-> list disk (find the one you want to convert)
-> select disk 0 (select the one you want from the list)
-> clean (wait an hour or so until its done)
-> quit
6. Continue with install

vi – my CLI editor of choice

My editor of choice is “vi”.    Here are some useful stuff I use often.

If you can’t use arrows to navigate, use the built in navigation of vi: h, j, k, l.  Its easy to remember the directions if you live in the US.  Not so much elsewhere.

h = Left (Think Hawaii)
j = Down (Think Jamaica)
k = Up (Think Kanada [Yeah, lame but it works])
l = Right (Think London)

To search for text, type  /<text to search for>.  To go to the [n]ext find press “n“.  To go to the previous press “N“.  The capital of next.  /crap (more…)