Scripting Question

Problems installing Firefox 12

07/17/2012 4645 views

I created a script to install Firefox 12 and when it is run the first time I get the error, "Failed to read the configuration file."

From another post I created the following files:

      lockPref("browser.shell.checkDefaultBrowser", false);
      lockPref("browser.startup.homepage_override.mstone", "ignore");
      lockPref("browser.rights.3.shown", false);

      lockPref("toolkit.telemetry.prompted", 2);
      lockPref("toolkit.telemetry.rejected", true);


     pref("general.config.obscure_value", 0);
     pref("general.config.filename", "mozilla.cfg");

My batch file looks like this:
"%~dp0firefox_setup_12.0.exe" -ms

 REM Install 32-bit customisations
     if exist "%programfiles%\Mozilla Firefox\" copy /Y "%~dp0override.ini" "%programfiles%\Mozilla Firefox\"

    if exist "%programfiles%\Mozilla Firefox\" copy /Y "%~dp0mozilla.cfg" "%programfiles%\Mozilla Firefox\"

    if exist "%programfiles%\Mozilla Firefox\" copy /Y "%~dp0local-settings.js" "%programfiles%\Mozilla Firefox\defaults\pref\"

I zipped these files with firefox_setup.exe.

The files were copied to the correct folders and I noticed that I got the settings from local-settings.js in my profile.

Not sure where I have gone wrong.




Answer Summary:
0 Comments   [ + ] Show comments


All Answers

Answered 07/17/2012 by: jagadeish
Red Belt

  • Yes. I thought I followed his instructions with slight variation for our situation.
  • There are some comments in the end which people have mentioned some other ways. Please read those comments and see if it works for your situation. You can too post there the solution when you get it. It will help others.
    • I didn't see any comments on your blog that would help my situation. But thanks

I have a suggession but sure how much extend it is correct, in the .cfg file i notieced lockPref instead of that change it to jus pref this might help you

   Pref("browser.shell.checkDefaultBrowser", false);
     Pref("browser.startup.homepage_override.mstone", "ignore");
      Pref("browser.rights.3.shown", false);

      Pref("toolkit.telemetry.prompted", 2);
      Pref("toolkit.telemetry.rejected", true)

Answered 07/18/2012 by: ontari.ontari
Black Belt

  • Thanks. I tried that but still got the same error.
  • I read something about profiles from the past. I deleted the whole c:\program files\mozilla firefox folder, as well as the logged user %appdata%...firefox files. Same problem as before

I have tried more things. I encoded the mozilla.cfg file and changed "general.config.obscure_value"1); and my prefs were not applied. I tried putting the full path in "general.config.filename", "c:\program files\mozilla firefox\mozilla.cfg:);. Still nothing. I double checked that mozilla.cfg and the local-settings.js file were in the proper places.

I am just stumped.


Answered 07/25/2012 by: jfrasier
7th Degree Black Belt


I think I have solved it. Either these settings are somehow incompatible with Firefox 12 which is what I was testing, or there was something wrong with my setup.exe.

I downloaded a zip file from http://www.mockbox.net/configmgr-sccm/174-install-and-configure-firefox-silently and made a few changes and ran it and it works fine.



Answered 07/25/2012 by: jfrasier
7th Degree Black Belt

This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