1 |
On Mon, Feb 27, 2012 at 3:48 PM, Paul Hartman |
2 |
<paul.hartman+gentoo@×××××.com> wrote: |
3 |
> On Mon, Feb 27, 2012 at 5:30 PM, Mark Knecht <markknecht@×××××.com> wrote: |
4 |
>> On Mon, Feb 27, 2012 at 3:18 PM, Paul Hartman |
5 |
>> <paul.hartman+gentoo@×××××.com> wrote: |
6 |
>>> On Mon, Feb 27, 2012 at 4:49 PM, Nikos Chantziaras <realnc@×××××.de> wrote: |
7 |
>>>> On 28/02/12 00:41, Mark Knecht wrote: |
8 |
>>>>> |
9 |
>>>>> Are there any tools that will: |
10 |
>>>>> |
11 |
>>>>> 1) Ensure that for every installed packages there is a corresponding |
12 |
>>>>> tbz2 file in /usr/portage/packages? |
13 |
>>>>> |
14 |
>>>>> 2) Remove any older versions in /usr/portage/packages prior to me |
15 |
>>>>> running a backup? |
16 |
>>>> |
17 |
>>>> |
18 |
>>>> I think app-portage/gentoolkit can help with its "eclean" tool |
19 |
>>>> (specifically, "eclean-pkg"). |
20 |
>>>> |
21 |
>>>> "man eclean" should get you started. |
22 |
>>> |
23 |
>>> And as an example of savings... I run eclean once in a while, but not |
24 |
>>> automated. I just ran it and got these results: |
25 |
>>> |
26 |
>>> [ 14.8 G ] Total space from 1673 files were freed in the distfiles directory |
27 |
>>> |
28 |
>>> I guess I should use it more frequently. ;) |
29 |
>>> |
30 |
>> |
31 |
>> 15GB is a nice clean up! |
32 |
>> |
33 |
>> I don't think I'd want to run it automatically, at least not often. If |
34 |
>> it automatically deleted things that work in favor of newly built but |
35 |
>> untested packages that would defeat the purpose in my mind. |
36 |
>> |
37 |
>> As basically nothing but a home user I'm trying after 12 years to |
38 |
>> piece together some sort of a backup strategy here, including how to |
39 |
>> do a restore if a drive died, etc. I'll ask some questions about that |
40 |
>> later, but likely it should be it's own thread. |
41 |
>> |
42 |
>> Cheers, |
43 |
>> Mark |
44 |
> |
45 |
> You can probably just exclude /usr/portage from your backup entirely, |
46 |
> since it'll be restored with an emerge --sync (or webrsync) and any |
47 |
> distfiles can be downloaded again if they are needed. |
48 |
> |
49 |
|
50 |
Agreed. |
51 |
|
52 |
My server has about 400GB to back up. Roughly 360GB is virtual |
53 |
machines which get backed up daily already so I have that handled. |
54 |
|
55 |
Of the other 40GB it seems that (excluding portage, /var and a few |
56 |
other things) I need to back up about 24GB which I think can be backed |
57 |
up live. I'm not really worried about restoring the exact state of the |
58 |
machine in one pass. This isn't a business, etc. I just want to get |
59 |
back fairly quickly to where I was before the presumed failure. I |
60 |
figure if I get: |
61 |
|
62 |
/home |
63 |
/boot |
64 |
/usr/src |
65 |
/etc |
66 |
/var/lib/portage |
67 |
|
68 |
and maybe one or two more, then a restore would hopefully be something |
69 |
like doing a quick install as per the Gentoo docs and then laying this |
70 |
stuff on top and doing an emerge -ke @world. |
71 |
|
72 |
Or at least that's what I'm trying to puzzle together. |
73 |
|
74 |
I'm planning on trying it with an additional hard drive as a test. |
75 |
I'll have to modify fstab as the main system is a 5 drive RAID6 |
76 |
monster and for testing I just want a single drive to verify that it |
77 |
works. |
78 |
|
79 |
QUESTION: As for ensuring that every package actually has a |
80 |
corresponding tbz2 file in the packages directory, would |
81 |
|
82 |
emerge -ek @world |
83 |
|
84 |
install everything from packages except in the case of something not |
85 |
existing in which case it would build and store it? |
86 |
|
87 |
Thanks, |
88 |
Mark |