In case you are a Snap Firefox person, you would possibly discover that your profile data isn’t within the traditional place. Why is that this? The Snap launch of Firefox doesn’t work together with the folder that Mozilla Firefox often creates on Linux to handle profiles. The explanation for that is that Snaps are sandboxed purposes. They can’t work together with each a part of the file system and are made to self-contain themselves.
Back up Firefox Snap settings
If you happen to’re a Snap Firefox person, your profile data is saved inside the ~/snap/firefox
listing. To make a backup of this profile data, begin by opening up a terminal window by urgent Ctrl + Alt + T or Ctrl + Shift + T on the keyboard. Then, observe the step-by-step directions outlined under.
Step 1: Utilizing the terminal window, CD into the ~/snap
listing. This listing resides in your house folder and holds all Snap-related configuration information. You want to be on this listing to make a backup of your Firefox profile data.
cd ~/snap
Step 2: As soon as inside the ~/snap
listing, run the ls command. The ls command will enable you to check out what’s inside the folder you’re presently in. We’d like to decide if there’s a firefox folder inside ~/snap
.
ls
Do you may have too many sub-folders within the ~/snap
listing? Run the ls command alongside grep to filter out precisely what you want.
ls | grep firefox
If you don’t see the firefox folder seem after working the ls command, the Snap launch of Firefox is both not put in, or is just not working accurately. Please take the time to re-install the Firefox Snap, and register to your Firefox account to set up a profile.
Step 3: After confirming that there’s a firefox folder within the ~/snap
listing, the backup can start. Utilizing the tar command, create a TarGZ archive of the folder. Remember that when creating this archive, compression can take time. Be affected person!
Word: be certain to shut the Firefox app on your system earlier than making an attempt to create a backup. If the browser is working, there may very well be short-term information being created that might mess with the compression course of.
tar -czvf my-firefox-backup.tar.gz firefox
Step 4: When the backup is full, you may take the backup file and add it to Dropbox, Google Drive, or place it on a USB flash drive or USB laborious drive. Nonetheless, doing so is irresponsible, as it isn’t encrypted. Because of this, we are going to now go over how to encrypt your backup.
Encrypt backup
To encrypt your backup, use the next gpg command under in a terminal window. Make certain to use a safe, memorable password! A weak password is simple to guess and can render your encryption ineffective.
gpg -c my-firefox-backup.tar.gz
The encryption is full. Delete the unencrypted backup from the ~/snap
folder as it’s not wanted. To delete, run the rm command under.
rm my-firefox-backup.tar.gz
Place the encrypted GPG backup file within the residence listing (~) with the mv command.
mv my-firefox-backup.tar.gz.gpg ~/
As soon as the GPG backup file is within the residence listing, take it and retailer it in a secure location!
Restoring the backup
Restoring your Firefox Snap backup could be very simple. All that you just want to do is decrypt the backup and extract the contents of the TarGZ archive to the ~/snap
folder. To start out the restoration course of, open up a terminal window and observe the step-by-step directions down under.
Word: the Firefox Snap app should be closed through the backup restoration course of!
Step 1: Utilizing the CD command, transfer the terminal session from your property listing to the ~/snap
folder.
cd ~/snap
Step 2: Inside the ~/snap
folder, you will want to delete the prevailing Firefox folder. To delete the prevailing Firefox folder, make use of the rm command under.
rm -rf firefox
Step 3: After deleting the firefox folder, transfer the encrypted backup file to the house listing. Then, decrypt it utilizing the gpg command.
gpg my-firefox-backup.tar.gz.gpg
The decryption ought to solely take a few seconds. When the decryption course of is full, you will notice my-firefox-backup.tar.gz within the residence listing.
Step 4: As soon as the Firefox backup is decrypted, you should transfer the unencrypted backup into the ~/snap
folder. Utilizing the mv command under, place the unencrypted Firefox backup archive in ~/snap
.
mv my-firefox-backup.tar.gz ~/snap
Step 5: Decompress the Firefox backup utilizing the tar xvf command.
tar xvf my-firefox-backup.tar.gz
When the backup is decompressed, your Firefox Snap’s profile data will probably be restored. Be happy to open up Firefox and use it! Nonetheless, bear in mind to run the rm ~/snap/my-firefox-backup.tar.gz command to delete the unencrypted backup file, as somebody may acquire entry to your profile data!