搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

How do I prevent Firefox from re-opening my last session upon reboot

  • 1 回覆
  • 0 有這個問題
  • 10 次檢視
  • 最近回覆由 cor-el

more options

How do I prevent Firefox from re-opening my last session upon reboot, for example after my laptop dies or I shutdown without closing browser windows? I never never ever want Firefox to restore pages at any time for any reason.

Background: I use firefox for work, and I keep 7 separate firefox windows open to the sites I use to do my job. Because it's a pain opening them every time, I created a shell script (I'm using linux mint 21.1 by the way) to do it. I just double click a desktop icon to launch my shell script and all of my windows open in the order I like them to be in.

Unfortunately, if my laptop battery dies or if I just am in a hurry and I log out without closing everything, then the next time I log in and launch my script, it opens my first firefox window, which then decides to open ALL 7 of the windows that were killed when my laptop shut down, and then my script opens the remaining 6 windows it is supposed to open, for a total of 14 browser windows now open, and I have to close half of them.

What I tried: I googled around and the only thing I could find was the browser.sessionstore.resume_session_once settting, which appears to have no effect whatsoever when I restart (my test was to set this flag to false, open 7 browser windows, restart my machine without closing the browser windows, and then launch my script and the result was 14 browsers open instead of 7).

Version: I'm using Mozilla Firefox for Linux Mint (mint-001 - 1.0) with a Firefox version number of 111.0.

How do I prevent Firefox from re-opening my last session upon reboot, for example after my laptop dies or I shutdown without closing browser windows? I never never ever want Firefox to restore pages at any time for any reason. Background: I use firefox for work, and I keep 7 separate firefox windows open to the sites I use to do my job. Because it's a pain opening them every time, I created a shell script (I'm using linux mint 21.1 by the way) to do it. I just double click a desktop icon to launch my shell script and all of my windows open in the order I like them to be in. Unfortunately, if my laptop battery dies or if I just am in a hurry and I log out without closing everything, then the next time I log in and launch my script, it opens my first firefox window, which then decides to open ALL 7 of the windows that were killed when my laptop shut down, and then my script opens the remaining 6 windows it is supposed to open, for a total of 14 browser windows now open, and I have to close half of them. What I tried: I googled around and the only thing I could find was the browser.sessionstore.resume_session_once settting, which appears to have no effect whatsoever when I restart (my test was to set this flag to false, open 7 browser windows, restart my machine without closing the browser windows, and then launch my script and the result was 14 browsers open instead of 7). Version: I'm using Mozilla Firefox for Linux Mint (mint-001 - 1.0) with a Firefox version number of 111.0.

所有回覆 (1)

more options

You can check this pref on the about:config page.

  • about:config => browser.sessionstore.resuming_after_os_restart = false