the Rainbow Networks
+++eXy FFA
Map: hektik
Players: 2 / 18
The golden pot › RAINBOW NETWORKS › Main › Firefox 3 speed up
Firefox 3 speed up
"There is only only problem, there isnt a General Crap section, that is my home. :)

I shall use Main for now. Main what? Main crap?"

Post new topic   Reply to topic   Printer Friendly Page     Forum IndexMain
View previous topic :: View next topic  
Author Message
Falkland
Übergod
Übergod


Joined: Aug 01, 2008
Posts: 922
Location: Nowhere

PostPosted: Wed May 20, 2009 5:18 pm    Post subject: Firefox 3 speed up Reply with quote

Firefox 3 uses sqlite to store urls, visited pages , bookmarks , cookies etc ...

Now I've found a procedure to optimize the firefox3 sqlite database :

Quote: www.gettingclever.com/...fox-3.html

Quote::

...
Having database store your browsing data has one drawback, you have to optimize the database from time to time to get rid of old, deleted data, re-index the columns etc. Otherwise you keep all the junk data mixed in with your real data.

In SQLite is the statement to do this called VACUUM;. So here's how to vacuum your Firefox:

1. Download sqlite command line client for your platform.
2. Turn off your Firefox
3. Go to your profile folder
4. Issue the command:
* For Linux

$ for i in *.sqlite; do echo "VACUUM;" | sqlite3 $i ; done

* For Windows

for %i in (*.sqlite) do @echo VACUUM; | sqlite3 %i

In my case this effectively cut the size of urlclassifier3.sqlite and places.sqlite to half. Thus saving 20 MB in my memory and Firefox's speed improvement was very noticeable. So have fun with the vacuum cleaner :).

Back to top
View user's profile
chiquita
Alpacas Approved
Alpacas Approved


Joined: Sep 01, 2007
Posts: 1410
Location: psychiatric ward

PostPosted: Wed May 20, 2009 5:36 pm    Post subject: Re: Firefox 3 speed up Reply with quote

Nice find. I hated FF3 when I noticed it doesnt work properly when it's not connected. Now it shows a jar file message on the latest one.

A while back I found the firefox -P option... which starts up FF and you can create different profiles.. for example you might want run a light version with no extensions so it takes less RAM and less load time etc. When you start FF it requests what account you want to use
Back to top
View user's profile
Joki
Übergod
Übergod


Joined: Apr 16, 2008
Posts: 1037
Location: at tiled stove

PostPosted: Wed May 20, 2009 5:45 pm    Post subject: Re: Firefox 3 speed up Reply with quote

How do i do that with postgreSQL, that i have already installed?

_________________
Back to top
View user's profile Visit poster's website
Falkland
Übergod
Übergod


Joined: Aug 01, 2008
Posts: 922
Location: Nowhere

PostPosted: Wed May 20, 2009 6:54 pm    Post subject: Re: Firefox 3 speed up Reply with quote

Linux way :

- apt-get install sqlite3
- make a shell script :

Code::
#### firefox-cleanup.sh ####

#!/bin/bash 

for i in *.sqlite; 
    do echo "VACUUM;" | sqlite3 $i ; 
done

- open a shell and type cd ~/.mozilla/firefox/<whatever_is_named_your(s)_profile_dir(s)>
- run the script (eg sh ~/firefox-cleanup.sh)


Windows way :

- download the commandline program from here : www.sqlite.org/download.html ( sqlite-3_6_14_1.zip -> 247.61 KiB)
- exctract the tool and place it in your PATH ( eg C:\Windows ) or add to your PATH the location where u've extracted it.
- make a .bat or .cmd script :

Code::
#### firefox-cleanup.cmd ####

for %i in (*.sqlite) 
   do @echo VACUUM; | sqlite3 %i

EDIT : added the correct and working script for WinXP

Code::
@@ firefox-cleanup.cmd or firefox-cleanup.bat @@

for %%i in (*.sqlite) do @echo VACUUM; | sqlite3 %%i

- place the script somewhere and add the location to your PATH or place the script in C:\Windows
- open a Command line window and type cd C:\Documents and Settings\<username>\Application Data\Mozilla\Firefox\Profiles\<whatever_is_named_your(s)_profile_dir(s)> ( this is the common path in Windows XP .. it should be a bit different for Vista )
- run the script

