Pages

Friday, July 22, 2011

Read, so that you don't end up loosing data, the first time you install linux.

Have you already lost your data while installing Linux for the first time? Never mind, you are not the first one :) . Almost everybody, mostly Indians who have a tendency of trying out before reading manuals end up loosing all their data when they install Linux for the first time (I did too :P). It so happened that a friend who had taken some free advice from me on which distro he should choose, for beginning with Linux fooBaar'd his system. And I am writing this post so that I can point people to read it before they embark on the "dangerous" yet exciting path.
There are quite a few things one has too keep in mind beforehand. Primarily, one has to have a firm belief in the fact that, nothing that one does, while installing Linux, may cause serious injuries to the hardware. Also, Linux is not responsible for the loss of your data, if you select the partition containing data, for formatting / change of Filesystem - so the user has to be alert. And one more thing to be noted is, no one can become an expert in the art of installing Linux, without getting the hands dirty. So if you were thinking of reading a lot of text before setting your sails, trust me, you may as well wait for ever. However, it will be good if you at least follow the links shared in this post and skim through to get an idea.
Okay so that was a long moral lecture, now lets get down to business. First of all you need to select which distro you are going to get started with. And selecting can be a real task if you get to know how many of them are there. You can get more information about distros on Distrowatch. As for a beginner, the community generally recommends
  • Ubuntu  - I won't recommend because of experimental change in interface.
  • Kubuntu (Ubuntu with KDE) - more info
  • Linux Mint - more info
Take a look at article on Desktop Linux on Wikipedia for more information on GNOME and KDE.
Another thing a newcomer needs to etch on his brain is, it doesn't matter which distro / desktop environment he uses because, ultimately, all of it boils down to a personal preference. And there will be a lot of time in life for flame wars on topics like "my distro is cool and yours is crappy".
So once a distro is chosen, you need to get it's installer on a bootable medium. The installer is generally an iso file which needs to be burnt to a CD / DVD via some generic disk writing software or written to a usb drive using UNetBootIn. One can also get it along side various Tech - magazines like Linux For U or Digit. I don't think someone reading this would be n00b enough to be unable to search the Internet, visit the site of the distro, locate the ISO and download it.

Now, that a bootable installer is there, one can easily boot from it. If restarting the computer while the installation medium (i.e CD / DVD is plugged in) does not work take a look at this link. After booting, things will be as simple as custard, except for disk partitioning. For somebody who has no experience with
Next and the most important task is to create partitions in which the installation will take place. For detailed info on the directory structure and filesystem of Linux and preparing yourself to quit the clumsy comfort of C: and D: drives do go through the content on Aasis Vinayak's blog. I intend to clearly and crisply introduce the simplest and safest partitioning scheme for a dual boot system with a Windows installation.
One (or two in case of Win 7) primary partition for Windows.
An extended partition containing:
 An NTFS formatted partition to be used as your D drive. (data should never be on the same partition as operating system - in case the OS needs to be re installed  - data would be safe.)
 An ext journaling filesystem for / (root) on linux. (essential)
 An ext partition for /home (read Aasis Vinayak's blog for explanation)
 A swap partition (essential - size should be double the RAM).
The process of creating partitions may differ from one installer to another but since everything is in GUI, it is extremely intuitive and self explanatory so nobody can misunderstand.
The rest all too obvious to be taken into consideration. In future if a newbie develops distro hopping tendencies wishes to setup a multi-boot environment a previous post of mine might come to the rescue.

While I was searching the Internet for appropriate links to include in this post, I came across these, which intrigued me :
http://www.vias.org/linux-knowhow/wrapnt414D24_newbie_guide.html
http://www.tldp.org/LDP/intro-linux/html/index.html
Linux portal on wikipedia :-
https://secure.wikimedia.org/wikipedia/en/wiki/Portal:Linux

All the best for your venture.

Thursday, July 21, 2011

Interning at AmiWorks

The curriculum for B.Tech (CSE) in my college, like many others, requires me to pursue industrial training in my third year. Just as my batchmates, I too was anxious to secure a place for myself in an organisation related to my field of work and my area of interest. Meanwhile, I volunteered to take a session on Introduction to Qt at  OSS Camp 11.03 Lucknow and there, I met Amit Singh who offered me a place as a Summer Intern in his company, Amiworks, Pune. The offer was appealing and I accepted it.
After my exams I reached Pune and joined AmiWorks on my birthday. It took me a week to settle on a project, but once that was set, there was no looking back. I tried and developed a File Sharing and Syncing Application using PyQt. While Qt was something I was familiar with, I chose python because firstly, I wanted to learn it and second, my room-mate cum Co-founder of AmiWorks, Aman Jain  motivated me enough to embark on an unknown path. I won't bore you with the details of the project, as that is to be submitted to the college in a report which is hardly read by anyone. What I intend to share is the exhilarating experience I had while interning at AmiWorks.


First of all, my residence and office were in the same three storey building. All I had to do was climb a flight of stairs to get to my office, so I was spared the travelling woes and I was able to sleep an hour extra everyday ;) . The office itself was cool, big windows, balconies, greenery all around and pleasant weather of Pune. The working environment was even more awesome - a comfortable chair, bean bags, dual monitor setup, 16Mbps Internet etc made it feel like heaven for a programmer. 
Ah !! it wasn't all work and no play. We used to have musical afternoons where Advait's talent covered everybody else's musical n00bh00d. And I also watched quite a mouthful of movies in the two month span with my room mates cum colleagues, both in theatre and on Youtube ( the 16Mbps belonged to just four of us after office ;) ).
I miss - the saturday nights - anna ki idli - evenings at crossword - dinner at vaishali - ghar jaisa khana at Delhi Kitchen - morning walks and movies with colleagues / room-mates - exclamations of Vivek - questions of Ankur - Neha's comments - Aman's advice -  Amit's support -  programming sprints - daily stand-up meets - and the list goes on !!!


