Configuring Dual Monitors in Linux Mint

Condobloke

Well-Known Member
Joined
Apr 30, 2017
Messages
9,431
Reaction score
7,551
Credits
64,532
Specifically in LM21.3....Cinnamon.....which should also apply easily to LMDE6 and the new LM22 when it gets here.

One Samsung and One Acer Monitor....The Acer connected via hdmi cable, the Samsung connected via vga connector

Altering display settings so that the cursor passes from one monitor to the other, is easy.

Putting another Panel on the second monitor is also easily done

Menu button for the new panel...easy

I will show the icons, which, after much labour and really bad language, I managed to arrange quite some time ago just after LM21 came out.
2024-07-12_12-14.png



2024-07-12_12-14_1.png

There must be an easier way.

Is there a config file or similar that I can copy, and send it to the new install (lmde6 or LM22) by email and then paste it to some appropriate place......to then have the exact same icons on the panels in the new install ? maybe I would need to install the apps first?....
 
Last edited:


@Condobloke
Just an aside from topic.
Thought you'd like to know - I've been running LM 22 Beta on my laptop I take to the mall {while wife walks}.
I'm not a cp wiz or anything near that, but I have had no trouble at all with LM 22.
OG TC
 
AFAIK most DE configurations are stored in your users homedir under $HOME/.config, what you can do is create an archive of your existing $HOME/.config and then extract on your newly installed system.
Code:
cd $HOME
tar -cfv $HOME/back-home-config.tar.gz .config
Save that file to external storage, then when you reinstall your system with Mint 22 you can try extracting that file. By first copying to your home directory of your user.
Code:
cd $HOME
cp /mnt/usb/backup-home-config.tar.gz .
tar -xzf backup-home-config.tar.gz
Then log out and back into your installation and see if you get the desired result. One thing to note is that with a new Cinnamon version configurations may have changed so there is a chance that something might not look or work correctly. If that is the case all you have to do is rename or delete $HOME/.config on your new system, then logout and then log back in.

One thing that could be the case is that icons may have changed but I doubt there will be a lot of big chances going from 21.3 to 22 that would impact your DE configuration, only big thing I heard is that experimental Wayland support will be with the next Cinnamon version.

Just one question. Why do a fresh install, you can easily just upgrade from LM 21.3 to 22 and create a snapshot before hand. The only reason the reinstall would be if you wanted to go from LM to LMDE.
 
Thanks @f33dm3bits, I have not tried it yet, but should get to it before the day ends.

I am doing a fresh install of two OS's....lmde6 and LM22. (I have an instinct to get lmde6 set up properly on its own ssd. The crap that has come from Ubuntu with 24.04 disturbs me)

I want them both to have the same apps and panels set up as I currently have on LM21.3.

The panel set up in the screenshots above took me hours to get right...I cannot remember what I did to bring it to that stage.....it took so long and I clicked and clicked and clicked so many times i lost track of where I was up to !! Eventually it all worked, but I cannot remember the steps !!

I will try your suggestions above later in my day. If it doesnt work or if it manages to screw up the install, there is not a problem, I will just reinstall straight over the top......or I will take a Timeshift snapshot before I start. Not a biggie either way.

Thanks again Maarten.
 
First commands produced the below:

