New Home – http://blog.nm7.org

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/H8luP

Hello World!

I’ve moved my blog to a new home. Its at http://blog.nm7.org.

Its been a while since I’ve been blogging there. But since I still get a few visitors here, I thought I should post a note here.

Hope you will visit the new site.

Solving the Rubik’s cube

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/18PKNo

I’ve finally solved the Rubik’s cube. It took me some time to get the moves right. Its not so hard once you figure it out. Of course, I had a little help from http://www.rubikssolver.com/.

Its a great way to learn the moves to solving this puzzle.

Drupal Tutorial – resource

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/5aNAJ

A really good resource for anyone who is using Drupal to build websites.

Reference: http://www.ibm.com/developerworks/ibm/osource/implement.html

HOWTO: Install Ruby 1.8.7 on Windows

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/3KvnLj

  1. Download the windows binaries for Ruby 1.8.7 here: http://www.ruby-lang.org/en/downloads/ extract that to wherever you would like, I use c:\ruby. Then put c:\ruby\bin in your PATH environment variable.
  2. Download the zlib package: http://www.zlib.net/zlib123-dll.zip and extract the zlib1.dll, rename it to zlib.dll and move it into your Windows\System32.
  3. Download the iconv package: http://sourceforge.net/project/showfiles.php?group_id=25167&package_id=51458. Find and extract the iconv.dll into your Windows\System32.
  4. Download the rubygems package and follow the instructions, basically extracting the package and running
    ruby setup.rb
  5. Verify that everything works properly by trying a
    gem install rails
  6. once that installs then do:
    rails test_project

Note: If zlib.dll and iconv.dll don’t work, copy them into c:\ruby\bin

Source: http://bit.ly/DICb

HOWTO: Proxy Firefox through SSH

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/3KzOFC

Requirements:

  1. PuTTY on local machine
  2. Remote host running OpenSSH

1. Create a new PuTTY session
Run PuTTY and create a new session in PuTTY to connect to the remote host that is running OpenSSH. Fill in the hostname, the port (usually 22), make sure SSH is checked, give it a session name and hit Save.

2. Configure a secure tunnel
Click on “Tunnels” on the left and set up dynamic fowarding for a local port (e.g. 7070). Under “Add new forwarded port” type in 7070 for the source port, leave the destination blank, and check Auto and Dynamic. Then it the Add button. If you did it correctly, you’ll see D7070 listed in the Forwarded Ports box.

That’s it for tunnels, as there is no need to create more than one. Remember to save your session profile in PuTTY so you don’t have to set up the tunnel next time.

3. Connect to the remote SSH box
Double click on the connection profile and type in your username and password when prompted.

4. Configure Firefox
Go to Tools, Options, General, and then click on Connection Settings.

Check Manual Proxy Configuration, leave most of the fields blank, but fill in 127.0.0.1 for the SOCKS v5 host with a port of 7070 (or whatever you used in Step 2).

5. Enjoy
That’s it. From now on, as long as you first log into the remote ssh host with PuTTY, your Firefox and IM traffic will be routed over a secure tunnel to the remote host and then out to the Net. Good stuff.

Note:

  • Use Pidgin with these settings for your IM needs.
  • Use Thunderbird with these settings for email.
  • If you’re using linux, skip the first three steps and run
    ssh -D 7070 username@host.com
Adapted from – Proxy Firefox through a SSH tunnel

Making Java 2 work in Debian

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/uzVHv

Download the j2se SDK from http://java.sun.com. Download the “.bin” file. In a terminal window, run the following commands.

  • Switch to root use by issuing
    $ su -
    Password:
  • cd to the directory where the file was downloaded.
    # cd ~nick/Downloads/
  • Change the permission of the file and execute it.
    # chmod +x j2sdk*.bin
    # ./j2sdk-*.bin
  • Make a directory under /usr/local (for example /usr/local/sun).
    # mkdir /usr/local/sun
  • Copy the extracted java directory to this newly created directory.
    # mv j2sdk* /usr/local/sun
  • Adjust the configurations to ensure that java works correctly. (This is because Debian/Linux uses different versions of java, that may not be reset when the Sun Java is installed.
    # update-alternatives --install /usr/bin/javac javac /usr/local/sun/j2sdk*/bin/javac 120
    # update-alternatives --install /usr/bin/java java /usr/local/sun/j2sdk*/bin/java 120

You should now have a working jdk environment, virtual machine and compiler.

You might need to change your /etc/profile adding the proper definitions of some environment variables (CLASSPATH, JAVA_COMPILER and JAVA_HOME) so that Java programs can find the kit you just have installed. Append the following lines to your /etc/profile. The following example show which settings you could add if you had installed Sun’s 1.4.2 jdk:

JAVA_COMPILER=/usr/local/sun/j2sdk1.4.2_17/lib:/usr/local/sun/j2sdk1.4.2_17/jre/libexport
export JAVA_COMPILER

JAVA_HOME=/usr/local/sun/j2sdk1.4.2_17/
export JAVA_HOME

PATH=$PATH:/usr/local/sun/j2sdk1.4.2_17/bin
export PATH

This should enable it for all users, except root. If you want to compile and run java programs as root, add the above lines to /root/.bash_profile.

Note: This has been tested only in Debian, although it should work in other distro’s too.

HOWTO: Shortcut to “Safely Remove Harware”

I’ve moved to a new home. See this post at “An Individual Approach” – http://bit.ly/ebjBx

Press Windows Key + R (To open the run dialog).

Type in the following:

C:\Users\Nick Mathew\AppData\Roaming\Microsoft\Internet Explorer\Quick Launch

Now create a shortcut (right-click on an empty space in the folder and select New-> shortcut). Add the following line.

RunDll32.exe shell32.dll,Control_RunDLL hotplug.dll

This creates a quick launch to the “Safely Remove Hardware” dialog. Now you can reduce the number of clicks to remove a USB drive.

Source : Create a Shortcut or Hotkey for the Safely Remove Hardware Dialog