Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Backup/Restore GNOME Settings With Dconf
#1
Exclamation 
Hey there...

As I work on a GNOME edition of XeroLinux, I had to figure out a way to include my settings by default. Thanks to community members now I know, and am gonna share here if anyone is interested.

Today, we are going to learn how to backup and restore Linux desktop system settings with Dconf tool. This will be useful when you wanted to transfer same system settings after reinstalling your Linux desktop system, without having to manually do them one by one.



- Install Dconf On Linux

Dconf comes pre-installed in many Linux distributions. If it is not installed already, you can install it using the distribution's default package manager depending upon the distribution you use.

$ sudo pacman -S dconf

- Backup And Restore GNOME Settings With Dconf

Believe or not, this is one of the easiest way to backup and restore system settings with a just single command.

To backup your current Linux desktop settings using dconf, do run this command:

$ dconf dump /org/gnome/ > gnome-desktop.conf

The above command will save all customization and tweaks you made in your system, including the pinned applications in the Dock or Unity launcher, desktop panel applets, desktop indicators, your system fonts, GTK themes, Icon themes, monitor resolution, keyboard shortcuts, window button placement, menu and launcher behaviour etc., in a text file named gnome-desktop.conf.

Please note that this command will only backup the system settings. It won’t save settings of other applications that doesn’t use dconf. Also, it won’t backup your personal data either.

You can view this file using any text editors or cat command.

$ cat gnome-desktop.conf

Now reset your desktop settings to the factory defaults with command:

$ dconf reset -f /org/gnome/

After running the above command, your Linux desktop will turn into the old state when you installed it in the first time. Don't panic! Your personal data and installed applications will still be intact.

To restore the System settings, simply do:

$ dconf load /org/gnome/ < gnome-desktop.conf

You can even backup more specific settings like desktop or window manager.

$ dconf dump /org/gnome/desktop/wm/preferences/ > old_wm_settings

Keep the backup file in a safe place to use it later after reinstalling your Linux desktop.

It's that simple!!
~ XeroLinux Toolkit Maintainer ~
I do try to help where I can, when I can.
I do this on my own, so I might not have all the answers.
[Image: K7U76Mv.png]
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Exclamation How To Auto-mount Partitions On Startup Using Gnome Disks DarkXero 3 3,687 01-04-2023, 12:24 AM
Last Post: DarkXero

Forum Jump:


Users browsing this thread: 1 Guest(s)