brian@brian-desktop:~$ cd $HOME
brian@brian-desktop:~$ tar -cfv $HOME/back-home-config.tar.gz .config
tar: Removing leading `/' from member names
tar: /home/brian/back-home-config.tar.gz: Cannot stat: No such file or directory
tar: .config/BraveSoftware/Brave-Browser/Profile 1: file changed as we read it
tar: Exiting with failure status due to previous errors
brian@brian-desktop:~$
 
@Condobloke ... a few observations:

Naming the tar file with the suffix tar.gz is misleading if one is just archiving with the tar command since the .gz usually refers to compression by gunzip. One might create the tar file with the .tar suffix, and then separately compress it with a compressing utility like gunzip into the tar.gz file, which would accurately denote the file. Nevertheless, it is possible to archive the directories and compress them in a single step by using the z option e.g.:
tar -zcvf <compressed_tarfile>.tar.gz <directory>
See here:

The problem with using tar to archive the .config directory on a working system is that the files in the .config directory are still being used by the operating system, e.g. for caching, so files are changing whilst tar is trying to archive them which leads to tar baulking.

To keep the ~/.config directory static one can boot into single user mode, or rescue mode, or boot from a live disk and perform the archiving. The compression can be done either simultaneously with the appropriate command or later on the tar file. I guess there are other ways to do all this, but I hope this helps.
 
Naming the tar file with the suffix tar.gz is misleading if one is just archiving with the tar command since the .gz usually refers to compression by gunzip.
I was about to say but now I see that I forgot to a flag, it should have been.
Code:
tar -cfz $HOME/back-home-config.tar.gz .config
Then you get something like this.
Code:
 ile test.tar.gz
test.tar.gz: gzip compressed data
And then this to extract it.
Code:
tar -xzf backup-home-config.tar.gz
But it actually doesn't matter whether it's just a tar or a gzipped tar, the point was for making an archive that you can then extract on other system.

The other option though would be to figure out which files and directories specifically would configure your bar, but I didn't want to spend that much time sorting it out and this seemed like the fastest way to try it to se it it works and the most logical way of doing it since your DE settings are created under your user profile.
The problem with using tar to archive the .config directory on a working system is that the files in the .config directory are still being used by the operating system
To keep the ~/.config directory static one can boot into single user mode, or rescue mode, or boot from a live disk and perform the archiving.
Technically true but all my years of using Linux I have never booted a system in single user mode for creating a tar and I have never had issues with it, that's including server systems. Of course this doesn't mean it can't cause issues.

We could then also ask the question why do backup solutions that do file backups work then because all those type of backup systems do their backups of the files and directories on the filesystem when the system is online, even Timeshift with rsync when not using btrfs?
 
Last edited:
@f33dm3bits
It was the tar output in Condo's post #5 which indicated that there had been a change on the filesystem that tar was targeting:
Code:
tar: .config/BraveSoftware/Brave-Browser/Profile 1: file changed as we read it
Hence the explanation provided in post #6 about this circumstance which can occur and was present in this case.

The suggestion was made in post #6 that there are "other ways to do all this", so other approaches, such as those you suggested, were not being discounted at all.

One alternative approach to minimise the altering of files in the .config directory is to close all the browsers and any other active file activities, and use tar in that context. It can work that way. It can also work, by chance, just by running the tar command too at times without regard to anything else, but it didn't in this case though. The suggestions in post #6 were really ones that almost never fail, hence the mentions.

@f33dm3bits wrote:
all those type of backup systems do their backups of the files on the filesystem when the system is online
The issue is really in the software of the respective programs that are "backing up" or archiving or just copy saving. Those are three different activities. For backing up, a one shot copy may be taken for that moment in time. For copying, a similar one shot copy is taken. The experience in post #5 was different with tar. The tar command takes time to gather up the files, and then checks them for the creation of the archive, so it noticed change, and was concerned enough to let the user know. If the files tar is archiving are static, then one wouldn't expect any issues.
 
Last edited:
I am still getting booted to the kerb....

brian@brian-desktop:~$ tar -cfz $HOME/back-home-config.tar.gz .config
tar: Removing leading `/' from member names
tar: /home/brian/back-home-config.tar.gz: Cannot stat: No such file or directory
tar: Exiting with failure status due to previous errors
brian@brian-desktop:~$
 
I am still getting booted to the kerb....