EDIT : don't forget to do this after shutting down firefox or at least to work on a profile that is not in use by firefox itself.


Last edited by Falkland on Thu May 21, 2009 6:38 pm; edited 2 times in total
Back to top
View user's profile
[sXe]
Forum Addict
Forum Addict


Joined: Sep 27, 2007
Posts: 354
Location: Germany

PostPosted: Wed May 20, 2009 9:19 pm    Post subject: Re: Firefox 3 speed up Reply with quote

As recommend in the comments I tried it with the SQLite Manager Firefox Plugin but it says @ Last Error: database disk image is malformed :|

_________________

Back to top
View user's profile
jackthompson
Admin
Admin


Joined: Aug 15, 2007
Posts: 1302
Location: Here

PostPosted: Thu May 21, 2009 5:12 am    Post subject: Re: Firefox 3 speed up Reply with quote

Joki wrote:
How do i do that with postgreSQL, that i have already installed?

maybe one has to just copy the db to pg and change its ip:port in the firefox config.. or so...
Back to top
View user's profile
Joki
Übergod
Übergod


Joined: Apr 16, 2008
Posts: 1037
Location: at tiled stove

PostPosted: Thu May 21, 2009 8:59 am    Post subject: Re: Firefox 3 speed up Reply with quote

Just tried it with your sqllite cmdline binary, since it doesnt need an installation or anything. (I try to avoid programs that requires an installation, since after times it will leave lots of waste on my HD):

Code::
C:\>cd %APPDATA%\Mozilla\Firefox\Profiles

C:\Dokumente und Einstellungen\JocklGockl\Anwendungsdaten\Mozilla\Firefox\Profiles>cd hry4p31h.default

C:\Dokumente und Einstellungen\JocklGockl\Anwendungsdaten\Mozilla\Firefox\Profiles\hry4p31h.default>sqlff.bat

"i" ist syntaktisch an dieser Stelle nicht verarbeitbar.

C:\Dokumente und Einstellungen\JocklGockl\Anwendungsdaten\Mozilla\Firefox\Profiles\hry4p31h.default>for i in (*.sqlite);

C:\Dokumente und Einstellungen\JocklGockl\Anwendungsdaten\Mozilla\Firefox\Profiles\hry4p31h.default>exit

_________________
Back to top
View user's profile Visit poster's website
kernel_panic
Übergod
Übergod


Joined: Aug 28, 2007
Posts: 751
Location: uk

PostPosted: Thu May 21, 2009 11:38 am    Post subject: Re: Firefox 3 speed up Reply with quote

Quote::
As recommend in the comments I tried it with the SQLite Manager Firefox Plugin but it says @ Last Error: database disk image is malformed :|

That method worked fine here...

_________________
"Fuelling off topic babble since day 1."
Back to top
View user's profile
Falkland
Übergod
Übergod


Joined: Aug 01, 2008
Posts: 922
Location: Nowhere

PostPosted: Thu May 21, 2009 2:23 pm    Post subject: Re: Firefox 3 speed up Reply with quote

I am not an expert in windows shell scripting , but this seems to work correctly ( tested in wine ) :

Code::

for %%i in (*.sqlite) do @echo VACUUM; | sqlite3 %%i

Back to top
View user's profile
Joki
Übergod
Übergod


Joined: Apr 16, 2008
Posts: 1037
Location: at tiled stove

PostPosted: Thu May 21, 2009 4:31 pm    Post subject: Re: Firefox 3 speed up Reply with quote

yup, this worked. grats, falky.

_________________
Back to top
View user's profile Visit poster's website
aanti
Forum Addict
Forum Addict


Joined: Jan 26, 2008
Posts: 269
Location: Frankfurt am Main

PostPosted: Thu May 21, 2009 10:30 pm    Post subject: Re: Firefox 3 speed up Reply with quote

result ? benchmarks ?
Back to top
View user's profile
Joki
Übergod
Übergod


Joined: Apr 16, 2008
Posts: 1037
Location: at tiled stove

PostPosted: Thu May 21, 2009 11:34 pm    Post subject: Re: Firefox 3 speed up Reply with quote

