View previous topic :: View next topic |
Author |
Message |
gangstervano n00b
Joined: 15 Aug 2016 Posts: 74
|
Posted: Sat Sep 24, 2016 2:46 pm Post subject: Ccache backup restore |
|
|
Hi!
Can I somehow make a backup ccache data and then restore it?
Let's create a tar arhih folder /var/tmp/ccache?
Backup and recovery is expected on the same PC. |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 21724
|
Posted: Sat Sep 24, 2016 3:16 pm Post subject: |
|
|
You could, but why do you need to? Caches are expected to store only results that can be regenerated if the cache is cleared. Path /var/tmp/ccache is where object files from Portage builds are stored. You probably do not need to preserve those. |
|
Back to top |
|
|
gangstervano n00b
Joined: 15 Aug 2016 Posts: 74
|
Posted: Sat Sep 24, 2016 5:10 pm Post subject: |
|
|
Hu, thank you for your reply
This is in order not to carry out a full compilation, when you restore old disk image with gentoo.
For example, I restore an image that does not have some of the programs.
These programs have already been compiled.
I restores ccache. Then compile program. As a result, I quickly regained the program that were not on the disk image.
I did not understand Is there enough to save the folder /var/tmp/ccache or not?
Excuse me for my english |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 21724
|
Posted: Sat Sep 24, 2016 5:19 pm Post subject: |
|
|
Would it not be better to backup and restore the programs themselves, rather than some of the objects used in the program? |
|
Back to top |
|
|
gangstervano n00b
Joined: 15 Aug 2016 Posts: 74
|
Posted: Sat Sep 24, 2016 5:23 pm Post subject: |
|
|
The folder takes up less space and is more versatile. Besides, I do not know exactly what I want to restore the program, and which are not.
Besides, for me it is too difficult to understand how to save separate program.
Last edited by gangstervano on Sat Sep 24, 2016 5:26 pm; edited 1 time in total |
|
Back to top |
|
|
Logicien Veteran
Joined: 16 Sep 2005 Posts: 1555 Location: Montréal
|
Posted: Sat Sep 24, 2016 5:23 pm Post subject: |
|
|
To use a ccache image who was created in the pass with your today system, you need the same system configuration today than in the past. For example, if the Gcc version in the past is lower than today, or Emerge version and/or configuration is different, I would not use such an image.
In all situations, I would not use a ccache backup image. Maybe ccache would just overwrite the data but, not using a ccache backup is a source less of problem causes to think of when come the time to debug something. _________________ Paul |
|
Back to top |
|
|
gangstervano n00b
Joined: 15 Aug 2016 Posts: 74
|
Posted: Sat Sep 24, 2016 5:31 pm Post subject: |
|
|
I assume that the configuration will be the same.
I have a script that saves all the configuration files that I have changed.
Versions of gcc also remain the same.
On this basis there may save and then restore ccache?
I'm realizing that it's some risk. |
|
Back to top |
|
|
Logicien Veteran
Joined: 16 Sep 2005 Posts: 1555 Location: Montréal
|
Posted: Sat Sep 24, 2016 5:45 pm Post subject: |
|
|
I use ccache. I have read somewhere that Ccache and be a source of compilation fails or someting like this. I need to search the forum to retrace the thread. Everything compile fine on my side with Ccache for the moment. _________________ Paul |
|
Back to top |
|
|
gangstervano n00b
Joined: 15 Aug 2016 Posts: 74
|
Posted: Sat Sep 24, 2016 5:55 pm Post subject: |
|
|
What ccahe can cause problems written in the handbook and I know it.
The question is whether there is the ability to save data ccache?
And followed by reduction them with the "ideal" conditions. |
|
Back to top |
|
|
|