Trang web này sẽ có chức năng hạn chế trong khi chúng tôi trải qua bảo trì để cải thiện trải nghiệm của bạn. Nếu một bài viết không giải quyết được vấn đề của bạn và bạn muốn đặt câu hỏi, chúng tôi có cộng đồng hỗ trợ của chúng tôi đang chờ để giúp bạn tại @FirefoxSupport trên Twitter và /r/firefox trên Reddit.

Tìm kiếm hỗ trợ

Tránh các lừa đảo về hỗ trợ. Chúng tôi sẽ không bao giờ yêu cầu bạn gọi hoặc nhắn tin đến số điện thoại hoặc chia sẻ thông tin cá nhân. Vui lòng báo cáo hoạt động đáng ngờ bằng cách sử dụng tùy chọn "Báo cáo lạm dụng".

Tìm hiểu thêm

Trying to restore a session within a session from backup file manually

more options

My power died recently, after which I opened Firefox, expecting to be greeted with the about:sessionrestore page but it was just a blank white page for some reason. The tab name still had "about:sessionrestore" but it was just blank, no window to select and restore. I backed up the sessionstore-backups folder and found the session I need to restore (recovery.jsonlz4). I dunno why, when I uncompressed that file, it saved that broken session as well. So the file looks like {Session with broken about:sessionrestore page -> Broken about:sessionrestore tab -> Session I want -> Tabs I want}

Is there any way to manually restore this nested session? I attached some images to help clarify. I don't really know how to work with json files, I'm using a freeware viewer to read the uncompressed session file. Thanks for any help.

My power died recently, after which I opened Firefox, expecting to be greeted with the about:sessionrestore page but it was just a blank white page for some reason. The tab name still had "about:sessionrestore" but it was just blank, no window to select and restore. I backed up the sessionstore-backups folder and found the session I need to restore (recovery.jsonlz4). I dunno why, when I uncompressed that file, it saved that broken session as well. So the file looks like {Session with broken about:sessionrestore page -> Broken about:sessionrestore tab -> Session I want -> Tabs I want} Is there any way to manually restore this nested session? I attached some images to help clarify. I don't really know how to work with json files, I'm using a freeware viewer to read the uncompressed session file. Thanks for any help.
Đính kèm ảnh chụp màn hình

Tất cả các câu trả lời (3)

more options

You may have corrupt sessionstore [v56] sessionstore.jsonlz4 file(s). Delete all sessionstore* files and the sessionstore-backups folder.

Don't delete the files if you need to rescue any data from them, just move them out of the profile folder to some location where Firefox doesn't look for them. You can try to read out their contents using this tool: https://www.jeffersonscher.com/res/scrounger.html


Type about:support<enter> in the address bar.

Under the page logo on the left side, you will see Application Basics. Under this find Profile Folder. To its right press the button Show Folder. This will open your file browser to the current Firefox profile. Now Close Firefox.

Windows: Show Folder; Linux: Open Directory; Mac: Show in Finder

Linux: Under the page logo on the left side, you will see Application Basics. Under this find Profile Directory. To its right press the button Open Directory.

Locate the above file. Then rename or delete it. Restart Firefox.

more options

@FredMcD

I'm not sure you actually read my post completely. I am already past the steps you described. I have the session file backed up already and it is readable. What I want to do is edit the .json file so that FF reads the inner session instead of the corrupted outer layer. Trying to restore it as it currently is makes the blank about:sessionrestore come up every time.

Được chỉnh sửa bởi Typo3000 vào

more options

One of the options on the Scrounger page is to save out the first embedded session found in the JSON. Is that button enabled? If not, perhaps my code isn't detecting it correctly, or maybe due to lack of regular testing it no longer works:


Manual Extraction

If you viewing your JSON file in a Firefox tab, you could switch to the "Raw" view and try running this in the web console (Ctrl+Shift+K). Since I don't have immediate access to a file like yours, I don't know whether it will work:

// First, you need to be in the "Raw" tab of the Fx JSON viewer
// Find the JSON content
var s = document.querySelector('#rawdata-panel div.panelContent pre.data');
// Extact the content and work with it as a JSON object
var s1 = JSON.parse(s.textContent);
// Identify the object property containing the embedded session
var s0 = s1.windows[0].tabs[0].formdata.id.sessionData;
// Pop up a prompt with the JSON text of the embedded session
prompt('Extracted', JSON.stringify(s0));


If the code is very long a prompt window isn't going to be large enough and you may need to dump it out somewhere else.