Tuesday, December 20, 2022

backing up Stellarium - Ubuntu

Here are backup/restore notes for Stellarium on Linux.

The purpose of this document is to help anyone know where custom user data is stored by the Stellarium program. This can helpful in a variety scenarios such as reinstating data after a clean install or transferring to a different computer.

It's too bad we can't just backup everything in the .stellarium folder. That'd be quick and easy but that would backup the large star catalogue files and other unnecessary files.

Testing was performed on a Surface Book (first generation) laptop running Ubuntu. Stellarium version 1.1 used. 

The Ubuntu testing was under a "snap" configuration. This impacted the directory structure for the storage of the various user configuration files.

Note, a directory with a leading period is hidden. You'll need to enable the display of hidden files and folders in the file manager app.


scenario - uninstalling/reinstalling

Perhaps we are doing a refresh. Or transferring to a new computer. There's an assumption we're using the same version or near to the same version.


* landscapes

Custom user landscapes for background, surroundings. A landscape profile is made up of one or several image files (PNG) plus a text initialisation (INI) file.

Don't back up the "stock" landscape files from the Stellarium website.



Within the "landscapes" folder there will be subfolders, e.g. "my yard" or "Mew Lake campground," one for each of the added landscape profiles.

Each landscape profile has an INI file and PNG image files.


* customisations to SSO objects

If you have added a great number of comets and asteroids to Stellarium, you'll want to back up the key file for convenience.






* star catalogues loaded

Do not backup the catalogue files proper as they are too large. And they are downloaded from a Stellarium repository. 

Record the file with the highest catalogue number. Then, inside Stellarium, you can load in the necessary catalogues.

Remember to offset given the first catalogue file Stellarium uses has the number 0 (zero).  






The "stars" file shown here means the catalogue file number 5 has been added. In other words, file number 5 is the 6th catalogue loaded.

The system generated "stars config" file indicates which catalogues are active. 

None of the files in the \stars folder need to be saved... 

* general settings and preferences

Active buttons in the horizontal toolbar, Sky & View settings, fonts, line colours, FOV, direction at start-up... all the user settings or user preferences are recorded in the general configuration file for Stellarium program.





* mount config

As managed by the Telescope Control plug-in. For each mount profile, the driver, the communications port, etc.






The "device models" system-generated file is the "standard" drivers. It does not need to be backed up.

The "telescopes" file is critical and has all custom mount information.

* custom equipment

All the data in the oculars module of Stellarium is saved in one file. So all your custom eyepieces, telescopes, camera lenses, cameras, sensors, magnifiers, etc. and their parameters can be easily backed up. The user settings for the oculars tool itself, such as mask transparency, is captured. 





* custom locations

Back up your custom locations or different observing sites.





* observing lists

Backup your custom observing lists (formerly bookmark lists) e.g. "tonight's campaign 6 Dec 2022." 





* a backup plan

This listing shows that there are a handful of files to backup to safeguard one's custom data and the application's settings. 

Assuming you use these features in Stellarium, the files (with rather obvious names) to back up are:

  • custom landscape directories (with the image and INI files)
  • ssystem_minor.ini 
  • config.ini for the general preferences
  • telescopes.json
  • ocular.ini
  • user_locations.txt
  • observingList.json

And make a note of the highest star catalogue loaded.

It's pretty easy to jump into file manager tool and copy the individual files somewhere for safe keeping. You could script the process to do it frequently and quickly.

* the restore

A restoration process was attempted as part of this test, meaning:

  1. the user data was backed up/copied
  2. the Stellarium software was uninstalled with the option to remove all user data
  3. the software (same version) was reinstalled, i.e. "clean install"
  4. the program was launched and examined, where it was observed that no custom settings were preserved, there were no custom locations, landscapes, observing lists, solar system objects, custom oculars, etc.
  5. the program was shut down
  6. the user data was reinstated to the specific folders
  7. Stellarium was launched and examined, where it was noted that all the customisations were back! 
  8. the missing star catalogues were loaded

* summary

It is quite easy and quick to manually backup the handful of files in Linux, as needed, to protect for customised, personalised data in Stellarium and one's preferences for the appearance and operation of the software.

No comments: