为提升您的使用体验,本站正在维护,部分功能暂时无法使用。如果本站文章无法解决您的问题,您想要向社区提问的话,请到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 提问,我们的支持社区将会很快回复您的疑问。

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

How to restore tabs using recovery.bak?

  • 4 个回答
  • 6 人有此问题
  • 2 次查看
  • 最后回复者为 Kaos_Dragon

more options

After a power outage while I was asleep, I loaded firefox back up and got the "well this is embarrassing" screen. I scanned the tabs to make sure it was right, and it was my tabs from about a month ago. I went right to the sessionstore-backups folder and copied everything in it to another folder. After peeking in them with notepad, only recovery.bak actually had my previous session.

I've tried renaming it to recovery.js and sessionstore.js while deleting all the others in the backup folder and the main profile folder, but I haven't had any luck yet. Is there anything else I can try?

After a power outage while I was asleep, I loaded firefox back up and got the "well this is embarrassing" screen. I scanned the tabs to make sure it was right, and it was my tabs from about a month ago. I went right to the sessionstore-backups folder and copied everything in it to another folder. After peeking in them with notepad, only recovery.bak actually had my previous session. I've tried renaming it to recovery.js and sessionstore.js while deleting all the others in the backup folder and the main profile folder, but I haven't had any luck yet. Is there anything else I can try?

被采纳的解决方案

jscher2000 said

Probably this is obvious, but did you give Firefox time to fully exit and shut down before removing the latest sessionstore.js, copying in recovery.bak, and renaming recovery.bak to sessionstore.js? Same question with recovery.js if it still exists after a normal shutdown. Plan B would be: Extract the URLs from the old file and click each link to load it manually This is a better approach when you need to examine a number of files and you don't want to lose your current session. One-time Setup: (0) Install the "Session Extractor" bookmarklet (see the instructions in the top bar of the page for how to install it): https://www.jeffersonscher.com/res/sumomarklets.html#SessExtr To Extract the URLs: In the folder where you copied your session history files for safekeeping: (1) Create a copy of the session history file you want to mine for URLs and rename it with a .json extension. For example, right-click the recovery.bak file, choose Copy, then right-click a blank area of the list and choose Paste. Note: By default, Windows hides the .js extension. This is all easier if you can see it. http://windows.microsoft.com/en-us/windows/show-hide-file-name-extensions Right-click > Rename the recovery - Copy.bak file to recovery.json (or recovery.txt if you prefer). (2) Open the recovery.json file in a Firefox tab. Either drag the renamed file and drop it on an existing page to load the json/txt file in its place, or right-click the file and choose Open With and use Firefox. (3) In the tab displaying the session history file, click the bookmarklet button to run the script. This should generate a new page listing the URLs of each open tab from the file. You can select and copy this list and paste it somewhere for safekeeping, and/or you can just use the links now. Unfortunately, if you want to save that page "as is" (as an HTML page), there's an extra step: press Ctrl+U to launch the "view source" page, and save that as a .htm or .html file. For some reason, saving the original page gives you the original session file instead of the formatted list of links.

I didn't have any luck renaming it to get it to work normally, so I did plan B. At first it didn't work. Gave some weird syntax error. So I popped it into a JSON editor and tweaked it a bit until it complied then it worked just fine. It's probably why it wasn't working when I renamed it. So thanks for the help!

定位到答案原位置 👍 0

所有回复 (4)

more options

Probably this is obvious, but did you give Firefox time to fully exit and shut down before removing the latest sessionstore.js, copying in recovery.bak, and renaming recovery.bak to sessionstore.js? Same question with recovery.js if it still exists after a normal shutdown.

Plan B would be:

Extract the URLs from the old file and click each link to load it manually

This is a better approach when you need to examine a number of files and you don't want to lose your current session.

One-time Setup:

(0) Install the "Session Extractor" bookmarklet (see the instructions in the top bar of the page for how to install it):

https://www.jeffersonscher.com/res/sumomarklets.html#SessExtr

To Extract the URLs:

In the folder where you copied your session history files for safekeeping:

(1) Create a copy of the session history file you want to mine for URLs and rename it with a .json extension.

For example, right-click the recovery.bak file, choose Copy, then right-click a blank area of the list and choose Paste.

Note: By default, Windows hides the .js extension. This is all easier if you can see it. http://windows.microsoft.com/en-us/windows/show-hide-file-name-extensions

Right-click > Rename the recovery - Copy.bak file to recovery.json (or recovery.txt if you prefer).

(2) Open the recovery.json file in a Firefox tab. Either drag the renamed file and drop it on an existing page to load the json/txt file in its place, or right-click the file and choose Open With and use Firefox.

(3) In the tab displaying the session history file, click the bookmarklet button to run the script. This should generate a new page listing the URLs of each open tab from the file. You can select and copy this list and paste it somewhere for safekeeping, and/or you can just use the links now.

Unfortunately, if you want to save that page "as is" (as an HTML page), there's an extra step: press Ctrl+U to launch the "view source" page, and save that as a .htm or .html file. For some reason, saving the original page gives you the original session file instead of the formatted list of links.

more options

You probably saw this tip before, but just in case, because Windows hides certain file extensions by default, you'll have the best luck renaming files if you show all extensions: http://windows.microsoft.com/en-us/windows/show-hide-file-name-extensions

more options

Note that you need to copy the recovery.bak file to the main Firefox profile folder and rename the file to sessionstore.js. It is best to first select "Show my windows and tabs from last time" as the startup setting to make Firefox automatically restore all tabs.

more options

选择的解决方案

jscher2000 said

Probably this is obvious, but did you give Firefox time to fully exit and shut down before removing the latest sessionstore.js, copying in recovery.bak, and renaming recovery.bak to sessionstore.js? Same question with recovery.js if it still exists after a normal shutdown. Plan B would be: Extract the URLs from the old file and click each link to load it manually This is a better approach when you need to examine a number of files and you don't want to lose your current session. One-time Setup: (0) Install the "Session Extractor" bookmarklet (see the instructions in the top bar of the page for how to install it): https://www.jeffersonscher.com/res/sumomarklets.html#SessExtr To Extract the URLs: In the folder where you copied your session history files for safekeeping: (1) Create a copy of the session history file you want to mine for URLs and rename it with a .json extension. For example, right-click the recovery.bak file, choose Copy, then right-click a blank area of the list and choose Paste. Note: By default, Windows hides the .js extension. This is all easier if you can see it. http://windows.microsoft.com/en-us/windows/show-hide-file-name-extensions Right-click > Rename the recovery - Copy.bak file to recovery.json (or recovery.txt if you prefer). (2) Open the recovery.json file in a Firefox tab. Either drag the renamed file and drop it on an existing page to load the json/txt file in its place, or right-click the file and choose Open With and use Firefox. (3) In the tab displaying the session history file, click the bookmarklet button to run the script. This should generate a new page listing the URLs of each open tab from the file. You can select and copy this list and paste it somewhere for safekeeping, and/or you can just use the links now. Unfortunately, if you want to save that page "as is" (as an HTML page), there's an extra step: press Ctrl+U to launch the "view source" page, and save that as a .htm or .html file. For some reason, saving the original page gives you the original session file instead of the formatted list of links.

I didn't have any luck renaming it to get it to work normally, so I did plan B. At first it didn't work. Gave some weird syntax error. So I popped it into a JSON editor and tweaked it a bit until it complied then it worked just fine. It's probably why it wasn't working when I renamed it. So thanks for the help!