brian@brian-desktop:~$ tar -cfz $HOME/back-home-config.tar.gz .config
tar: Removing leading `/' from member names
tar: /home/brian/back-home-config.tar.gz: Cannot stat: No such file or directory
tar: Exiting with failure status due to previous errors
brian@brian-desktop:~$
One thing to try is run the tar command from your home directory, e.g.:
Code:
tar -zcvf back-home-config.tar.gz .config
In this case, the compressed tar file would normally be created and deposited in your home directory.

Out of interest, what is the output of:
Code:
echo $HOME
 
It was the tar output in Condo's post #5 which indicated that there had been a change on the filesystem that tar was targeting:
I missed that part, must have not been fully awake yet.

The issue is really in the software of the respective programs that are "backing up" or archiving or just copy saving
I hadn't thought of that but true.
 
brian@brian-desktop:~$ echo $HOME
/home/brian
brian@brian-desktop:~$
 
Running : tar -zcvf back-home-config.tar.gz .config

in the home folder it produces a result so long it would be rejected by the sites "max size" etc etc....anyway to make it more specific?


1720858019634.png
 

Attachments

  • 1720857997769.png
    1720857997769.png
    116.5 KB · Views: 70
I just found his hidden underneath the many and varios folder/files etc ect etc on my desktop....the back-home etc folder is empty

1720858554756.png
 
If I open home, then .cinnamon then configs ....I see this

1720859028587.png

and if I then open configs, i see this
1720859086125.png


is this any help ?
 
@Condobloke it seems that there's a lot there, but there are ways to proceed, and you may not need it all, depending on which configs you wish to copy.

The original query in post #1 was:
Is there a config file or similar that I can copy, and send it to the new install (lmde6 or LM22) by email and then paste it to some appropriate place......to then have the exact same icons on the panels in the new install ? maybe I would need to install the apps first?.

Copying the configs may be possible with a series of tar files rather than one large one. Each tarfile would be small enough so that you don't run into any large file problems. You could look at each directory in the ~/.config directory, determine it's size with a command like:
Code:
du -sh ~/.config/<directory_of_interest>
du -sh ~/.<directory_of_interest>
and use the tar command to make a compressed tarfile of each separate directory for copying over if it's a size that works. It could be a bit tedious, but may achieve the outcome you are after.
 
Last edited:
@Condobloke it seems that there's a lot there, but there are ways to proceed, and you may not need it all, depending on which configs you wish to copy.
I think it would be difficult to figure out which config files exactly would be for that specific desktop configuration.

Copying the configs may be possible with a series of tar files rather than one large one. Each tarfile would be small enough so that you don't run into any large file problems.
Maybe it would first help to check how big the ~/.config directory is and depending on the size just use rsync to sync it to an external driver with enough space instead of using tar?
 
So, to be clear.....in the screen shot immediately above....I select the ones I want and open terminal in those I have selected, and run : tar -zcvf back-home-config.tar.gz .config ......in each of them....like
I opened panel [email protected] ....opened terminal and got this result:
brian@brian-desktop:~/.cinnamon/configs/[email protected]$ du -sh ~/.config/ 32.json
1.7G /home/brian/.config/
4.0K 32.json
brian@brian-desktop:~/.cinnamon/configs/[email protected]$

I just opened panel launchers....which displays :
1720865620456.png
...opened terminal there, ran :
brian@brian-desktop:~/.cinnamon/configs/[email protected]$ tar -zcvf back-home-config.tar.gz .config
tar: .config: Cannot stat: No such file or directory
tar: Exiting with failure status due to previous errors
brian@brian-desktop:~/.cinnamon/configs/[email protected]$

This succeeded in opening a back-home-confog.tar.gz box..:
1720865755993.png
right alongside the 32.json box....and the config.tar box is empty (45 bytes)
 
.cinnamon has properties showing 69.5 MB

when I open .cinnamon and select configs it shows properties of 113 kb

1720866227237.png
 
brian@brian-desktop:~/.cinnamon/configs/[email protected]$ tar -zcvf back-home-config.tar.gz .config
tar: .config: Cannot stat: No such file or directory
tar: Exiting with failure status due to previous errors
brian@brian-desktop:~/.cinnamon/configs/[email protected]$
You need to run that from your homedir dir or use the full path.
Change to home and then run tar command.
Code:
cd ~/
tar -zcvf backup-home.config.tar.gz .conf
Or as one command with the full path.
Code:
tar -zcvf ~/backup-home.config.tar.gz ~/.conf
 

Members online


Top