In short "I am missing my internship days" and I can't wait for PyCon 11 which is being hosted at Symbiosis Pune, which is when I will be meeting friends cum colleagues again !!

Thursday, June 30, 2011

Running a program on the system accessed via ssh

Controlling anything remotely is always kinda exciting and fun. And when it comes to computers its even more exhilarating. So when I became aware of ssh I was excited. Tried poking fun at people in computer lab by logging into their system and closing their programs and rebooted their computer. For a command line freak like me its even more fun to be able to actually control another computer from terminal.
But if you have tried running a program which requires a GUI you would have found that it gives an error stating
Error: No Display found.

I always wondered how that could be achieved but never knew really tried to find out. Today, however I decided to find out and blimey!!  a simple internet search revealed the answer. Prefix the program with this DISPLAY=:0. So if you want to run the terminal program on a gnome system run
$ DISPLAY=:0 gnome-terminal

And BINGO !!!

Saturday, June 18, 2011

Compiz Fusion screws up in Ubuntu 11.04

A new recruit, at AmiWorks, got Dell Vostro with Ubuntu 11.04 to work on. Being new to Linux he was enjoying the experience but a little while later when he had played all the pre-installed games the excitement of a new OS started diminishing. And he was now in the state of comparing Linux with Windows. He approached me asking for something exciting to do with his Linux box and I obliged.
The most fascinating thing that boggles a new Linux user is the rotating cube virtual desktop arrangement. I exclaimed "Okay, I will show you something, that will make you forget Windows forever". And installed Compiz Config Settings Manager. Since I have not tried Ubuntu, I didn't know that Unity didn't support Compiz. So it broke and left me in a fix.
Now the guy had the opportunity of mocking my statement "Something that will make me forget Windows forever .. aha". Having no previous experience with Natty I could restore the system to the way it was, only with a little help from #ubuntu IRC.
Firstly chose restore to defaults on ccsm (compiz config settings manager) and then fired
$ unity --reset 

on the terminal. This fixed the situation on that computer and should be helpful for anybody else who screws up in a similar manner.

Moral: Don't boast off about ccsm until you have yourself tried it on the new configuration.

Monday, May 23, 2011

You can't beat the shit out!!

