How to speed up the Smart Location Bar (Awesome Bar)?

6

1

The Firefox Awesome Bar is indeed awesome. But, lately I see that it has become slow. On entering some characters it even freezes for a few seconds (freezing the entire browser).

Why does it slow down? Is there a way to speed it up?

(The OS is Windows XP.)

Ashwin Nanjappa

Posted 2009-07-16T08:47:22.283

Reputation: 8 705

Yep, Firefox 3.7 should be a bit faster when it comes out. http://mashable.com/2009/06/29/firefox-next/

– Tomas Andrle – 2009-07-27T22:08:46.873

I can't find a reference to it now, but I remember reading on one of the mozilla devs blogs that they were looking into this. – Sam Hasler – 2009-07-16T11:27:54.643

What add-ons do you have installed? I'm having the same issue on my home desktop and it even seems to lose keystrokes consistently. I'm wondering if it could be related to a particular add-on. – Joe Holloway – 2009-09-09T13:32:34.420

Answers

10

You could VACUUM the SQLite databases that Firefox uses to store it's history and other data. Vacuuming optimizes the database tables inside the files. That speeds up Firefox and saves you some disk space.

To vacuum the Firefox database files:

  1. Find the Firefox profile data directory on your system. On Windows Vista, it could be somewhere like C:\Users\tom\AppData\Roaming\Mozilla\Firefox\Profiles\default.jqi\. The directory contains files with the .sqlite extension, so you can find it by searching for those.

  2. Get the SQLite command line utility here.

  3. Close all Firefox windows. Open a command line in the profile directory.

  4. On Windows, type in the command for %i in (*.sqlite) do @echo VACUUM; | sqlite3 %i On Linux or Mac, run for i in *.sqlite; do echo "VACUUM;" | sqlite3 $i ; done

  5. Defragment your harddrive.

Google Chrome actually uses SQLite as well, except it doesn't give the files the .sqlite extension. You can still safely run the same command for all the files in the Chrome profile directory and SQLite will only VACUUM the files it recognizes.

Tomas Andrle

Posted 2009-07-16T08:47:22.283

Reputation: 2 892

On a Mac: ~/Library/Application\ Support/Firefox/Profiles/*.default/ (see http://superuser.com/questions/3275/firefox-on-mac-slow-slow-slow/3739#3739)

– Arjan – 2009-08-18T09:17:42.540

Is there any reason you're putting VACUUM in both bold and all-uppercase? – Hello71 – 2011-03-14T15:56:37.490

@Hello71: nope. I'm just used to writing SQL keywords in uppercase for better readability. Lowercase should work fine. – Tomas Andrle – 2011-03-15T09:40:10.937

2

It is easier to install the Vacuum Places addon which allows you to defragment the Places database with the click of a button.

You used to be able to run the command:

Components.classes["@mozilla.org/browser/nav-history-service;1"].getService(Components.interfaces.nsPIPlacesDatabase).DBConnection.executeSimpleSQL("VACUUM");

in the "Error Console" to vacuum the database, but I'm not sure it works in Firefox 3.6.

dogbane

Posted 2009-07-16T08:47:22.283

Reputation: 3 771

1

This is because you have a lot of pages history. Clearing history every once in a while helps with this.

John T

Posted 2009-07-16T08:47:22.283

Reputation: 149 037

6Doesn’t that somewhat diminish the awesomeness of the awesome bar. – Jeremy French – 2009-07-16T11:21:54.657

1

Well the awesome bar queries your history, bookmarks and recent search terms (from the same bar) so perhaps you've got a lot of data in there. Try clearing out your history (from a month back onwards if you'd like to keep recent history) and emptying your search history - 3.5 has a useful tool for this (that can clear up to a set date). This should speed up your query times if there's less data.

Ross

Posted 2009-07-16T08:47:22.283

Reputation: 2 848

0

If you have SQLite you can run this command:

echo 'DELETE FROM moz_historyvisits
WHERE visit_date < strftime("%s", "now", "-5 month") * 1000000; VACUUM;' |
sqlite3 places.sqlite

Steven Penny

Posted 2009-07-16T08:47:22.283

Reputation: 7 294

0

This works just fine for me:

cd ~/.mozilla/firefox/????????.default
echo "VACUUM;" | sqlite3 places.sqlite

The idea is VACUUMing, as suggested, only places.sqlite.

muhuk

Posted 2009-07-16T08:47:22.283

Reputation: 143

0

On Linux you could use tmpfs to mount part of the filesystem in memory. (Ironically, of course, one of SQLite's best features is its ability to store an entire database in memory in the first place.)

Wikipedia suggests an alternative to tmpfs for Windows, but it doesn't go into details and it feels somewhat hacky. YMMV.

Nikhil Chelliah

Posted 2009-07-16T08:47:22.283

Reputation: 1 028

0

The Places Maintenance extension has a UI that allows easy vacuuming (optimization) of Firefox database files, which should help speed up the Awesome Bar and other Firefox database access. It also has other Firefox database maintenance functions:

Allows to run Maintenance tasks on the database that drives Places, the bookmarks and history module behind Firefox.

Places Maintenance UI

galacticninja

Posted 2009-07-16T08:47:22.283

Reputation: 5 348