DAQ:FireFox

From HallCWiki
Jump to navigationJump to search

The Hall C electronic logbook is a web based application, so having a properly functioning web browswer available on counting house computers is an essential part of Data Acquisition. Most computers in the counting house are usually logged into the "cdaq" or "cvxwrks" accounts and thus share home directories on the file server. When computers are sharing home directories, runing FireFox (or other Mozilla based browser) can get messy with lots of profiles being created. This page describes how we make sure that each FireFox instance on each computer has it's own profile and how prompting for profile creation is avoided.

FireFox Installation

In order to have a recent and consistent version of FireFox on the counting house computers, not all of which run the same version of Linux, FireFox is installed on the Hall C file server, cdaqfs. Various versions of firefox are untarred into /net/cdaqfs/apps/Linux-rhe/firefox. The directory PRO is a softlink to the version that will be used.

FireFox Startup Script

In the bin/Linux subdirectory of both the cdaq and cvxwrks accounts, the following script, named firefox is placed.

#!/bin/bash

MOZDIR="/net/cdaqfs/apps/Linux-rhe/firefox/PRO"

$MOZDIR/firefox -a firefox -remote "openURL("$@",new-tab)" ||
exec $MOZDIR/firefox -P $HOST "$@";

This script will start FireFox using a profile based on the full hostname of the computer. (E.g. "cdaql2.jlab.org".)

Starting FireFox

FireFox should be started by running ~/bin/Linux/firefox. Preferably ~/bin/Linux should be placed into PATH before /usr/bin so that the script overrides any version of FireFox that came with the OS installation or an alias for firefox be defined in the login script.

The web browser button on the window manager (E.g. xfce) should be configured to run ~/bin/Linux/firefox.

If a profile is prompted for when starting FireFox, a new profile should be created using the full hostname. If a window pops up claiming that another copy of FireFox is running, then make sure that all other copies running under the logged in account are killed. If the error persists, then startup Profile with the command ~/bin/Linux/firefox -ProfileManager. Use the profile manager to delete any profiles that have the hostname in them and then create a new profile.