No noticeable difference yet.
But I BELIEVE in it. And believe is, what makes you go on.

_________________
Back to top
View user's profile Visit poster's website
aanti
Forum Addict
Forum Addict


Joined: Jan 26, 2008
Posts: 269
Location: Frankfurt am Main

PostPosted: Fri May 22, 2009 7:43 am    Post subject: Re: Firefox 3 speed up Reply with quote

there are also firefox builds compiled for performance..but i dont think ff is slow
Back to top
View user's profile
Falkland
Übergod
Übergod


Joined: Aug 01, 2008
Posts: 922
Location: Nowhere

PostPosted: Fri May 22, 2009 3:26 pm    Post subject: Re: Firefox 3 speed up Reply with quote

Optimizing the database has real benefits only when firefox does db-related operations and on memory consumption.

For objective better code/engine performances u need a firefox binary built with PGO (Profile Guided Optimizations).

This build procedure does two compilation steps : after compiling firefox once , the new built binary is executed and the build process collects some data.
After collecting a significant amount of data, the build process stops the firefox execution and starts the last stage for building the final optimized binary.

NOTE : the windows firefox version is _ALREADY_ built with PGO and also ( but I'm not sure at 100% ) the default linux builds. The builds that come with Ubuntu and Debian (IceWeasel) are not built with PGO . Someone has stated somewhere that the Fedora and OpenSuse builds are built with PGO but I can't confirm this ...

In terms of absolute performances the beta of firefox 3.5 or the nightly build ( currently in preliminary alpha stage : 3.6a1pre) are significantly better than the current stable firefox version ( 3.0.0.10 ) thankfully to a newer javascript engine and other code optimization.

Take a look at the different performances between Firefox 3.0.0.10 ( Ubuntu Hardy 8.04.2 ) and the nightly build ( 3.6a1pre ) in the sunspider test : www2.webkit.org/perf/s...pider.html (the tests ran in quite the same conditions: the only active process was firefox but the nightly build had a higher number of opened tabs )

Code::
TEST                   COMPARISON            FROM                 TO             DETAILS

=============================================================================

** TOTAL **:           3.02x as fast     8152.6ms +/- 31.7%   2699.2ms +/- 0.7%     significant

=============================================================================

  3d:                  2.30x as fast      892.6ms +/- 2.4%    387.4ms +/- 3.0%     significant
    cube:              2.51x as fast      313.8ms +/- 1.6%    125.2ms +/- 8.1%     significant
    morph:             3.38x as fast      313.8ms +/- 2.6%     92.8ms +/- 9.3%     significant
    raytrace:          1.56x as fast      265.0ms +/- 4.2%    169.4ms +/- 3.9%     significant

  access:              2.67x as fast     1020.2ms +/- 1.3%    381.8ms +/- 1.2%     significant
    binary-trees:      1.06x as fast      105.4ms +/- 3.8%     99.6ms +/- 1.4%     significant
    fannkuch:          2.41x as fast      412.2ms +/- 1.1%    170.8ms +/- 2.1%     significant
    nbody:             4.19x as fast      359.8ms +/- 3.3%     85.8ms +/- 0.6%     significant
    nsieve:            5.58x as fast      142.8ms +/- 3.9%     25.6ms +/- 2.7%     significant

  bitops:              7.46x as fast      698.4ms +/- 4.4%     93.6ms +/- 3.6%     significant
    3bit-bits-in-byte: 37.4x as fast      112.2ms +/- 0.9%      3.0ms +/- 0.0%     significant
    bits-in-byte:      8.59x as fast      156.4ms +/- 2.3%     18.2ms +/- 7.5%     significant
    bitwise-and:       44.3x as fast      177.2ms +/- 0.6%      4.0ms +/- 0.0%     significant
    nsieve-bits:       3.69x as fast      252.6ms +/- 12.4%     68.4ms +/- 3.3%     significant

  controlflow:         -                  206.2ms +/- 139.5%     95.6ms +/- 0.7% 
    recursive:         -                  206.2ms +/- 139.5%     95.6ms +/- 0.7% 

  crypto:              -                  817.0ms +/- 109.9%    136.4ms +/- 2.3% 
    aes:               -                  364.4ms +/- 145.0%     80.6ms +/- 4.4% 
    md5:               6.23x as fast      214.2ms +/- 76.7%     34.4ms +/- 3.2%     significant
    sha1:              11.1x as fast      238.4ms +/- 89.8%     21.4ms +/- 3.2%     significant

  date:                -                 1134.8ms +/- 80.3%    379.6ms +/- 1.3% 
    format-tofte:      2.40x as fast      481.2ms +/- 49.1%    200.4ms +/- 2.6%     significant
    format-xparb:      -                  653.6ms +/- 136.6%    179.2ms +/- 0.9% 

  math:                6.28x as fast     1118.6ms +/- 44.2%    178.0ms +/- 0.9%     significant
    cordic:            4.47x as fast      512.0ms +/- 56.6%    114.6ms +/- 0.6%     significant
    partial-sums:      8.48x as fast      388.4ms +/- 46.7%     45.8ms +/- 2.3%     significant
    spectral-norm:     12.4x as fast      218.2ms +/- 46.1%     17.6ms +/- 3.9%     significant

  regexp:              3.49x as fast      633.8ms +/- 48.2%    181.8ms +/- 11.2%     significant
    dna:               3.49x as fast      633.8ms +/- 48.2%    181.8ms +/- 11.2%     significant

  string:              1.89x as fast     1631.0ms +/- 19.3%    865.0ms +/- 1.8%     significant
    base64:            4.80x as fast      218.0ms +/- 44.7%     45.4ms +/- 1.5%     significant
    fasta:             2.27x as fast      449.0ms +/- 46.9%    198.2ms +/- 1.0%     significant
    tagcloud:          1.25x as fast      303.2ms +/- 1.3%    242.0ms +/- 1.1%     significant
    unpack-code:       1.56x as fast      447.4ms +/- 4.0%    286.0ms +/- 4.2%     significant
    validate-input:    2.28x as fast      213.4ms +/- 6.6%     93.4ms +/- 4.3%     significant

Firefox 3.0.0.10 test
Firefox 3.6a1pre test

If u decide to test/use the 3.5 beta or the nightly build on the same profile u use with stable firefox , many extensions will not work !!! And there are other minor engine/profile related differences between stable and development version.

The best way to test/use the beta or the nightly build is to create a new profile starting firefox by command line with the -P switch option , then create a new profile and run firefox in that profile ( as suggested by chiquita ).
Back to top
View user's profile
Falkland
Übergod
Übergod


Joined: Aug 01, 2008
Posts: 922
Location: Nowhere

PostPosted: Fri May 22, 2009 4:12 pm    Post subject: Re: Firefox 3 speed up Reply with quote

I forgot to mention other optimizations u can do to decrease the loading page time :

1. increasing the max number of connections and the max number of connections per server
2. enabling the http pipelining


- Just type about:config in the address bar and just ignore the mex about the warranty.

- Type network.nttp in the filter bar

- Increase the value ( eg double it ) of network.http.max-connections , network.http.max-connections-per-server , network.http.pipelining.maxrequests

- set to true the keys network.http.pipelining and network.http.pipelining.ssl

- restart firefox ( maybe u don't need this , but .... )
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic   Printer Friendly Page     Forum Index -> Main All times are GMT + 1 Hour
Page 1 of 1


Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Welcome Anonymous


Membership:
Latest: kontol
New Today: 0
New Yesterday: 0
Overall: 355

People Online:
Members: 0
Visitors: 28
Total: 28
Who Is Where:
 Visitors:
01: The golden pot
02: The golden pot
03: Home
04: My Account
05: My Account
06: Rainbow Media
07: Maps
08: The golden pot
09: My Account
10: The golden pot
11: Home
12: Home
13: My Account
14: My Account
15: Maps
16: Home
17: The golden pot
18: Shoutblock
19: The golden pot
20: The golden pot
21: The golden pot
22: The golden pot
23: The golden pot
24: The golden pot
25: The golden pot
26: My Account
27: Home
28: The golden pot

Staff Online:

No staff members are online!

The Rainbow Networks website is hosted by JockeTF and Soder on furver.se.

The Rainbow Networks
Interactive software released under GNU GPL, Code Credits, Privacy Policy
Azul theme and related images designed by Jamin