Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(69)

Issue 3562001: AU: Use full rootfs partition for scratch. (Closed)

Created:
10 years, 2 months ago by petkov
Modified:
9 years, 7 months ago
Reviewers:
Will Drewry, adlr
CC:
chromium-os-reviews_chromium.org, adlr
Visibility:
Public.

Description

AU: Use full rootfs partition for scratch. This patch allows the delta generator to use blocks beyond rootfs up to the full rootfs partition as scratch. This is really a stop gap solution. The updater needs to be fixed to work with as little as one block of scratch if necessary. BUG=6531 TEST=unit tests, generated a delta payload and updated from 70.8 to 72.3 Change-Id: I52b7d04d5a5345c34c9c647f9878c836be9f489c Committed: http://chrome-svn/viewvc/chromeos?view=rev&revision=c0b7a53

Patch Set 1 #

Total comments: 9
Unified diffs Side-by-side diffs Delta from patch set Stats (+23 lines, -17 lines) Patch
M delta_diff_generator.cc View 4 chunks +23 lines, -17 lines 9 comments Download

Messages

Total messages: 9 (0 generated)
petkov
10 years, 2 months ago (2010-09-28 23:15:47 UTC) #1
Will Drewry
Some questions/comments for my edification, but right now the fact the test passes is a ...
10 years, 2 months ago (2010-09-29 01:10:43 UTC) #2
petkov
http://codereview.chromium.org/3562001/diff/1/2 File delta_diff_generator.cc (right): http://codereview.chromium.org/3562001/diff/1/2#newcode43 delta_diff_generator.cc:43: const size_t kRootFSPartitionSize = 1 * 1024 * 1024 ...
10 years, 2 months ago (2010-09-29 04:27:40 UTC) #3
Will Drewry
http://codereview.chromium.org/3562001/diff/1/2 File delta_diff_generator.cc (right): http://codereview.chromium.org/3562001/diff/1/2#newcode43 delta_diff_generator.cc:43: const size_t kRootFSPartitionSize = 1 * 1024 * 1024 ...
10 years, 2 months ago (2010-09-29 04:33:41 UTC) #4
petkov
On 2010/09/29 04:33:41, Will Drewry wrote: > http://codereview.chromium.org/3562001/diff/1/2 > File delta_diff_generator.cc (right): > > http://codereview.chromium.org/3562001/diff/1/2#newcode43 ...
10 years, 2 months ago (2010-09-29 04:37:59 UTC) #5
petkov
http://codereview.chromium.org/3562001/diff/1/2 File delta_diff_generator.cc (right): http://codereview.chromium.org/3562001/diff/1/2#newcode43 delta_diff_generator.cc:43: const size_t kRootFSPartitionSize = 1 * 1024 * 1024 ...
10 years, 2 months ago (2010-09-29 16:17:36 UTC) #6
petkov
Will, so does this LGTY?
10 years, 2 months ago (2010-09-29 18:22:58 UTC) #7
Will Drewry
LGTM Please drop in a bug about the hard-coded root partition size. We need to ...
10 years, 2 months ago (2010-09-29 19:07:35 UTC) #8
petkov
10 years, 2 months ago (2010-09-29 19:44:35 UTC) #9
http://codereview.chromium.org/3562001/diff/1/2
File delta_diff_generator.cc (right):

http://codereview.chromium.org/3562001/diff/1/2#newcode43
delta_diff_generator.cc:43: const size_t kRootFSPartitionSize = 1 * 1024 * 1024
* 1024;  // 1 GiB
On 2010/09/29 19:07:36, Will Drewry wrote:
> On 2010/09/29 16:17:36, petkov wrote:
> > On 2010/09/29 04:33:41, Will Drewry wrote:
> > > On 2010/09/29 04:27:40, petkov wrote:
> > > > On 2010/09/29 01:10:47, Will Drewry wrote:
> > > > > Any chance you could open(tgt), ioctl(BLKGETSIZE64) and use that
number?
> > (Or
> > > > > fstat if the ioctl fails)?
> > > > 
> > > > I don't think I can do this -- this is running on the server on a .bin
> image
> > > > file. I.e., I don't think the actual partition size is available. Right?
> > > 
> > > Hrm the size is definitely available in the gpt table of the .bin and if a
> > loop
> > > device is provided, it may also be configured with the size. 
> > 
> > $ cgpt show chromiumos_base_image.bin | fgrep ROOT-A
> >      36864   1490944       3  Label: "ROOT-A"
> > 
> > 1490944 blocks is 763363328 bytes, which is the actual rootfs size, rather
> than
> > the rootfs partition size on the device.
> > 
> > On the actual device:
> > 
> > # cgpt show /dev/sda | fgrep ROOT-A 
> >   13549568   2097152       3  Label: "ROOT-A"
> > 
> > Is there any other place I can get the partition size from on the server?
> > 
> > > 
> > > Is it safe to assume there's no cgpt linkage in there already?
> > > 
> > > Also, is this a server-side decision or a decision that happens during
> > > install/apply, or both?  If it is the former, we could just add a cmdline
> arg
> > > for the rootfs size :)
> > 
> > 
> 
> It being hard-coded in the installer means we get forced into hard coding it
> here. Ugh.

crosbug/7181 filed.

Powered by Google App Engine
This is Rietveld 408576698