Page: 1, 2  Next

Switching from Debian Iceweasel to Firefox, permanently
techAdmin
Status: Site Admin
Joined: 26 Sep 2003
Posts: 4124
Location: East Coast, West Coast? I know it's one of them.
Reply Quote
The problem with Iceweasel and why I am now using Firefox
Because Iceweasel has had a consistent pattern of bugs and major failures in Debian over the past few years, leading up to the most recent set, I decided to finally give up, raise the white flag, and start running Firefox from www.mozilla.com instead.

Before I hear from the legions of Debian fanboys, none of whom will pay for my new laptop I would need to get if I kept using Iceweasel on a laptop I run (cpu runs around 70-80% at 1.4 gigaherz) with Debian Testing (as of 11-12-2009), or who will explain how I am supposed to use Iceweasel with my complicated bookmarks if it crashes every time I try to scroll down my bookmark folder list when I am trying to create a bookmark (bug first reported in Mozilla August 2009!, and correctly called invalid because Firefox ships with the correct version of libsqlite), I also want to point out that ever since I switched to Debian as my full time desktop in early 2006, Firefox/Iceweasel has had nothing but problems, so this isn't some new thing, or an over-reaction to one bug.

I'd like to say, I'm sorry about the Iceweasel groups problems, I'm sorry the dev isn't into it anymore, and I'm sorry that it's a complicated package. I understand this is volunteer work, and that we all do this to try to help others, but the simple fact is, Debian Iceweasel is NOT the same as Firefox, and it's clearly obvious that it's not trivial work to maintain a package of this complexity. So don't bother expecting this level, just work around it for good.

So rather than waste weeks, again, on trying to figure out if a bug is an Iceweasel introduced failure, or if it's rooted in Firefox itself, I decided to finally simplify the process and dump Iceweasel as my default Firefox app.

Basic Firefox system links and plugins info
To make matters easier, you can reuse your Iceweasel plugins.dat information, which has the paths to all your plugins. If you are going to skip using Iceweasel completely, you'll need to make a symbolic link from /opt/firefox/plugins to /usr/lib/mozilla/plugins so you can use the Debian packaged flash, acroread (if you use acrobat reader), and Java plugins.

Doing this requires a few changes, so I'll outline the changes here:

Download, Extract, Install
These directions apply to both 32 and 64 bit Firefox installs. See below for instrutions on how to install the 32 bit version on 64 bit system if for some reason the 64 bit does not work for you, but it should.

First, go to www.mozilla.com and download the bz file for Firefox. You can extract this to either your /home directory somewhere, which will let you use its updating feature easily, since you have write permissions there, or you can move it to /opt, which is where extra packages are supposed to go.

Whichever way you choose, after you download the package, extract it, which leaves you with a 'firefox' directory. Move this to your preferred location.

Let's assume from now on you put it in /opt. Next, you want to change the permissions of the /opt/firefox directory contents to your standard logged in username:
:: Code ::
chown <username> -R /opt/firefox (replace <username> with your log in user name).


This lets Firefox update itself, which saves you the bother of keeping track of this stuff.

Next, you want to move the iceweasel fake firefox link in /usr/bin and create a symbolic link to /opt/firefox/firefox instead, like so:

:: Code ::
mv /usr/bin/firefox /usr/bin/firefox-iw
ln -s /opt/firefox/firefox /usr/bin/firefox

Now your main stuff is set.

If you want to use the /usr/lib/mozilla/plugins directory, do this:
:: Code ::
ln -s /usr/lib/mozilla/plugins /opt/firefox/plugins

you might need to use the -f option to overwrite the opt one.

Set System Defaults and Create desktop entry file
You'll want to add a few more tweaks to make sure everything is the way the system expects.

First, let's create a firefox.desktop file in /usr/share/applications so the system knows about the new app:

(Note: the path to Icon= can change, check the contents of the firefox directory to locate the mozicon.128.png file in case it's not there, then adjust the path accordingly, and post on this thread if it has changed. This path is correct as of firefox 25)

:: Code ::
 echo '[Desktop Entry]
Name=Firefox
GenericName=Web Browser
Comment=Surf the internet
Exec=/opt/firefox/firefox %u
Terminal=false
Icon=/opt/firefox/browser/icons/mozicon128.png
Type=Application
Categories=Application;Network;WebBrowser;
MimeType=text/html;text/xml;application/xhtml+xml;application/xml;application/vnd.mozilla.xul+xml;application/rss+xml;application/rdf+xml;image/gif;image/jpeg;image/png;
StartupWMClass=Firefox-bin
StartupNotify=true' > /usr/share/applications/firefox.desktop

Note: check icon path and icon file name, the name changes sometimes release to release.

Now we have to update the system, make sure to use a link to the direct /opt/firefox/firefox instead of /usr/bin/firefox whenever you can, since the /usr/bin/firefox might get overwritten by an iceweasel update (hint, after you set it up, put iceweasel on hold: aptitude hold iceweasel).

Assuming you had iceweasel as your default, you'll need to change a few things now in your system. I use KDE, so you have to change these in your desktops if it's not KDE to whatever your desktop requires.

First, change overall desktop defaults, assuming you used iceweasel:

KDE 3.5: open KDE control center, KDE Components, File Associations, type 'html' (no ' marks) into the search box, select html. If firefox is in the list, fine, move it to the top with the move up button. If not, add it using the ADD button.

KDE 4.x: K menu, Settings, System Settings. Chose advanced settings tab. Click File Associations. Type in 'html' into search box, then do as above to make firefox the default app for KDE.

Do this in the 'application' and the 'text' item. Double check that it's going to /opt/firefox/firefox %u which it should now know about from the firefox.desktop item you made.

Now change konversation, if you use it, to default to firefox. Open konversation, select Settings -> Configure Konversation, select Behavior/General item. Check the 'Use custom web browser' box, then put in:
:: Code ::
/opt/firefox/firefox '%u'

Now add any shortcuts you might want.

The firefox icons are in /opt/firefox/browser/icons/ for the full size one, and /opt/firefox/browser/chrome/icons/default for the smaller ones. This path has changed in the past, and it may again, so just look through the directories to locate the png of the icon and use that path in the above desktop file.

Next, if you use icedove, change the default browser that links in emails opens up with. Select Edit, Preferences, Advanced tab, click Config Editor button.

If you have set your default network.protocol-handler.app.http and network.protocol-handler.app.https handlers, you just need to edit them, otherwise create them. Set the path to the firefox app there. Again, try to always use the real path, /opt/firefox/firefox in all these, because the /usr/bin/firefox can get overwritten. However, /usr/bin/firefox is needed for KDE to correctly open firefox instead of iceweasel on session restore, but as far as I know, that's the only place it's really used, but you can't work around that one as far as I know.

Extra Installation Information
You can find more information at Mozilla: Installing Firefox on Linux and Firefox system requirements page.

There's also this linuxquestions.org Firefox on Debian thread, which is thankfully light on fanboys, and which shows one serious advantage of installing directly, getting the newest version immediately, not having to wait for it to trickle into sid or testing.

Flash player update
As of flash 11.2 I believe, adobe stopped shipping new flash versions for linux using the old plugin api. There are no current versions of flash that work, so you have to use the old version for now, until firefox updates their api to support the new method used by Google Chrome, which is the only browser in linux as far as I know that currently supports new flash out of the box. This will probably change in the future, I am writing this as of Firefox 25.0 / 2013-11-14. If firefox changes this, and if the packages change for fiash in debian, let me know and I'll update the thread.

Use update-alternatives to set system to use new firefox by default
Only do this if you want the new firefox to be the system wide default X mode gui web browser (x-www-browser)

:: Code ::
update-alternatives: --install needs <link> <name> <path> <priority>

<link> is the symlink pointing to /etc/alternatives/<name>.
  (e.g. /usr/bin/pager)
<name> is the master name for this link group.
  (e.g. pager)
<path> is the location of one of the alternative target files.
  (e.g. /usr/bin/less)
<priority> is an integer; options with higher numbers have higher priority in
  automatic mode.

:: Code ::
update-alternatives --install  /usr/bin/x-www-browser x-www-browser /opt/firefox/firefox 100
update-alternatives: using /opt/firefox/firefox to provide /usr/bin/x-www-browser (x-www-browser) in auto mode.


64 bit information - LEGACY - Only use this if the regular 64 bit firefox does not work for you
To do a direct install of Firefox, which appears to be available in 32 bit binaries only, note you will need a few extra packages. First just add any dependencies:

:: Code ::
aptitude install iceweasel

(to pull in any gtk and other required libs). Remove iceweasel itself if you don't want it after you're done, or better, just note the packages it comes with, and install them alone, though they won't get updated as dependencies if those change in the future (this is why I suggest just keeping iceweasel installed but not used), then do:
:: Code ::
aptitude install ia32-libs ia32-libs-gtk

(I think that's the package name, I don't use 64 bit, for these types of reasons) and figure out the rest for yourself. If there are more steps required please post them here.

For straight 64 bit flash, get 64 bit Flash direct from Adobe here if you are forced to deal with a 64 bit desktop.

Here are directions on compiling to 64 bit from source. Not my cup of tea, but there it is, along with the inevitable problems and hacks required.

But really, just run 32 bit version, like this (edited to remove unneeded steps):
:: Quote ::
Seen a lot of things about running flash and Java on AMD64 platform
i chose to install a 32-bits browser and it works like a charm

1) install
ia32-libs
ia32-libs-gtk

2) Install 32 bit firefox [using the above directions].

