How to fix Chrome on Windows sitting at "resolving host" for a long time on each page load

This issue was annoying me increasingly over the last few days. After googling around for a bit, I eventually found an answer that worked for me. Only step 4 is likely to be strictly necessary, but I did a bit of prep just to be sure I didn't break anything.

  1. Disabled my Internet adapter in the "Network and Sharing Center" under "Change adapter settings".
  2. Turned off my VPN program. (Most users won't have this).
  3. Ran "cmd" as administrator. You can do this by hitting the Windows key, typing "cmd" and then right-clicking on the "Command Prompt" search result and then click "Run as administrator".
  4. Inside the Command prompt, ran this command:

    netsh interface ip delete destinationcache

  5. Turned my Internet adapter back on.
  6. Turned my VPN back on.
  7. Google Chrome is now fast again.

Update:

After a bit more investigation I realized that the problem was not solved. The fix that worked was using Google's public DNS servers (8.8.8.8 and 8.8.4.4) rather than the server that my network adapters were configured to use (probably related to my VPN). I made this update in the "Change adapter settings" view described above for each of my two network adapters. In each case, I clicked on the IPv4 settings and clicked "Properties". I then entered the above ip addresses as the DNS servers that I wanted to use. After this change, everything is back to full speed.

Changing the order of entries in Grub 2 bootloader

A while back I had to solve the problem of removing an operating system entry from the Grub 2 bootloader.

Today I solved a related problem: changing the order in which the OS entries appear on the boot menu. It seems there are several solutions to this problem. The one I will show here was the most effective for me because I have already used the approach in the link above to remove an OS from Grub 2.

Here's how you do it:

  1. Log in as root, or execute the following mv commands using "su" before your commands.

    sudo su

  2. Go to the "/etc/grub.d" directory.

    $ cd /etc/grub.d

  3. Look at the directory:

    $ ls

  4. Which will give you a result that look something like this (numbers and names may vary).

    00_header 10_linux 30_os-prober 41_custom
    05_debian_theme 20_linux_xen 40_custom README

  5. Basically, the order of these numbers dictate what the order will be on the Grub menu. You can rename these files to change the order. In my case, I wanted to make one of my "custom" entries the first entry (because it was my Windows 7 partition).

    $ mv 10_linux 15_linux
    $ mv 40_custom 10_custom

  6. Now I just re-run update-grub to re-generate the boot menu table.

    $ update-grub

  7. We can check that things are ok by looking through the generated file. In my case, I checked that my Windows 7 entry was present in the file. Interpreting this file deeply requires a lot of knowledge, so don't worry if it is mostly gibberish.

    $ vi /boot/grub/grub.cfg

  8. Restart your computer to see the new boot menu order.

Manually removing an OS from Grub 2 bootloader in Ubuntu 11.10

This post is here partially because I have had to go through this action several times in the last few months.

I recently bought a Samsung NF-210 Netbook and I have been fighting with setting it up since then. The netbook comes preloaded with Windows 7 Starter. I added in Ubuntu as a dual-boot option. I started with Ubuntu 10.10, but that proved to be difficult to use because it did not correctly handle the function keys for changing brightness or volume.

This same solution worked on Ubuntu 10.10 as 11.10.

My goal is to remove the Windows Recovery Environment from the automatic listing on the grub boot menu. This is more than just a cosmetic change because if you accidentally run this partition, it will fubar your boot partition causing you to lose the ability to boot using grub. Thus you will have to reinstall grub or possibly an entire OS (either linux or windows) depending on how you have set up your hard drive.

  1. Fire up a terminal, switch to root via "sudo su".
  2. "cd /etc/grub.d" - changing to the directory where we do most of the work.
  3. "chmod -x 30_os-prober" - turning off the automated ability of grub to find new non-linux OSes.
  4. "vi /boot/grub/grub.cfg" - going to see the current profile of OSes detected on the computer.
  5. Scroll down until you spot the entries for your windows partitions. Select the one(s) that you do want to show up on the menu. Copy them to the clipboard. Copy this text to somewhere so that you can paste it into the next file...
  6. "vi 40_custom" - This custom file lets you add your own OS profiles to the grub menu.
  7. Paste in the text that you copied earlier (below the comments).
  8. "chmod +x 40_custom" - The file needs to be executable in order to be included in the grub menu.
  9. "update-grub" - Grub needs to re-create its menu.

Now when you reboot you should see that only the OSes that you selected and moved will show up. In my case I moved my Windows 7 profile, but not the Recovery Environment profile. Thus when I boot I see all of my menu items except the recovery profile. Yey!