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

Issue 5122002: installer: fix the "umount: XXX not mounted" error message during postinst (Closed)

Created:
10 years, 1 month ago by Hung-Te
Modified:
9 years, 7 months ago
Reviewers:
Will Drewry
CC:
chromium-os-reviews_chromium.org
Visibility:
Public.

Description

installer: fix the "umount: XXX not mounted" error message during postinst When cleaning loop devices, it may be not always mounted. This CL makes it allowing an extra parameter to specify any additional steps to be performed before releasing a loop device. BUG=chromium-os:9278 TEST=Build an USB image with this change, and then /usr/sbin/chromeos-install Before: Seeing "umount: /dev/loop2: not mounted" and "umount: /dev/loop3: not mounted" in output messages After: No error message. Also verified "sudo losetup -a" does not leave any resources mounted. Change-Id: I10dfa08b037bb11bd821754f32a7a39c155fe445 Committed: http://chrome-svn/viewvc/chromeos?view=rev&revision=8bb0de1

Patch Set 1 #

Total comments: 2

Patch Set 2 : Refine param semantic #

Total comments: 2

Patch Set 3 : change FLAGS_TRUE compare from '=' to '-eq' #

Patch Set 4 : add sync for losetup -d after mkfs.ext3 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+17 lines, -6 lines) Patch
M chromeos-install View 1 chunk +3 lines, -0 lines 0 comments Download
M chromeos-setimage View 1 2 3 1 chunk +14 lines, -6 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Hung-Te
10 years, 1 month ago (2010-11-17 10:02:44 UTC) #1
Will Drewry
Looks ok to me with the given question. However, I wonder if it'd make sense ...
10 years, 1 month ago (2010-11-18 09:20:15 UTC) #2
Hung-Te
Looking at /proc/mount seems not a really good idea because we don't know if the ...
10 years, 1 month ago (2010-11-18 09:49:02 UTC) #3
Will Drewry
LGTM with the comparison nit. Thanks! http://codereview.chromium.org/5122002/diff/5001/chromeos-setimage File chromeos-setimage (right): http://codereview.chromium.org/5122002/diff/5001/chromeos-setimage#newcode123 chromeos-setimage:123: if [ "$need_umount" ...
10 years, 1 month ago (2010-11-23 01:36:48 UTC) #4
Hung-Te
10 years, 1 month ago (2010-11-23 02:14:52 UTC) #5
http://codereview.chromium.org/5122002/diff/5001/chromeos-setimage
File chromeos-setimage (right):

http://codereview.chromium.org/5122002/diff/5001/chromeos-setimage#newcode123
chromeos-setimage:123: if [ "$need_umount" = ${FLAGS_TRUE} ]; then
On 2010/11/23 01:36:50, Will Drewry wrote:
> nit: FLAGS_TRUE/FALSE is normally checked with -eq and not using a string
> equality, though it should be equivalent.

Done.

Powered by Google App Engine
This is Rietveld 408576698