[not sure if these 3 are needed on newer systems]
4) launch the browser and type in the address bar: 'about:config'
5) search for 'IPV6'
6) right click -> toggle

7) add your 32 bits plugins and enjoy


Conclusion
I really wish this wasn't necessary, but the fact is, Iceweasel in Debian is getting downright useless, if not literally dangerous for my hardware.

By switching, on a laptop, for example, I went from (Iceweasel) cpu at 70-80% always, at full speed, 1.4 gigaherz, to (with Firefox direct), cpu at 7-8%, at 600 mghz, with exactly the same extensions, open tabs, and settings. This isn't even remotely funny, and directly proves that whatever Debian says about Iceweasel being just a slightly tweaked Firefox simply isn't true. I get the same results on a dual core box, although less dramatic, because I use so many tabs running so many complex sites that the difference isn't as striking, but it's still significant, cpu throttling for example never kicks in with iceweasel, but does kick in with Firefox.

Plus, the fact that Firefox shipped with libsqlite that it works with, and Debian, along with most other distros, updated libsqlite to a newer version that breaks a key API that firefox needs (oh, whoops...) shows to me that there is no point in ever using the debian packaged iceweasel again. This isnt' the first major problem, by the way, I've had with Iceweasel, and it's not the first time I've seen such Debian caused issues. Debugging Firefox issues is hard enough as it is, and if you add in an extra layer of possible Debian error, it makes it close to impossible to track down the problems. So I'm now free of this headache. I'm sure Firefox themselves will mess up again in the future, but at least I will know the source of the messup now.

On my dual core box, it runs now about 10C cooler, and at half (1/2) the cpu speed. In other words, not only can iceweasel break your system and fry the cpu, it contributes to global warming and is bad for the environment. Sadly this isn't a joke.

Thunderbird

Similar issues, here's a few steps as I find them:

:: Code ::
update-alternatives --install /usr/bin/x-mail-client x-mail-client /opt/thunderbird/thunderbird 10

Back to top
aus9
Status: Assistant
Joined: 21 Sep 2008
Posts: 358
Location: Australia
Reply Quote
hi

and to hijack slightly.....I use the non-free adobe plugin.

1) use root powers to create folder
:: Code ::

su
mkdir /usr/lib/adobe-plugin


2) download the tarball version of adobe flashplayer
unpack it gives you one file called libflashplayer.so
move it to new folder using root powers

3) symbolic link (symlink) to where you run firefox from...I am alone so mine sits in home folder, so I can run it as local user
:: Code ::

ln -s /usr/lib/adobe-plugin/libflashplayer.so /home/gordy/fox/plugins/


4) I have a bookmark for adobe so I can check my version on a regular basis.....I am hoping there is a smarter way?
www.adobe.com/software/flash/about/

joining up to adobe is not my preferred option
Back to top
craigevil
Status: Interested
Joined: 05 Jul 2009
Posts: 12
Location: OZ
Reply Quote
aus9

apt-get install flashplugin-nonfree

or apt-get install flashplayer-mozilla from debian-multimedia.org

Either way it gets updated when doing apt-get upgrade or aptitude full-upgrade

Downloading it from adobe should always be a last resort.
Back to top
Firefox in Mint Debian repos
secipolla
Status: Contributor
Joined: 21 Nov 2009
Posts: 72
Reply Quote
Now we have Firefox for Debian, with all localizations, proper firefox.desktop and proper Debian alternatives.
Add to /etc/apt/sources.list (or /etc/apt/sources.list.d/mint.list)*
:: Code ::
#### Mint Debian testing
deb http://packages.linuxmint.com/ debian main upstream import