A friend with managerial background once complained that he can't withstand people making weird noise with their burps right after dinner. And that he feels like beating the shit out of them. To this my immediate and involuntary response was that "Technically speaking, you can't beat the shit out of the person who had just had food. You would more likely be immediately successful in beating the vomit out of him. :P Upon my remark he tried to justify by stating the implied meaning of his previous statement.
The third guy, a layman (in  other words a genius), in our company got seriously agitated with the nature of this discourse, and screamed "Shut it, you geeks!!". And laughter took over !!!

Sunday, May 8, 2011

Criticise or Change?

I am sure that I won't find even one single person who has never ever criticised The System he / she is a part of. We, being humans, have a tendency to detest the present, miss the past and long for the future. So do the students. When we were in the school nothing was worse than the teachers and the school administration. When in college, the college administration takes that place and memories of the school life are cherished and we can't wait for getting a job. Then those who are working find it extremely unbearable to be there, miss the student life and long for retirement.
We ask for change in The System (Even I do). Forget being the change for a while. The thing we need to ask ourselves is are we mature enough to enjoy the change. Wouldn't we again criticise the changed environment just like a toddler who discards a toy after playing with it for a while?
Actually it isn't The System that needs change. Its our attitude. 'WE' here, means everybody who is a part of 'the system', any system, government, education etc, will have to change they way we think about The System. Because its us, everyone of us, who makes The System what it is. For instance, both teachers and students will have to have the attitude of learning something new everyday, have faith on each other and strive for excellence. The people, and the people in power will have to collaborate to resolve the issue instead of "being the issues" and playing the blame game. Once we grow up, stop criticising and demeaning others, stop wasting time on gossiping like the envious women, and strive for excellence, the day won't be far when we will be satisfied with The System and be an example for the rest of the world.

Sunday, May 1, 2011

MBA after Engineering.

Recently I met a would be engineer who aspired to prepare for CAT and go for MBA right after achieving his B.Tech. This brought back all the reasons I have heard from people choosing MBA after engineering.

So why do people go for MBA after engineering?
Statuary Warning: These are my thoughts and no offence is intended to anyone, if you feel offended you are more than welcome not to read any further.
  • Learning Managerial Skills
If it is only about learning, why not learn it the only way skills can be acquired i.e by getting hands dirty and practically doing stuff. If one can't learn to swim by only reading books and one can't learn to write programs by mugging them up for exams, I am pretty sure that it is equally impossible to learn the MBA stuff only reading books. And all the colleges will get you to do is, read, mug up, vomit and so on...

  • Position - being a manger and governing fellow engineers
In a system where actual learning happens only on ones own and a degree can't certify one to be a better engineer or manager against another, why do companies rely on them and promote MBAs only? Not sure if this happens everywhere, but if it doesn't then why are the engineers crazy for MBA?
  • Engineering was a wrong choice.
So you want to say that you were counselled and compelled by your parents because offsprings of their acquaintances were going for engineering and it was never your aim. And that this time your decision is based upon the counselling of your friends, seniors, acquaintances, you are not going in the wrong direction. 
Or perhaps it was one of your "To Err is human" thingy. How can you be so sure that you won't curse MBA just like you did engineering, afterwards?

  • I don't know Engineering - they taught nothing at college.
Again how do you know the college would teach you something? And it won't be the same mug up and vomit cycle for 4 end-sem exams?
  • Money - earning more 
Haven't you already spent a fortune in terms of time and money already in order to obtain a B.Tech? Can you afford to waste another such fortune?

  • Everything that can be achieved with more money
Hmm.. if materialistic stuff is all you desire and knowledge has no value in your eyes, you should better choose the easy way of making money, there are many successful icons even in that dimension whom you could follow to become the next billionaire overnight.
  • I have had enough ... I can't study technology any more?
Yes, right, you have had enough of technology haven't you? So why not go back in the stone age and promise that you won't buy the next killer phone from Apple.

