Bash: File Server Hourly Backup Script

Administration, Info.Tech, Linux System Administration Comments Off on Bash: File Server Hourly Backup Script

Been creating bash backup scripts but every time I create for the new server, I forgot the commands and research again. This time, I’m gonna save it in my blog so that I will search it in one place. Hehehe…


cd /backup/

DATE=$(date "+%Y%m%d%H%M%S")


# find -mtime -1 | xargs cp -t --parents "$BACKUPNAME/"

find /jdrive/ -mmin -60 -exec cp --parents '{}' "$BACKUPNAME/" \;

tar -zcvf "ibackup/$BACKUPNAME.tar.gz" "$BACKUPNAME/"

rm -rf "$BACKUPNAME/"

# file and delete all files smaller than the specified filesize
find /backup/ibackup/ -name "*.gz" -size -500 -delete

# file and delete all files that are older than 45 days
find /backup/ibackup/ -mtime +45 -type f -exec rm -rf {} \;

Here you go… My home-brewed incremental backup script. We usually use duplicity but it failed us twice. So, we are using now both my home-brewed script and duplicity. Oh! by the way,  I used this script for our file server only.

POLi Payment Gateway: Why you shouldn’t use this option…

Info.Tech, Security Concerns, Web Development 2 Comments »







The first time I saw POLi payments was in Qantas Airlines New Zealand. The moment I saw asking for my Bank Credentials, I click back button ripoli_3ght away.

Why? Because POLi is asking your Access Code/Username and Password of your bank, your BANK CREDENTIALS! Imagine your hosts file has been altered by malware or any virus or your network has been hacked or exploited or your ISP has been hacked or whatever above your internet line has been altered pointing POLi payment gateway’s DNS to different server, you will be giving your bank access to the hackers. And POLi is a direct access to your bank account (your entire assets in your bank) and initiate the transaction right away. Unlike credit cards, if your card has been expospoli_2ed, then the risk is JUST your card, not your whole account in the bank then you still have time to call the bank the close it right away.

So my advise never use POLi payments. I’m not against the company or the people who created it but I am just against how the implementation or how it works.

OCZ SSD is the worst SSD!

Computer Hardware, Info.Tech Comments Off on OCZ SSD is the worst SSD!

ocz_ssdOK, let me share this to the world how bad this OCZ SSD.

Bought 3 OCZ SSD months ago. First SSD is where my OS installed, Windows 7 Professional. 2nd SSD is my MySQL Database, 3rd SSD is my Development Source Codes.

OS SSD crashed first after 6 months and undetectable. Then the vendor replaced the SSD with Samsung and works fine until now. Next is the DB SSD crashed after 9 months. Dev SSD crashed after 12 months.

How can you rely on these OCZ SSDs? I lost tons of files because of these SSDs. If you want SSD, buy Intel SSD or Samsung SSD and they are the reliable brands. Never again be fooled with those other SSDs. Too much promising yet they are all crap!


iMac Reset Password or Factory Reset without losing the data

Apple Stuff, iMac Troubleshooting Comments Off on iMac Reset Password or Factory Reset without losing the data

Restart your computer and press COMMAND + S then this will enter to terminal mode.

First you need to mount the “root” path before you can modify the disk.

:/ root# mount -uw /

Now after mounting the root path, you have two option here, factory reset or reset password of a user so you can access the files.

Factory Reset

In factory reset, all you need is to delete the file /var/db/.applesetupdone then OS X will detect that the system has run the first time (but the data are all intact).

rm /var/db/.applesetupdone

User Reset Password

In user reset password, this is what you will do:

  1. go to /Users directory then list the files and folders
  2. whoever you want to reset the password, just type passwd <username>
  3. then this will ask you for the new password and confirm new password
  4. that’s it
:/ root# cd /Users
:/ root# ls -lsa
:/ root# password user1
Enter New Password: 
Confirm Password:

:/ root# reboot

then type exit or reboot or restart the machine.

then you all good to go…

iMac Intel Diagnostic LED’s

Apple Stuff, iMac Troubleshooting Comments Off on iMac Intel Diagnostic LED’s

To observe the LED’s you need to apply power to the iMac with the front bezel off. Please ensure you don’t touch any part of the iMac or the exposed circuit boards while you have power connected.

Locate the Diagnostic LED’s between the RAM slots and the SATA connector.

The LED’s are numbered 1-4 from left to right. You may need to move the SATA cable to get a clear view of the LED’s.

If you are using this guide for iMac Intel 20″ EMC 2210 and 2133 the LED’s are located above the SATA connector and not as visible.

  • LED 1 – Indicates that the trickle voltage from the power supply is detected by the main logic board. This LED will remain ON while the iMac is connected to the AC power. The LED will remain on even when the computer has been shut down or put to sleep. The LED will turn off only if the AC power is disconnected or the power supply is faulty.
  • LED 2 – Indicates that the main logic board has detected proper power from the power supply when the computer is turned on. This LED will be ON when the computer is turned on and the power supply is working correctly.
  • LED 3 – Indicates that the computer and the video card are communicating. This LED will be ON when the computer is communicating properly with the video card. If LEDs 1 and 2 are ON and you heard the startup sound, but LED 3 is OFF, then the video card might be installed incorrectly or need replacement.
  • LED 4 – Indicates that the computer and the LCD display panel are communicating. This LED will be ON when the computer is turned on and video signal is being generated. If the LED is ON and there is no image on the LCD display panel, the LCD display panel or inverter might be installed incorrectly or need replacement.


Facebook Messenger Desktop

Info.Tech, Software Development, Visual C# .Net Comments Off on Facebook Messenger Desktop

Just for fun I made a Facebook Messenger Desktop version. This can be used if you don’t want to use the browser and would be ideal when you’re at work. 🙂

The application can minimize at the taskbar notification area which will be hidden away from your other opened applications.

Disclaimer: This is not the official facebook messanger desktop version but this is just framing facebook web-based messenger.


Visual C# .Net and rsync

Experimentals, Info.Tech, Software Development, Visual C# .Net 2 Comments »

Today, I was wondering if possible to use rsync in Visual C# .Net. After couple of searches, I finally got my answer and working sample project.


I would like to share my Visual C# .Net source code project since I found many developers were looking for a working sample. I am planning to create a class wrapper too and deposit it on GitHub soon.

My GitHub:
Download: Visual C# .Net and rsync (723)

My First Android App

Android, Info.Tech, Mobile Development Comments Off on My First Android App

This is my first android app, you can use it if you want. Its just a simple WebView though. The backend is using Silex PHP Framework and MySQL as the DB.


Notes Locker (585)

Download Notes Locker

QVNZ Viewer (ASC file viewer)

Info.Tech, Software Development Comments Off on QVNZ Viewer (ASC file viewer)

For everyone looking for ASC file viewer or QVNZ .asc file, if you are wondering what application can view the file, you can download and use the application I have created. This will view the contents of ASC file for QVNZ.


Update 4 August 2015:

I improved the viewer, its QVNZ Editor now. So you can edit the Cell then Save or Save As.


QVNZ Viewer (642)   |   QVNZ Editor (556)


Download at:

Computer Online Shop in New Zealand

Info.Tech, People, Personal, Wooow! 2 Comments »

I just found the reliable and best way to shop online with computer parts, accessories etc. Just browse at and you’ll get the best deal. 🙂


WP Theme & Icons by N.Design Studio
Entries RSS Comments RSS Log in