then run (as root)
:: Code ::
apt-get update && apt-get install linuxmint-keyring

and for firefox
:: Code ::
apt-get install firefox

and for localizations (e.g. Brazilian Portuguese)
:: Code ::
apt-get install firefox-l10n-pt-br


Shipped firefox.desktop:
:: Code ::
[Desktop Entry]
Version=1.0
Name=Firefox Web Browser
Name[ar]=متصفح الوِب فَيَرفُكْس
Name[ca]=Navegador web Firefox
Name[cs]=Firefox Webový prohlížeč
Name[es]=Navegador web Firefox
Name[et]=Firefoxi veebibrauser
Name[fa]=مرورگر اینترنتی Firefox
Name[fi]=Firefox-selain
Name[fr]=Navigateur Web Firefox
Name[hu]=Firefox webböngésző
Name[it]=Firefox Browser Web
Name[ja]=Firefox ウェブ・ブラウザ
Name[ko]=Firefox 웹 브라우저
Name[nb]=Firefox Nettleser
Name[nl]=Firefox webbrowser
Name[nn]=Firefox Nettlesar
Name[no]=Firefox Nettleser
Name[pl]=Przeglądarka WWW Firefox
Name[pt]=Firefox Navegador Web
Name[pt_BR]=Navegador Web Firefox
Name[sk]=Firefox - internetový prehliadač
Name[sv]=Webbläsaren Firefox
Comment=Browse the World Wide Web
Comment[ar]=تصفح الشبكة العنكبوتية العالمية
Comment[ca]=Navegueu per el web
Comment[cs]=Prohlížení stránek World Wide Webu
Comment[de]=Im Internet surfen
Comment[es]=Navegue por la web
Comment[et]=Lehitse veebi
Comment[fa]=صفحات شبکه جهانی اینترنت را مرور نمایید
Comment[fi]=Selaa Internetin WWW-sivuja
Comment[fr]=Navigue sur Internet
Comment[hu]=A világháló böngészése
Comment[it]=Esplora il web
Comment[ja]=ウェブを閲覧します
Comment[ko]=웹을 돌아 다닙니다
Comment[nb]=Surf på nettet
Comment[nl]=Verken het internet
Comment[nn]=Surf på nettet
Comment[no]=Surf på nettet
Comment[pl]=Przeglądanie stron WWW
Comment[pt]=Navegue na Internet
Comment[pt_BR]=Navegue na Internet
Comment[sk]=Prehliadanie internetu
Comment[sv]=Surfa på webben
GenericName=Web Browser
GenericName[ar]=متصفح وب
GenericName[ca]=Navegador web
GenericName[cs]=Webový prohlížeč
GenericName[es]=Navegador web
GenericName[et]=Veebibrauser
GenericName[fa]=مرورگر اینترنتی
GenericName[fi]=WWW-selain
GenericName[fr]=Navigateur Web
GenericName[hu]=Webböngésző
GenericName[it]=Browser Web
GenericName[ja]=ウェブ・ブラウザ
GenericName[ko]=웹 브라우저
GenericName[nb]=Nettleser
GenericName[nl]=Webbrowser
GenericName[nn]=Nettlesar
GenericName[no]=Nettleser
GenericName[pl]=Przeglądarka WWW
GenericName[pt]=Navegador Web
GenericName[pt_BR]=Navegador Web
GenericName[sk]=Internetový prehliadač
GenericName[sv]=Webbläsare
Exec=/opt/firefox/firefox %u
Terminal=false
X-MultipleArgs=false
Type=Application
Icon=/opt/firefox/icons/mozicon128.png
Categories=Application;Internet;Network;WebBrowser;
MimeType=text/html;text/xml;application/xhtml+xml;application/xml;application/vnd.mozilla.xul+xml;application/rss+xml;application/rdf+xml;image/gif;image/jpeg;image/png;
StartupWMClass=Firefox
StartupNotify=true


Alternatives:
:: Code ::
root@debian:/etc# update-alternatives --config x-www-browser
There are 2 choices for the alternative x-www-browser (providing /usr/bin/x-www-browser).

  Selection    Path                  Priority   Status
