Saturday, January 29, 2011

Fastest and Cheapest Internet in world

Hi all,

Most of us wonder which parts of the world have fastest and cheapest internet connection across the world. In India we have the cheapest call rates (even lesser than those offered by Skype etc), but bandwidth is costly and comes with usage cap or fair usage policy. The TRAI guidelines of increasing the minimum speed for broadband definition is yet to be heard. Any ways there are many reports out there which compare the internet speeds.

www.itif.org/files/BroadbandRankings.pdf

Looked here and found that cheapest net access is in HONG KONG (just Rs 1170 for 1Gbps connection ). Guess what i am most jealous person on the planet. Its much cheaper and much faster than one could imagine.

Hail Hong Kong for technological advancements. Hope we have similar standards in coming years. (BSNL has already released FTTH, but its way to costly).

Thanx for reading:)

Always have your stuff when you need it with @Dropbox. Sign up for free! http://db.tt/V9f0DFoI

Custom Domain name problems (www subdomain)

Hi all,


This post describes the problem i faced in setting up a new domain name and solutions to those.
I purchased gunjanbansal.in from http://mitsu.in/  for just Rs 79 ($1.73) for the first year, and Rs 550 from second year onwards (Offer on .in, .co.in and some other root domains only). This is much cheaper than what most of the other registrars offer. Believe me they do offer at this cheap price. Currently their promotional renewal scheme is on in which we can renew up-to 9 years max at about Rs 349-399. Guess what owing a domain name is much cheaper than i though, specially looking at all those sellers listing the price at $10 onwards. I think its much cheaper to buy a domain name from mitsu.

I faced a lot of problems initially as I was unaware of the setups required. Also my email (gunjan@gunjanbansal.in) is not yet working. I think i better take problems and solutions one by one.

I have used my domain for google sites, and blogger.

These are the current parameters :- cv.gunjanbansal.in and www.cv.gunjanbansal.in redirect to my resume at google sites.

blog.gunjanbansal.in and gunjanbansal.in redirect to this blog.

code.gunjanbansal.in redirect to my programming blog which is yet to be worked upon.


