Thursday, July 23, 2009

symbolic link(linux) Virus Incident

hello friends,
today I would like to discuss a very simple topic related to linux and how it bothered me.recently I was working with linux trying to learn "symbolic links".Symbolic link is a special file which points to another file in the is similar to shortcut in windows.

if you give the command ls -l in your terminal then you can view link files.if output starts with l then it's symbolic,to create a symbolic link we have to use "ln" command with -s option."ln" is for link and "-s" is for symbolic option.syntex is like this ln -s source destination.

now, source means the path of file or directory where it originally is. and destination means the path where you want the link to have to specify the name of link and this should not exist in system otherwise it will give error.

But I did something which I forgot later.I made a symbolic link by typing this ln -s /home/gaurav /home/gaurav/h. since every file of linux was in "gaurav" folder ,when i went in "h" folder inside "gaurav",i found all the files again in this folder including "h".when i again double-clicked "h" it took me to same folder which contained all files including "h".I didn't remember about symbolic links and instantly I was worried that there is some virus in my system.I had heard earlier that there is a virus which creates a folder in each folder including itself.

after some days when I opened shell and typed ls -l, I found "h" showing l which means it's a link only.then i was relieved and deleted this. then I typed ln -s /home/gaurav/videos/jal.mp4 /home/gaurav/Desktop/jal. by this I am able to view this video directly through desktop. I need not go anywhere.and this is done without copying the video or without "cut and paste" from its original destination.

this was a new thing for, I thought it would be good to share this.May be someone new like me would get help from this.But , if you are master of shell, you may laugh at me.

thanks everybody to read this post.

Tuesday, July 21, 2009


Hello everybody

Today I am trying to do something since morning but couldn't find anything interesting enough.This is the effect of 2&1/2 months holiday.this is the last week before college is going to open for 3rd semester.finally holiday will finish.Again, college routine will start.
Well,in this holiday I read a novel "the shadow lines" by Amitav ghosh.this is about India and Bangladesh division.Very sentimental. I am currently reading "the goal"."The Goal" is truely awesome.I have not finished it yet but till now it's very interesting.hope to finish it before holiday ends as I have to return it to its owner.

hope this week will pass very soon as I feel like college is calling me .well, this post is all about my holiday. Currently i am doing some experiment with linux shell script. Hope next post will be technical.

Wednesday, July 15, 2009

CLI over GUI

hello folks,
I am learning a bit linux, I thought it would be better to write something related to that.Don't worry , i will not teach you commands here(there are so many sources for that). I was thinking that CLI(command line interface) seems to be boring and cumbersome to use and I know so many people would say the same.Most of us are used to of windows' GUI(graphical user interface).Around 5 months ago my friend bought a laptop and got windows vista as default OS by that company.When i asked him to use linux,he said that as he had been using windows since childhood,he was more comfortable with that.Now i think that how can you compare two things without knowing both. If you also admire GUI then this is for you.CLI has really got some advantages over GUI.lets get it one by one
  • with a GUI, only the options provided by the interface are available to the user

  • lack of space on a screen can limit the number of options that a GUI displays

  • no standard methods exist within GUIs for performing standard command-line tasks, such as linking commands in sequences, redirecting output from one destination to another, or collecting commands into scripts

Shell keeps history of recent commands.its very useful.and, if you have to perform certain operations in sequence then you can create shell scripts script is just like batch files in windows.

there is one more thing that i have recently come to is more useful in hardware terms.Shells are much less resources-intensive than GUI' requires less memory.It means that command issued in shell will run more quickly than in GUI.

Only thing that i feel difficult is to remember commands.well,once you get used to it,its much easier than you think.
That's it for today.hope,you got something useful.

Tuesday, July 14, 2009

restoring grub menu

hi people,
finally pushed myself to write one about a technical issue. recently ,I reinstalled windows vista successfully but after restart i didn't see any grub menu to boot linux(ubuntu).At that instant, i was shocked as i thought linux was gone.Since vista had overwtitten the mbr so it used to boot vista directly.I tried to restore grub menu through a live cd of linux which is done through typing some commands in terminal.Basically, anybody can copy those commands from . But those commands were useless for my system as the "stage1" file was washed away from grub folder.finally,i downloaded an iso image of "super grub disk" and made a cd. then i booted through that cd and everything started working fine.when i saw grub menu again, i was so happy.