1 |
Meino.Cramer@×××.de wrote: |
2 |
|
3 |
> Mick <michaelkintzios@×××××.com> [15-08-01 04:28]: |
4 |
> > On Friday 31 Jul 2015 19:19:06 Meino.Cramer@×××.de wrote: |
5 |
> > > Hi, |
6 |
> > > |
7 |
> > > on my tablet PC I used an Android App called "Linux deploy" |
8 |
> > > to install an chroot-environment for - guess - Gentoo. :) |
9 |
> > > |
10 |
> > > The tablet has a SDcard slot and recognizes any FAT32 formatted |
11 |
> > > SDcard automatically. Anything else will silently be ignored. |
12 |
> > > |
13 |
> > > Furthermore Linux deploy uses a single file when it is |
14 |
> > > pointed to an external SDcard (with FAT32) which is mounted |
15 |
> > > via a loop device, formatted ext4, and then populated with |
16 |
> > > the Gentoo Linux files. |
17 |
> > > |
18 |
> > > So far so nice. |
19 |
> > > |
20 |
> > > Unfortunately the file size is limited to 4GB, which is not |
21 |
> > > /that/ much in respect to what I want to install later (Linux |
22 |
> > > deploy goes as far as LXDE runs a terminal and only a few moe |
23 |
> > > things). |
24 |
> > > |
25 |
> > > I created a second file of 4GB and set it up as a "second |
26 |
> > > partition". This is now additional storage capacity of another |
27 |
> > > 4GB. |
28 |
> > > |
29 |
> > > BUT: |
30 |
> > > Linux deploy already installed a full rootfs and more on the first |
31 |
> > > file. And I need to increase the size of _the whole rootfs_ with |
32 |
> > > this extra file ... not only the storage capacity located behind |
33 |
> > > a certain mountpoint. |
34 |
> > > |
35 |
> > > Is there any way to add the capacity of the second file in a way, |
36 |
> > > that the whole rootfs participates from/in/at/of (damn! sorry, I |
37 |
> > > am not good with/at/in/of/from propositions) this? |
38 |
> > > |
39 |
> > > How can I deal with this? |
40 |
> > > |
41 |
> > > Thank you very much in advance for any help! |
42 |
> > > Best regards, |
43 |
> > > Meino |
44 |
> > |
45 |
> > Have you tried mounting it with '-o loop' from your chrooted |
46 |
> > system? However, this won't work unless the chrooted system can |
47 |
> > see the new partition. |
48 |
> > |
49 |
> > -- |
50 |
> > Regards, |
51 |
> > Mick |
52 |
> |
53 |
> Hi Mick, |
54 |
> |
55 |
> yes...my question is a result from that. What I did is (the structure |
56 |
> is an example): |
57 |
> |
58 |
> This is the root of the current image file, which contains the |
59 |
> chroot environment and is mounted via loop by the android OS: |
60 |
> drwxr-xr-x 2 root root 4096 2015-07-25 04:04 bin |
61 |
> drwxr-xr-x 5 root root 1024 2015-07-25 07:42 boot |
62 |
> drwxr-xr-x 3 root root 0 2015-08-01 04:26 config |
63 |
> drwxr-xr-x 18 root root 15640 2015-08-01 04:26 dev |
64 |
> drwxr-xr-x 2 root root 4096 2015-01-11 16:42 doc |
65 |
> drwxr-xr-x 150 root root 12288 2015-07-31 04:01 etc |
66 |
> drwxr-xr-x 5 root root 4096 2014-01-13 05:21 home |
67 |
> lrwxrwxrwx 1 root root 5 2015-03-24 03:10 lib |
68 |
> drwx------ 2 root root 4096 2014-10-08 17:04 lost+found |
69 |
> drwxr-xr-x 3 root root 4096 2014-05-12 03:56 media |
70 |
> drwxr-xr-x 5 root root 4096 2010-11-05 21:07 mnt |
71 |
> drwxr-xr-x 14 root root 4096 2015-07-24 19:34 opt |
72 |
> dr-xr-xr-x 179 root root 0 2015-08-01 04:26 proc |
73 |
> drwx------ 96 root root 12288 2015-08-01 04:56 root |
74 |
> drwxr-xr-x 19 root root 860 2015-08-01 04:28 run |
75 |
> drwxr-xr-x 2 root root 12288 2015-07-28 21:07 sbin |
76 |
> dr-xr-xr-x 12 root root 0 2015-08-01 04:26 sys |
77 |
> drwxrwxrwt 39 root root 4096 2015-08-01 04:58 tmp |
78 |
> drwxr-xr-x 18 root root 4096 2014-09-07 19:09 usr |
79 |
> drwxr-xr-x 14 root root 4096 2015-01-08 08:27 var |
80 |
> |
81 |
> This fs is nearly filled up...not much more space available. |
82 |
> |
83 |
> So I created a second image file, which currently contains |
84 |
> nothing more than 4GB of free space (YEAH!:) |
85 |
> |
86 |
> If I mount this (via loop) to for example to /mnt/ |
87 |
> I will get: |
88 |
> drwxr-xr-x 2 root root 4096 2015-07-25 04:04 bin |
89 |
> drwxr-xr-x 5 root root 1024 2015-07-25 07:42 boot |
90 |
> drwxr-xr-x 3 root root 0 2015-08-01 04:26 config |
91 |
> drwxr-xr-x 18 root root 15640 2015-08-01 04:26 dev |
92 |
> drwxr-xr-x 2 root root 4096 2015-01-11 16:42 doc |
93 |
> drwxr-xr-x 150 root root 12288 2015-07-31 04:01 etc |
94 |
> drwxr-xr-x 5 root root 4096 2014-01-13 05:21 home |
95 |
> lrwxrwxrwx 1 root root 5 2015-03-24 03:10 lib |
96 |
> drwx------ 2 root root 4096 2014-10-08 17:04 lost+found |
97 |
> drwxr-xr-x 3 root root 4096 2014-05-12 03:56 media |
98 |
> drwxr-xr-x 5 root root 4096 2010-11-05 21:07 mnt (behind this |
99 |
> there is 4GB of additional space) drwxr-xr-x 14 root root 4096 |
100 |
> 2015-07-24 19:34 opt dr-xr-xr-x 179 root root 0 2015-08-01 04:26 |
101 |
> proc drwx------ 96 root root 12288 2015-08-01 04:56 root |
102 |
> drwxr-xr-x 19 root root 860 2015-08-01 04:28 run |
103 |
> drwxr-xr-x 2 root root 12288 2015-07-28 21:07 sbin |
104 |
> dr-xr-xr-x 12 root root 0 2015-08-01 04:26 sys |
105 |
> drwxrwxrwt 39 root root 4096 2015-08-01 04:58 tmp |
106 |
> drwxr-xr-x 18 root root 4096 2014-09-07 19:09 usr |
107 |
> drwxr-xr-x 14 root root 4096 2015-01-08 08:27 var |
108 |
> |
109 |
> BUT: The space of the filesystem to which for example updates and new |
110 |
> programs will be installed is not increased by a single byte. |
111 |
> |
112 |
> I need a soultion which add the 4GB space in a way that |
113 |
> the current nearly filled filesystem will get more space as a whole. |
114 |
> |
115 |
> How can I do that? |
116 |
> |
117 |
> Best regards, |
118 |
> Meino |
119 |
|
120 |
It's not exactly what you want, but it should work: |
121 |
|
122 |
Check the size of the directories under /usr with du: |
123 |
|
124 |
du -hs /usr/* |
125 |
|
126 |
Now you can consider which of them you want to move to your free 4GB |
127 |
space. Lets say, you have decided to move /usr/bin/ and /usr/portage/ |
128 |
to the free space that is mounted for example under /mnt/space, then you |
129 |
can do: |
130 |
|
131 |
cp -a /usr/bin/ /usr/portage/ /mnt/space/ |
132 |
mv /usr/bin /usr/bin_backup |
133 |
ln -s /mnt/space/bin/ /usr/bin |
134 |
mv /usr/portage /usr/portage_backup |
135 |
ln -s /mnt/space/portage/ /usr/portage |
136 |
|
137 |
If everything is working as expected you can delete /usr/bin_backup and |
138 |
/usr/portage_backup. |
139 |
|
140 |
Hope that helps. |
141 |
|
142 |
-- |
143 |
Regards |
144 |
wabe |