Cannot make a chroot, build, etc.

274 views
Skip to first unread message

Simon Glass

unread,
May 16, 2012, 12:21:04 AM5/16/12
to Chromium OS dev
Hi,

I hit problems where I cannot produce working binaries, so decided to try removing my chroot.

I'm sure I missed a PSA somewhere, since I seem to be the only one with problems. Any pointers please?

Regards,
Simon

cosarm> cros_sdk --delete
INFO    cros_sdk: Cleaning up old mount points...
INFO    cros_sdk: Deleting /c/cosarm/chroot...
INFO    cros_sdk: Done.
cosarm> cros_sdk

INFO    cros_sdk: Unpacking STAGE3...
INFO    cros_sdk: Set timezone...
INFO    cros_sdk: Adding user/group...

INFO    cros_sdk: Setting up mounts...
find: `/c/cosarm/chroot/etc/resolv.conf': No such file or directory
find: `/c/cosarm/chroot/dev/shm': No such file or directory
INFO    cros_sdk: Running init_setup()...
INFO    cros_sdk: Setting up hosts/resolv...
INFO    cros_sdk: Setting up /etc/make.*...
INFO    cros_sdk: Running post-inst configuration hacks
find: `/c/cosarm/chroot/dev/shm': No such file or directory
ln: creating symbolic link `/c/cosarm/chroot/home/sjg/.boto': File exists
!!! Invalid PORTDIR_OVERLAY (not a dir): '/usr/portage'
!!! main-repo not set in DEFAULT and PORTDIR is empty. 
>>> Regenerating /etc/ld.so.cache...
find: `/c/cosarm/chroot/dev/shm': No such file or directory
ln: creating symbolic link `/c/cosarm/chroot/home/sjg/.boto': File exists
ls: cannot access /usr/local/portage/chromiumos/profiles/default/linux/amd64/10.0: No such file or directory
lrwxrwxrwx 1 root root 87 2012-05-15 19:14 /etc/make.conf -> /home/sjg/trunk/src/third_party/chromiumos-overlay/chromeos/config/make.conf.amd64-host
lrwxrwxrwx 1 root root 63 2012-05-15 19:14 /etc/make.profile -> /usr/local/portage/chromiumos/profiles/default/linux/amd64/10.0
Running ['/c/cosarm/src/scripts/sdk_lib/make_chroot.sh', '--stage3_path', '/c/cosarm/sdks/cros-sdk-15.05.12.122012.tbz2', '--chroot', '/c/cosarm/chroot'] failed!
1 cosarm> cros_sdk
find: `/c/cosarm/chroot/dev/shm': No such file or directory
ln: creating symbolic link `/c/cosarm/chroot/home/sjg/.boto': File exists
-bash: /dev/null: Permission denied
-bash: /dev/null: Permission denied
-bash: /dev/null: Permission denied
-bash: /dev/null: Permission denied
sjg@sglass ~ $ 



Mike Frysinger

unread,
May 16, 2012, 1:15:55 AM5/16/12
to Simon Glass, Chromium OS dev
On Wed, May 16, 2012 at 12:21 AM, Simon Glass <s...@chromium.org> wrote:
> find: `/c/cosarm/chroot/dev/shm': No such file or directory

does your system have a /dev/shm ?
-mike

Mike Frysinger

unread,
May 16, 2012, 2:13:29 PM5/16/12
to Simon Glass, Chromium OS dev
fwiw, i just tried it on my goobuntu system and it worked ...
-mike

David James

unread,
May 16, 2012, 3:48:22 PM5/16/12
to Simon Glass, Chromium OS dev, Zdenek Behan
This problem occurs when your mount cache is out of date. One
workaround is to rename your build directory or reboot the machine.

The real fix is to update enter_chroot.sh to use /proc/mounts instead of
mount. Something like this: http://pastebin.com/EQ62iAWX

David Hendrix ran into the same problem and the above change fixed it locally.

Cheers,

David

Mike Frysinger

unread,
May 16, 2012, 4:01:12 PM5/16/12
to David James, Simon Glass, Chromium OS dev, Zdenek Behan
i'm not sure that's entirely safe ... the "on" match was helping
anchor to the 3rd position in the mount output. we'll have to tweak
the match slightly to make it work with /proc/mounts.

maybe something like:
MOUNT_CACHE=$(awk '{print $2}' /proc/mounts)

and then:
case " ${MOUNT_CACHE} " in
*" ${mounted_path} "*)
# Already mounted!
;;

i'll post a CL for it
-mike

Brian Harring

unread,
May 16, 2012, 5:35:07 PM5/16/12
to Mike Frysinger, David James, Simon Glass, Chromium OS dev, Zdenek Behan
That code needs to be moved out of crosutils and into cros_sdk anyways (I've been agitating for that for a while).

Any takers?
~harring


--
Chromium OS Developers mailing list: chromiu...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-os-dev?hl=en

Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages