Welcome to my not so new site

Its not so new anymore, I mainly use the site for posting useful information that I use at work.

Well its about time I got around to get my site up on the internet again, I’ve been on and off (mostly off) for over a decade. That’s a long time, and no one noticed. Maybe its about time this changes.

Welcome… hopefully I’ll do something constructive here.

Posted in Uncategorized | Leave a comment

Disable soft keys in Android

Edit build.prop
Add the following to the end of the file:

Posted in Tips and Tricks | Tagged , , | Leave a comment

XDA [How-To] Disable Forced Encryption

XDA [How-To] Disable Forced Encryption – Nexus 6



  • Extract the Android Image Kitchen zip Android_Image_Kitchen.zip
  • drag in the boot.img file you wish to modify onto the unpackimg.bat file
  • you should get a command window pop up, it should say succesfull and you will get a few folders added.
  • open the ramdisk folder and open the fstab.shamu file using notepad++
  • search for forceencrypt and replace it with encryptable. there should be only one case where this exists.
  • save the file, go back to the root of the image kitchen folder, and run the repackimg.bat file.
  • you should get a new boot.img build called image-new.img, you can use this now to flash on your device



Posted in Tips and Tricks | Tagged , | Leave a comment

Tell apt-get not to install “recommends” packages in Debian Linux

Tip: Tell apt-get not to install “recommends” packages in Debian Linux


Purpose: If you are using Debian Lenny and are installing software packages using apt-get then you might have noticed the new version of apt-get in Lenny installs the “recommends” packages automatically thus increasing the number of packages installed on your computer. The “apt-get” in Debian Etch (4.0) did not use to install “recommends” packages.  In this post, we will see how we can permanently tell apt-get NOT to install “recommends” packages.  For those of you who are not sure about Debian’s “depends”, “recommends” and “suggested” packages, please refer to this doc. This is important if you have limited storage space on your system, say for example an embedded system.

Posted in Tips and Tricks | Leave a comment

UUID/GUID using Windows Powershell

get-wmiobject Win32_ComputerSystemProduct | Select-Object -ExpandProperty UUID

Posted in Tips and Tricks | Leave a comment

Searching for a String in a file on Linux

Here’s one way using grep:

grep -rnw <dir> -e <pattern>
Posted in Tips and Tricks | Tagged | Leave a comment

Adjust Windows DNS settings from command line

If you ever wanted to change the DNS settings on Windows 7/8 here’s how you do it.

Open a command prompt with Administrator privileges, and type the following:

netsh interface ip set dns name="Wi-Fi" static

Secondary DNS:

netsh interface ip add dns name="Wi-Fi"

If you want to change to use DHCP Server provided DNS do this:

netsh interface ip set dnsservers name="Wi-Fi" source=dhcp
Posted in Tips and Tricks | Tagged | Leave a comment

Secure Erase SSD in Linux

Original Article: https://wiki.archlinux.org/index.php/SSD_memory_cell_clearing

Step 1 – Make sure the drive security is not frozen

Issue the following command:

# hdparm -I /dev/sdX

Step 2 – Enable security by setting a user password

Note: When the user password is set the drive will be locked after next power cycle denying normal access until unlocked with the correct password.

Any password will do, as this should only be temporary. After the secure erase the password will be set back to NULL. In this example, the password is “PasSWorD” as shown:

# hdparm --user-master u --security-set-pass PasSWorD /dev/sdX
Issuing SECURITY_SET_PASS command, password="PasSWorD", user=user, mode=high

As a sanity check, issue the following command

# hdparm -I /dev/sdX

The command output should display “enabled”:

        Master password revision code = 65534
        not     locked
        not     frozen
        not     expired: security count
                supported: enhanced erase
        Security level high

Step 3 – Issue the ATA Secure Erase command

Warning: Triple check that the correct drive designation is used. There is no turning back once the command is confirmed. You have been warned.
# hdparm --user-master u --security-erase PasSWorD /dev/sdX

Wait until the command completes. This example output shows it took about 40 seconds for an Intel X25-M 80GB SSD.

Issuing SECURITY_ERASE command, password="PasSWorD", user=user
0.000u 0.000s 0:39.71 0.0%      0+0k 0+0io 0pf+0w

The drive is now erased. After a successful erasure the drive security should automatically be set to disabled (thus no longer requiring a password for access). Verify this by running the following command:

# hdparm -I /dev/sdX

The command output should display “not enabled”:

        Master password revision code = 65534
        not     enabled
        not     locked
        not     frozen
        not     expired: security count
                supported: enhanced erase
Posted in Tips and Tricks | Leave a comment

How to regenerate new ssh server keys

OpenSSH require different keys depending if you use SSH1 and/or SSH2 protocol. All keys are generated by ssh-keygen, that one should be available on your system with the ssh package. The receipt is almost the same as for generating your own keys, except that you should use an empty passphrase. Default key lengths are also appropriate (2048 bits for rsa and 1024 bits for dsa)

SSH1 protocol

For SSH1 protocol, you need a rsa1 key generated has follow:

ssh-keygen -q -f /etc/ssh/ssh_host_key -N '' -t rsa1

SSH2 protocol

For SSH2 protocol, you need two keys, one rsa key and one dsa key generated has follow:

ssh-keygen -f /etc/ssh/ssh_host_rsa_key -N '' -t rsa
ssh-keygen -f /etc/ssh/ssh_host_dsa_key -N '' -t dsa
Posted in Tips and Tricks | Tagged , | Leave a comment

How to Setup Webmin 1.620 using YUM repository on CentOS 6.4



This post will brief you on how to setup Webmin 1.620 using yum repository in CentOS 6.4 virtual private server (VPS). Webmin is an open source system administration and system configuration tool which provide you web-based interface to manage, administer and configure your CentOS VPS or dedicated server through web browser. It’s provide graphical interface remote administration instead of manually edit the configuration using command line from putty or console. 1. Enabling Yum repository for Webmin. Create the /etc/yum.repos.d/webmin.repo file containing :

[root@centos64 ~]# vi /etc/yum.repos.d/webmin.repo
name=Webmin Distribution Neutral

2. Fetch and install my GPG key :

[root@centos64 ~]# wget http://www.webmin.com/jcameron-key.asc
[root@centos64 ~]# rpm --import jcameron-key.asc

3. Run “yum install” command to install all required dependencies :

[root@centos64 ~]# yum install webmin -y

Example :

[root@centos64 ~]# yum install webmin -y
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * Webmin: download.webmin.com
 * base: mirrors.hostemo.com
 * extras: mirrors.hostemo.com
 * updates: mirrors.hostemo.com
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package webmin.noarch 0:1.620-1 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

 Package                Arch                   Version                 Repository              Size
 webmin                 noarch                 1.620-1                 Webmin                  21 M

Transaction Summary
Install       1 Package(s)

Total download size: 21 M
Installed size: 21 M
Downloading Packages:
webmin-1.620-1.noarch.rpm                                                    |  21 MB     04:09
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : webmin-1.620-1.noarch                                                            1/1
Operating system is CentOS Linux
Webmin install complete. You can now login to http://centos64.ehowstuff.local:10000/
as root with your root password.
  Verifying  : webmin-1.620-1.noarch                                                            1/1

  webmin.noarch 0:1.620-1


4. By default Webmin runs on port 10000, therefore port 10000 need to be open in order to allow you to access web base interface remotely.

[root@centos64 ~]# vi /etc/sysconfig/iptables

Add the following rule to existing iptables firewall :

-A INPUT -m state --state NEW -m tcp -p tcp --dport 10000 -j ACCEPT

Restart IPtables :

[root@centos64 ~]# service iptables restart

5. Access and login to Webmin using URL http://serveripaddress:10000/

Posted in Tips and Tricks | Tagged , , | Leave a comment

Preferred USR Modem v.92 Init String

This is a string I like to use.

Posted in Tips and Tricks | Tagged | Leave a comment