Besides, we all loved 3 Idiots, all engineers embraced it as a mirror of the plights and delights of their very own lives. So how did we end up ignoring one of the many morals ()? People who go for MBA after B.Tech and work as a manager are no better than Donkeys (Rancho [aka Phunsukh Wangdu], enacted by Aamir Khan, 3 Idiots).

Edit: The only case in which such a move is justified is when the person takes full responsibility of his / her own actions and resolves never to blames others.

Friday, April 29, 2011

All Hail Corruption !!

We are living in a age when this word corruption has become so common that we don't even dare to imagine about a world without it. It has sunk its roots deep inside our whole infrastructure and system. Domains as diverse as education to defence are all immersed in the black sea of corruption. Not even one day passes when there is no news of corruption on the everyday-mushrooming news channels who them selves form an integral part of corrupt media. So what is corruption, how does it begin, what are the steps being taken by the corrupt authorities to stop it, how can we actually get out of this marshland?

So what is corruption? You see being a student of corruption I don't feel any reluctance in copying the definition (and much more coming later on) of corruption from the wikipedia article devoted to the topic. So this is what it goes like “The word corrupt (Middle English, from Latin corruptus, past participle of corrumpere, to destroy : com-, intensive pref. and rumpere, to break) when used as an adjective literally means "utterly broken"”. So what if its a middle east word? Its prevalent in every part of the world. The scenario is such that if somebody claims to be 100% honest and far from corruption, the chances are that he / she is either a lying lawyer, politician giving a press statement or a common man in search of an opportunity. Now, I see you sighing “Not me” under your breath, but come on!, you don't have to admit it to the world. But the ground reality is that you too have it in your blood to be corrupt ... just think about it while introspection and you will realise the percentage of truth in my claim.

It starts at a very tender age, right when your parents bribe you by promising something materialistic in lieu of your good marks ( yeah I know its stolen from 3 Idiots, so what? We all are corrupt – why should I be honest and pour my original ideas?) . Every new recruit has a clear conscience but the prevalent corruption and the healthy environment created by it just makes it easy for the system to modulate him / her and head in a direction without destination. Be it the most popular and most advertised corrupt department of police or the crucial education firms, we have people who wish to be paid more than they work and also dream of becoming a billionaire overnight. So why wouldn't corruption prevail?

Everybody who blames the corrupt authorities for not eradicating it, is also corrupt, because knowing that the authorities are corrupt they still expect them to take actions against it. And aren't we happy about the presence of corruption? Ah come'on is this what we actually understand from corruption? Nah, its something that sincerely comes to our rescue in difficult times. Really, the corrupt media has defaced, demeaned and demonized corruption. In the real sense we are all happy when one of our friends at post-office gets our job done from behind the window and we are spared the wait and trouble of standing in the queue. Also don't you enjoy when you get some of our task gets easily done just by paying up? And isn't it convenient when a friend of yours does not have to spend a night in the police lock-up coz he as high-level connections or has a little-more-than-sufficient money to stuff the authority's mouth with?
So who is promoting corruption and who is letting it prevail ? Yes its us. You me and everybody who sits silently, cosy on their couch, sipping coffee, reading newspaper, and blaming everybody else for the miseries caused by corruption. ( again, I know its copied from Nayak, the movie – stop pointing at me – what did you expect me to be? Honest in an article on corruption?) .If you think that a single anti-corruption bill passed by the efforts of Anna Hazare will uproot corruption which has been there for years, either you don't want it to be gone or you are over optimistic.
Only if every single Indian becomes sincere in their duties, eg student in studies, bureaucrats in governance and housewives in home management with the limited income etc, every single problem existing in the present times will evaporate without precipitate.

Monday, April 25, 2011

Dog on the 9th Floor of Hostel

The administration of my hostel is very strict. According to rules, no one except the hosteller students (not even hostellers from a different hostel) and staff can enter the hostel. Now I am sure that the administration must be having a very sound and solid reason behind creating them, but that can't stop me from pointing, smirking and blogging when dogs and rats roam freely in the hostel apart from us, monkeys.




Saturday, April 23, 2011

Yet another picture of a bug !!

Yet another picture of an insect ... found it on the floor and as usual couldn't resist clicking a few pictures of it.