The domain names www.gunjanbansal.in and www.blog.gunjanbansal.in unfortunalty dont redirect to any of these :(. Hey wait are you saying that www and without www domain names are different ??

Yes I am. Actually www is considered as the sub domain. By this i mean www.gunjanbansal.in and gunjanbansal.in are two different entities for the DNS servers.  I wish they were same. Most of the time we don't care to add www, but see that its auto added, so hows that ?? That is actually done using 301 or 302 redirection. The naked domain (just the top level domain and second level domain (may be third in case of .co.in etc)) i.e. "example.com" is redirected to "www.example.com" or vice-versa. www.example.com is treated as sub domain of example.com.

This redirection can be done in many ways, but the 301 redirection is best way to do so. 301 means permanently moved to other location. This is better done in .htaccess file on Apache.
See http://en.wikipedia.org/wiki/URL_redirection for more details, or better search it on the web.



Now for the URL redirection one needs a web host (most domain name registrars don't give it for free), on which one can add the redirection scripts. Unfortunately the free ones didn't impress me, and i am in no mood to buy web-space at the moment. May be I'll do in future who knows. If you have web-space, making a name server entry for hosting provider and adding all the redirection of sub-domains there (on web host) is better solution. (I'll tell in few mins what entries to be made, although they are available on net).

  • Decide what you want before u start setting up your new domain, the DNS servers take a lot of time to update (upto 48 hours) and you may not be able to check if your settings are correct in a blink of eye, this is not a programming assign my friend. You can off course try different proxy sites like hidemyass.com or anonymouse.org . There DNS servers update a bit faster and you may be able to see results pretty soon. Also try pingywebedition.somee.com which might help in faster propagation of dns changes. 
  •  There are various kinds of dns records. The records that will be of interest for first timers are :-  CNAME , A records , MX records, TXT records, Name servers. I'll first tell setup required at domain name provider.
  1. TXT records give general info about the domain/subdomain and are generally used to verify owner ship of the domain. You wont require these until unless you are enabling email system, or making use of google webmaster tools etc. 
  2. MX records :- These are used to specify mail servers. Hence would be use only when setting up email systems.
  3. CNAME record:- This is the record that is most useful. Be careful while setting this up. As wikipedia explains, these records are used for finding IP address of a domain or subdomain from a different domain/subdomain. Meaning

    If i have a CNAME record as follows :- gunjanbansal.in IN 3600 example.com, it means for the IP address of gunjanbansal.in look at example.com . It doesn't mean that this is URL redirection, neither example.com need to be a name server (The A/AAAA record for example.com will be used then). Your visitor will see gunjanbansal.in as the URL and so would example.com. A CNAME record to other CNAME record must be avoided and be used if utmost necessary (This is to avoid loops in CNAME records).  If using Google sites or Blogger, the cname record for your subdomain will be ghs.google.com . For the naked domain, its better to have a A record (There can be multiple such records so don't worry, they are explained below).  This is because a CNAME and MX record with the same name are discouraged and are not allowed by most of the domain name providers (I am not sure if they are not allowed at all). This means you wont be able to host email if u add cname record for the naked domain (off-course u can host email at a subdomain).

    Here the www.example.com CNAME entry with value example.com and example.com cname vlaue as ghs.google.com won't work as suggested here. This is because ghs.google.com would see it as a request for www.example.com rather than example.com and wont have any entry for that, returning 404 error. (Supposing only example.com is setup in blogger or google sites).

    I was stuck with all these until I realized whats going on behind the scenes. I had to spend few hours trying to figure this out.
  4. A record :- If using google sites or blogger, and not getting a webspace, you would need to redirect users visiting to your naked domain somewhere. Won't you. Just add A records for your naked domain as specified here.  Remember this is only for naked domain.
    In the coming years all of us would be running behind AAAA records :D Thanx to upcoming exhaustion of IPv4 address. These records are actual location of your domain (IP address)
  • Now in the blogger, under settings tab there is option for publishing. Choose advanced in these and provide your custom domain name. Or you can buy one if you want. I couldn't find a cheap hosting provider for .com address. There is option for redirecting the naked domain to your blog, you can tick it if you want. I faced a peculiar problem here, i think its mainly due to poor interface.  I now have 2 blogs, code.gunjanbansal.in and blog.gunjanbansal.in , What i saw was that the redirection option was either ticked or unticked in both. I couldn't leave it ticked in one and unticked in other. Actually what we see are not current settings but what blogger expect us to do, whenever you save configuration in one of your blogs, it will be there, but u might see some other configuration (presumably what blogger feels you wish to do). Don't worry about this. Just save one blog with redirection enabled and others with don't, and you ll be done. Forget about it after-wards.
  • Now in the google sites, there is something called web address. Here you can add custom webaddress were you wish your site must be hosted.
    Here also there is a problem. My website is hosted at 3 different locations (without 301/302 redirection) and search engines sees them as different :(. This problem can only be solved if u have some webspace. Until then you have to cope up with it.
  • If you own the webspace, you can add NS (name server) records for your domain (might be better if hosting very light stuff) or subdomain to your hosting providers name servers. Rest of the settings can be done at the hosting provider.
    For all this I would like to thank Satyadeep for his help in setting up the stuff when i was lost. Any suggestions are welcome. I'll update it as soon as possible.

    Friday, January 28, 2011

    New Blog

    Hi all ,


    Somehow i am getting addicted to blogging. I just started a new blog http://code.gunjanbansal.in . In the new blog i l try to solve algorithms related problems (I am not one of the best out there, just trying to be one, please bear with me if I am wrong) and provide tips to people. I wont be giving out complete code, but only snippets. I don't know if the new endeavour will be success full or not. I am just wishing for the same.
    Happy Blogging.

    Sunday, January 23, 2011

    Finally I own a domain name !!

    Hi all,

    Finally i am proud owner of domain name gunjanbansal.in . This blog will be reachable by

    blog.gunjanbansal.in

    gunjanbansal.in and gunjan-bansal.blogspot.com will redirect to above link using 301 (Permanently moved) redirection.

    Blogger don't allow simple multiple Urls to come to blogger, so i will have to go for some hosting provider to host .htaccess or php file redirecting www.gunjanbansal.in and www.blog.gunjanbansal.in to this blog. I am leaving that for now. May be I'll look forward to it, if i ever need a professional hosting for some other use.

    cv.gunjanbansal.in and www.cv.gunjanbansal.in point to my resume. I know it must have been a 301 redirection but that's not possible for now. They are indexed as different web pages by search engines.
     :(

    Any ways it feels good to have my own domain :) Hope you also buy one :P

    Avast AntiVirus Reviews

    Hi all ,

    Just another post by me today .. I think i am writing too much .. :D

    I have been a registered user of avast antivirus for past 4 years or so. I have been extremely satisfied with the results and recommend every other guy i meet. My reviews might look like biased too few :(

    Pros:-

    • Free :- Avast home edition is free. Only a free registration is required. Which now can be done form the avast interface itself (in Avast 5). Although there is no proxy support in the registration process.Other AV solutions cost a fortune :( at least in a country like India were piracy is rampant, Avast provides a way to keep it to a minimum level  :)
    • Light Weight :- Its one of the lightest application on my computer. Believe me its much lighter than Norton, which i received twice as a bloatware with my new laptops. Norton just kills my machines. It sucks !! Both time i uninstalled it on day 0. :D  Avast does not cause a slow down to system performance, and in the mean time keep scanning the file system in the background. You never have to manually scan the HDD.
    • Fast :- The new interface is multi threaded, and is suitable on today's multiprocessor systems. I have tried it on Pentium 4, Core 2 Duo, Core i5 460, Core i5 760, And the performance increase with multi processor is clearly visible.
    • Detection Rate:- I must say, being Computer Science student (also from past) i experiment with computers a lot (May be that's why i lost my 1st laptop :(), I have never ever been infected with a virus :) . This is a tough claim, but i fortunately its true. Now i have shifted My testing to virtual machines, so i no more have to care for virus infections etc.
    Cons :-
    • No proxy support for automatic updates :- Although the automatic updates work well on the direct connection, it  has given me some issues behind proxy. I can update Avast manually (both 4 and 5) but some how its never auto updated when behind proxy.( With authentication at least). Proxy support is missing in most of the software's, i don't know why they think that it will only work on a direct connection network.
    I cant think of any other Con write now, please leave your comments. I feel that Avast is most reliable and best antivirus. Although this may differ on what experts have to say with detection rate etc... I don't have infrastructure to do that kind of testing. For free users,who cant afford a antivirus and don't want to take the path of piracy, i will recommend avast. Its better than most of the paid solution.  (Atleast Norton and AVG)

    Saturday, January 22, 2011

    g++: unrecognized option -R

    I was stuck with the unrecognized option -R error in makefile of COOL language. I myself have never used it though.

    I found the solution on a maililng list

    http://gcc.gnu.org/ml/gcc-help/2001-05/msg00086.html





    The author suggests using -Wl or -rpath instead of -R . Refer to the above mailing list for more info.

    "
    This option is not portable.  It's actually a linker option, that GCC
    accepts on a few targets for compatibility with the native compilers
    of those platforms.  In general, you should use -Wl,-R to pass the
    flag directly to the linker, if the linker supports it.  Sometimes
    you'll find the spelling of the flag.  The GNU linker accepts both
    -rpath and -R.
    
    Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
    Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
    CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
    Free Software Evangelist    *Please* write to mailing lists, not to me
    
    "

    How to use older version of gcc

    Hi all,

    This post is for my friends who want to use an older version of gcc/g++ compiler but don't know how (Assuming they are on latest Ubuntu where in the default g++ package installs 4.4 or above). In synaptic versions of gcc ranging from 4.1 are available (at-least they do on Ubuntu 9.10).
    When i first googled/binged the question, it was difficult for me to get an answer. No were its mentioned on how to use older version. But just by luck i tired "g++-4.1" and it worked like charm :)

    For using an older version (Off-course after installation) supply the version number along with g++ command, eg for version 4.3 use "g++-4.3" no space in between. It will compile the code.


    Why we need older versions ??

    Its mainly because sites like http://www.codechef.com/ etc support gcc 4.3 but not above (The last time i saw), there is considerable difference between various versions of gcc () , which most of the time must not matter to a user. But sometimes when compiling a old code (I was stuck with COOL language in my compilers assignment), one need an older version.

    The changes incorporated in various versions are available at http://gcc.gnu.org/ in the form of change logs.


    By default g++ will map to the highest version of g++ installed (by selecting g++ or g++ multilib in synaptic). I think there must be a way to change this mapping . Any one know about it ??

    Ethernet (Wired LAN) vs Wi-Fi in Campus

    Hi all,
    When i first joined IIT Guwahati, I wanted a WiFi connection in hostel rooms as well in labs instead of the regular Ethernet. My friends in the outside had WiFi in their campus, and could move and still surf the net. With Ethernet its quite limited. But after 3 years in the Institute I realise that Ethernet is much better than WiFi (Even more costly to set up over a large region). A comparison is given below.

    Pros of Ethernet over WiFi:
    • Speed  :- WiFi has a maximum speed of 54Mbps for 802.11b/g , in 802.11 its much higher (Up to 150 Mbps ) (See http://en.wikipedia.org/wiki/IEEE_802.11). Were as in Ethernet its 10Mbps,100Mbps and 1Gbps. In most of the campuses 802.11b/g is employed and 10/100/1000Mbps Ethernet is employed. WiFi is more prone to errors (collisions) and suffer from much of packet loss especially if the access points are not connected using a wired backbone (May be Optic/Ethernet etc).  Were as Ethernet is more reliable and give better service. Lan Games, Dc++ Works superb on Ethernet. On WiFi it sucked, at least for me. WiFi is more prone to interference. As the distance from access point increases speeds falls considerably. In Ethernet speeds do fall (Distance from nearest switch) but is at much more slower rate than in Wifi.
    • Performance/Reliability :- Ethernet is much more reliable than WiFi. The theoretical maximum speed (at-least 100Mbps , 1Gbps is difficult to achieve because of long cable lengths, more number of users per cable etc). WiFi this performance is hardly achieved. Connection drops are more frequent  in WiFi.
    Cons of Ethernet over WiFi:-

    • Cost :-  Laying down long cables is much more costly than purchasing some access points. WiFi is much cheaper to establish than Ethernet in large area. 
    • Mobility :- WiFi provides a great mobility. Ethernet has a limited mobility.

    I feel that WiFi is more suited for areas like Coffe Shops/Homes/Restaurants rather than educational institutions were most of the people do their work sitting at a single place. and mobility is not much of importance, but the performance and speed is. Hope my friends who used to tease me reliase this and feel jealous.  :P :D

      Wednesday, January 12, 2011

      Skype Offline installer

      Get the skype complete installer at


      http://download.skype.com/SkypeSetupFull.exe


      We all know how much it sucks to use third party down-loaders, when we don't want it !!!

      Saturday, January 8, 2011

      Google Chrome Standalone installer

      Google stand alone installer (complete) without the ugly download and install on demand application is available at

      http://dl.google.com/chrome/install/154.36/chrome_installer.exe

      How Dell captured Indian laptop market

      Dell, the word is familiar with almost most of us, I myself feel their are varied reasons why they were able to capture Indian market (I don't have a Dell though :D), they are enumerated as follows :-

      1) Cheap Laptops, although most of the laptops are inheritor flawed and under perform when compared to their configurations (As far as i have seen, most of my friends have dell), they are much cheaper than their counterparts. This is not a capturing feature in higher end laptops were people tend to go towards Lenovo/Hp/Apple etc.

      2) Good after sale support :- I must agree that their after sales support is awesome, with atleast one service center in a major city, they give a quality support. But they mostly end up replacing a major part (motherboard/keyboard etc) in every service (They do become unusable pretty soon).
      But anyway the word of mouth and previous image of Accidental protection (which  now needs to be purchased separately) continues and bring in new customers.

      3) Good and Upto Date Website :- Dell has a awesome website which is up to date most of the time. I have seen Lenovo/HP/Sony website but don't feel the same with them. The models are either too new or old  (removed from market/not available even in showrooms). Hp leads the way in being the most outdated website, with price tags missing for most of the products if not all.

      4) Customizable Laptops :- Too much extent laptops from dell can be configured, either online or at showrooms, this is missing in Lenovo/Hp/Sony. This is the feature that most students go for, and most experts need. I don't know why its not available in India when it is  there in USA etc.

      5) Range of laptops:- Dell laptops suite most of the needs of people, when including the 4th point, its becomes more than sufficient. Their range of choices is much larger than their counterparts.


      I think if Hp/Lenovo/Sony improve on last 3 points at-least, their market share will zoom a lot :)

      Wednesday, January 5, 2011

      Why Lenovo failed / will fail in India

      Hi,

      This is more of personal blog post rather than technical one. when i purchased my Lenovo Ideapad Y series laptop spending about 52K Rs, i was king of the world, it had a awesome sound and great graphics capability. Performance was also awesome. But as the destiny does, it screen became loose from hinges within 3 months, i had to under go a lengthy repair process spending 8K Rs, to get it set. I dont know why it shoudnt be covered in warranty. And secondly their after sales service is so poor that one should think twice before going for lenovo.  Dont just trust the IBM behind it, Lenovo really sucks in India. Then after a week or so i forgot my BIOS password (my mistake, i know it must not be covered under warranty), but still i sheled another 7.5K bucks.. it sucked a alot. Authorised Service center took around 15 days and declined to give proper bills, on much insistence they gave me a now approved bill on their shop stamp head (Not lenovo). I mailed to them but alas no response from them .. i think they want their customer to suffer.

      Then as the destiny goes by my screen again became loose after around 1.5 yrs, i went to service center but i was not willing to shell another 7K on the piece of trash. I purchased an external monitor instead.

      Just another year passed and the laptop fan stopped working, i got it replaced, but the overheating knocked down my GPU (It was Nvidia Geforce 8 series). I than made up my mind to never go for lenovo again.

      Lenovo does makes laptops which perform awesome as far as computing is concerned, but their after sales serivce is poor, and the laptops need to handled like a child, a little strain will leave it of no use..
      Think twice before going for lenovo.  :)

      Happy shopping.