------------------------------------------------------------
* 0            /opt/firefox/firefox   70        auto mode
  1            /opt/firefox/firefox   70        manual mode
  2            /usr/bin/xlinks2       69        manual mode



*the upstream component are apps modified by Mint. Not needed for just Firefox since currently there's just Xchat in this category.
Mint Debian repository
Back to top
techAdmin
Status: Site Admin
Joined: 26 Sep 2003
Posts: 4124
Location: East Coast, West Coast? I know it's one of them.
Reply Quote
wow, good for mint, and it's even in opt, which suggests they didn't break the package like debian does.

Speaking for myself I'm going to keep using firefox direct install, since I will always get the new updates the day of, or second latest, of release.

Of course, if mint isn't breaking the packages, there's no reason they can't also just put out the new version day of release since all they have to do, presumably, will be to unzip the tar file and then build the new package, exactly what debian should have offered in its contrib long ago.

I'm glad to see people actually using some common sense to solve simple problems now and then.

This may warrant an smxi inclusion, since the steps are clear and easily scriptable.
Back to top
secipolla
Status: Contributor
Joined: 21 Nov 2009
Posts: 72
Reply Quote
I installed it here since I intend to pass on this PC to another person. Mint Debian's ISO has just been approved in their internal testing and will be available soon. It defaults to Debian "testing".

The firefox package is just /opt/firefox... /usr/bin/firefox, the .desktop file and the Debian docs.
Back to top
techAdmin
Status: Site Admin
Joined: 26 Sep 2003
Posts: 4124
Location: East Coast, West Coast? I know it's one of them.
Reply Quote
can you check to see if the mint package updates during an apt-get install firefox or du?

There's a new firefox today or yesterday, so you can test if it's in Mint.

To see, also just check this first:

apt-get update
then
apt-cache show firefox

that will show the current version if that package is direcctly linked to the firefox version number:

current firefox: 3.6.9
Back to top
secipolla
Status: Contributor
Joined: 21 Nov 2009
Posts: 72
Reply Quote
I received the update notification yesterday, the one from Firefox itself but I didn't update it to check if Mint would update their package (also to be able to update from within FF I would have to change /opt ownership).
Mint hasn't updated it yet.
I also checked their repositoris and noticed that they created this package specially for Mint Debian, because the Ubuntu version gets the Ubuntu package.
So I think they'll have to get the hang of updating it but also I think they must be somewhat busy with all the hype now.
I'll raise the subject on their forum. I'm pretty sure they'll not miss those updates in the future but let's see.
Back to top
techAdmin
Status: Site Admin
Joined: 26 Sep 2003
Posts: 4124
Location: East Coast, West Coast? I know it's one of them.
Reply Quote
I'm just wondering because it's possible they are simply making a virtual package, ie, one that simply downloads and extracts firefox to /opt, and doesn't track updates.

That would be a mistake because browser updates are not optional for secure browsing now.

I am also debating if I should script both the manual install version and the mint installer, but I wont' do the Mint installer if firefox doesn't update when you upgrade the system or do apt-get install firefox.

I've seen some arch packaging methods where they simply download the source and compile it, but the package doesn't at all track updates, thus creating the illusion that you've installed a normal package but you really haven't.
Back to top
secipolla
Status: Contributor
Joined: 21 Nov 2009
Posts: 72
Reply Quote
I think Mint's is a proper package, it even has the version and all:
:: Code ::
temp@debian:~$ apt-cache policy firefox
firefox:
  Instalado: 3.6.8-1linuxmint2
  Candidato: 3.6.8-1linuxmint2
  Tabela de versão:
 *** 3.6.8-1linuxmint2 0
        500 http://packages.linuxmint.com/ debian/import i386 Packages
        100 /var/lib/dpkg/status

Only they left Firefox's update checking enabled. If it was only for downloading and installing it wouldn't be that bad because changing /opt's ownership would be enough to keep the browser up-to-date but they wouldn't do that since Mint is made to be as easy as it can be and even the updates are meant to come in automatically. The point is that they must be working on mintupdate to make it fit in Mint Debian and when I say "they" maybe it's only Clement.
Anyway I posted in the forum and as you said, hope the norm will be to update it as soon as possible after a new version is out.
Back to top
Display posts from previous:   
Page: 1, 2  Next
All times are GMT - 8 Hours