Firefox keeps restoring session, I tried everything.
Hello.
I use 76.0.1 (64-bit) on Xubuntu 20.04 and same thing happens on every computer. After clean system shutdown or restart, Firefox keeps restoring tabs I used. This never happens if I close Firefox first. Also this never happens when I close and reopen firefox in the same session. I tried everything: - obvious "Restore previous session" restore in options - about:config turning various options: browser.sessionstore.resume_from_crash browser.sessionstore.restore_tabs_lazily browser.sessionstore.resuming_after_os_restart browser.sessionstore.max_tabs_undo browser.sessionstore.restore_on_demand privacy.clearOnShutdown.sessions - i even created "user.json" with restore line as someone suggested None of these measures helped. I thought that It may be connected to XFCE session store somehow, so I went through disabling that too - no change. No other program happens to do the same. After reboot, when someone starts Firefox, all my tabs from previous session are reopened instantly. This happens on my both Xubuntu workstations, but never happens on my Windows computers. Please help.
Alle svar (4)
Are you shutting down the computer without closing the programs first? Not good, Not good.
Programs need to be properly shut down because many programs are opening and changing files.
Closing those programs first is a must so that they can close any open files.
Also, you are risking corrupting such files.
Why not? When you choose shutdown from menu, or (since 2000s) when power button is hit, computer shutdowns safely every program, service or filesystem and only than powers off. It even stops when any unsaved documents are open. I'd be ridiculous to jump every open program and tab to close them. Problem is in my configuration, some strange bug or unwanted feature, not in a way I close the system. Just to be clear I DO NOT unplug the cord or something like that - but even than - I do not need someone after me to see my Firefox session. Question is still open.
Create a new profile as a test to check if your current profile is causing the problems.
See "Creating a profile":
https://support.mozilla.org/kb/profile-manager-create-and-remove-firefox-profiles http://kb.mozillazine.org/Standard_diagnostic_-_Firefox#Profile_issues
If the new profile works then you can transfer some files from the old profile to that new profile, but be careful not to copy corrupted files.
http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox
You can also try to reset Firefox:
https://support.mozilla.org/kb/Basic+Troubleshooting
A couple of months ago another Linux user mentioned this. Eventually we discovered some code in Firefox which detects when it is quitting due to an "os-restart" --
https://searchfox.org/mozilla-release/source/browser/components/sessionstore/SessionStore.jsm#2327
-- and in that situation, Firefox sets a flag in the profile to automatically restore the previous session on the next Firefox startup.
At least, that's what it looks like. I didn't research it further.