Mozilla サポートの検索

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

詳しく学ぶ

Best practices for system backups?

  • 2 件の返信
  • 0 人がこの問題に困っています
  • 最後の返信者: 𝖘𝖈𝖆𝖗

more options

I'm taking nightly incremental backups of /home for example to my home storage server and, I guess, due to the databases Firefox uses for various storage, those can't be backed up by just copying them, if Firefox is running and has the database open.

What are the best practices, then, for ensuring all profile data, including these databases, is in a state where it can be backed up, while Firefox is running, in a way it can be restored to a fully functioning profile?

For example, with MySQL databases, you can dump the log before running the backup each night, which basically exports the SQL statements needed so you can skip backing up the actual binary database file (like ibdata1).  Does SQLite need something similar?  and is this the only special consideration that is needed, or are there other specialized types of data within our profile directories that can't be backed up by simply copying the data while Firefox is running?

Thanks

I'm taking nightly incremental backups of /home for example to my home storage server and, I guess, due to the databases Firefox uses for various storage, those can't be backed up by just copying them, if Firefox is running and has the database open. What are the best practices, then, for ensuring all profile data, including these databases, is in a state where it can be backed up, while Firefox is running, in a way it can be restored to a fully functioning profile? For example, with MySQL databases, you can dump the log before running the backup each night, which basically exports the SQL statements needed so you can skip backing up the actual binary database file (like ibdata1).  Does SQLite need something similar?  and is this the only special consideration that is needed, or are there other specialized types of data within our profile directories that can't be backed up by simply copying the data while Firefox is running? Thanks

すべての返信 (2)

more options

I've always just copied mine and the copies have worked fine when copied back.

役に立ちましたか?

more options

Yes, well, that has typically worked in the past, but not so much anymore with these fancy databases.  I didn't even need a backup, I just copied my profile folder over to the new computer.  Thing is, places.sqlite was secretly corrupted at some point but I was never alerted to this. Everything has appeared and worked fine, my history is all viewable in the old Firefox, nightly backups have been successful, and so on.

Yet, only 12 history items found?  Then upon checking integrity in about:profiles the truth was revealed, it was a complete mess. Also tried Firefox Sync, same thing only 12 entries synced.  I finally had success with Skyweb's History Export add-on, it was able to grab over 138,000 records and export to json which i was able to import into this new computer.

For databases, in general, it's a bad practice to just plain file copy them while they're still open.  Yes, if it's got little to no usage when the copy is performed, you can get lucky and not have issues with restoration. But with these one like places.sqlite that stores all kinds of things besides history, there's no telling when a transaction might be written. The databases have to be backed up in special ways.

Now I'm reading more about different ways that can be executed before my nightly backup runs: .clone, .dump, .backup.  An app called Litestream looks to be the best, it looks like it can dump incremental backups of sqlite database which can then be included in nightly system/home incremental backups... will keep reading.

役に立ちましたか?

質問する

投稿に返信するには あなたのアカウントにログイン する必要があります。まだアカウントをお持ちでなければ、新しい質問を開始 してください。