Friday, May 25, 2007

The kaleidoscope in my head

Someone in me thinks that the era of competition between Codeshepherd and Deepan is over. Codeshepherd is an anathema to Deepan and so is Deepan to Codeshepherd.

Thursday, May 24, 2007

Phantom memories

What do I mean by phantom memories?? Don't you ever feel, you had come across a situation sometime before in your life ? I am referring to those memories that don't really have a basis. Are these memories of us living in some other universe? Is quantum mechanics the answer the question? Did I die two minutes back in some other world ? Or did you kill me in some other world?

Music - making the religious harmony

AR Rahman, is a icon of passion, music, spirituality and many more. AR has a very interesting background which many of us don't know. He changed his name to "AR Rahman", before the movie Roja was released. He choose his own name. He converted from Hinduism to Islam. He has a vision to bring harmony between various religions in the subconscious level. His tool is the "language of nature". Vande matharam song has it lyrics taken both from Islam and Hinduism devotional songs.

A kind of Synesthesia

Answer this puzzle..

Father and son are driving along a river side road in a mountain. They meet with an accident when they cross a bridge. The father dies in the accident, and the sun is taken to the hospital. In the hospital, the doctor look at the patient and says "Oh this is my son!!". How is this possible??

If you know the answer, then you may not be suffering from Synesthesia. I am not yet sure if this can be called as a case of synesthesia. Anyway I will explain why those people who fail to answer this puzzle might be suffering from synesthesia. The answer to the puzzle is "The doctor is the mother". Given the fact that most doctors are men, the doctor profession is associated with male gender. And you end up thinking how can the father be alive?? Did he not die in the accident. Synesthesia is defined as a neurological condition in which two or more bodily senses are coupled. So here you can the sense corresponding to profession is couple with sense (??) corresponding to gender. May be I should ask Dr.Ramachandran if this is a correct instance of synesthesia.

Exploiting Unicode

Support for unicode characters lets us to use fancy alphabets. I use this link to generate all fancy character for my name and nick. For example look at the word "codeshepherd" in title, it should be like "ÇÖÐÊSHËþHÈRD". The only downside of using these fancy characters is, google index bot will not read it as "codeshepherd". So I might lose in the page ranking for the word "codeshepherd". If you are using GTK applications, you can use ctrl+shift+u+ *unicode number* to enter unicode characters.

CodeShepherd's Garbage Collector

Garbage collectors attempt to reclaim memory used by objects that will never again be accessed. So technically this blog is similar to garbage collector working on my brain. I blog just to kill my free time. Am not sure if someone would ever benefit from my blogs. What plays the role of garbage collectors in mammals ?? Proteases ?? A point to think over!!

Wednesday, May 23, 2007

Getting parallels to boot from fedora core paritition on macbook

I recently bought a macbook (2gig ram, 2ghz intel, 80gig hd). It runs both fedora and osx. I can boot to the same fedora core partition both from parallels and in the native dual boot mode. I use the rEFIt boot loaded to choose between linux and osx initially, if I choose linux then control passes from rEFIt bootloader to grub. rEFIt is a bootloader for EFI based systems like Intel macs. EFI is similar to bios on macs. I don't have a clear understanding of firmwares like EFI and BIOS. rEFIt bootloader provides a nice terminal which you can access even before you boot your machine.

The trickier part is to getting parallels to boot from the dualboot fedora root partition. I used bootcamp only to create a partition for linux initially. I tried resizing the OSX partition with parted, but ended up corrupting the OSX partition. So I had to reinstall OSX from scratch. So I advise people to use bootcamp to resize the OSX partition.

Steps involved in getting parallels to boot from dualboot fedora/ubuntu/debian/gentoo partition

1)Use bootcamp to create a new partition for linux.
2)Install rEFIt bootloader
3)Install fedora/ubuntu/gentoo/debian on the new partition
4)Make sure to install grub on SDA/HDA or whatever is the main disk. This happens by default in fedora, I am not sure about how other distros handle this
5)Now when you boot, you should find rEFIt bootloader with two primary options, one to boot OSX and another to boot Linux
6)Boot to OSX and install parallels
7)Start parallels and create a custom distro, for harddisk choose bootcamp option.
8)Edit the pvs file corresponding to the custom distro you created in parallels as follows.
In the [IDE devices] session change the line "Disk 0:0 image = Boot Camp;" to "Disk 0:0 image = Boot Camp;disk0s3"
9)Boot to the linux in parallels. You will find your grub broken. I landed in the grub prompt.
10)In the grub prompt enter as follows
configfile (hd0,0)/etc/grub.conf
11)If everything goes well you will see the grub menu
12)Boot to linux in parallels.
13)If you had already booted linux as a native OS, you will need to reconfigure your X.
14)I have fuse sshfs installed both on OSX and Fedora, So I can mount the OSX partitions in linux and linux partitions in OSX. Eventually I can access all data in my harddisk from both the operatings systems.
15)Choose shared network option in parallels so that you can mount your sshfs paritions using a fixed IP.
16)I use firefox with google browser sync plugin. So I share the same bookmarks and history on both the operating systems.

These steps should ideally work for any linux/unix flavors. It works for me with Fedora Core 6. I am waiting for the Fedora Seven release.

Unsolved Problems
1)Sometimes the keyboard does not work after you choose linux from rEFIt bootloader. So you can't change the options you have set in your grub. you will end up booting to the default one. This seems to be a bug in apple firmware (EFI ??). It has been documented in the rEFIt website.
2)Every time I boot to linux from parallels, I have to enter "configfile" option manually. This is because grub can work only for one set of configuration. I have grub working for dual boot configuration. So I have to manually enter "configfile" option everytime I boot to fedora in parallels.
3)If you choose ram option to some number other than 512mb or 1024mb, you reach kernel panic in parallels.
4)I cannot use function keys on linux when i boot from parallels. Am not sure why parallels is not capturing it. I badly want to use ctrl+alt+f1 to get the ttys. ctrl+alt is used for releasing mouse from parallels. Haven't yet figured a way to getaround this. There seems to be sendkey option in parallels. Will have to explore that.
5)The X-configuration changes when you shift from dualboot linux to parallels linux.

Social life for geeks

Most people who are passionate about technology, tend to socialize at IRC. I often visit #linux-india, #english, #math, #gaim, #electronics, #robotics. Those channels that I visit less frequently are ##c, ##java, #tomcat, #mysql, #postgres, #physics, #linux, #bash, #anything, #gcc, #g++, #web, #javascript, #non-math, #perl, #python, #fedora, #ubuntu, #joomla, #bioinformatics, #hardware, #php, #oracle, ##windows, #chemistry, #biology, #photography, #ai, #machinelearning, #crypto, #damnsmalllinux, #dojo, #dslr, #ejb, #google, #gtk+, #haskell, #hprog, #music #robotics, #smalltalk, #subclipse, #xen, #xml, #uml. I go to freenode regularly. During week ends I also go to Dalnet and QuakeNet. Schools and colleges are not needed anymore, if someone is interested in learning computers.