Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 8101 - patch breaks portage && /dev/null problem
Summary: patch breaks portage && /dev/null problem
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Daniel Robbins (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-09-19 05:54 UTC by phoen][x
Modified: 2011-10-30 22:17 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description phoen][x 2002-09-19 05:54:23 UTC
Hey devs, 

a colleague of mine wanted to build gentoo 1.4_rc1 from strage3, but he was
unable to do that because of this very weird error. First of all i should
mention that he installs gentoo on a seperate ext3 partition, using mandrake as
a hostsystem.

Installation procedure so far:
1) grabbed the pentium3 stage3 from ibiblio
2) unpacked the stage3 to /mnt/gentoo
3) modified /mnt/gentoo/etc/wget/wgetrc for proxy settings
4) grabbed the latest portage snapshot from ibiblio
5) unpacked that to /mnt/gentoo/usr
6) chroot, env-update, source /etc/profile
7) set the timezone
8) "emerge gentoo-sources"

emerge downloaded the sources just fine, but it broke after that:
# emerge gentoo-sources
[...]
>>> md5 ;-) linux-2.4.19.tar.bz2
>>> md5 ;-) patches-2.4.19-gentoo-r9.tar.bz2
/usr/sbin/ebuild.sh: /dev/null: Permission denied
/usr/sbin/ebuild.sh: /dev/null: Permission denied
>>> Unpacking source...
>>> Unpacking linux-2.4.19.tar.bz2
>>> Unpacking patches-2.4.19-gentoo-r9.tar.bz2
Current kernel version is 2.4.19
Scanning patch directory: '.'
Checking 00_O1-scheduler (plain text format)... patch: **** Can't create file
/root/tmp/ppz5SF1w : Permission denied
cat: write error: Broken pipe
can't be applied.  Please modify the patch.
patch: **** Can't create file /root/tmp/po3rvBaf : Permission denied

!!! ERROR: The ebuild did not complete successfully.
!!! Function src_unpack, Line -78, Exitcode 2
!!! (no error message)

First of all, /dev/null is not writable from inside the chroot. Really weird.
You can't even "echo" stuff into it. So we ran the following commands in a
normal, non-chrooted environment:
# ll /mnt/gentoo/dev/null
crw-rw-rw-    1 root     root       1,   3 Sep 11 23:32 /mnt/gentoo/dev/null
# ll /dev/null
crw-rw-rw-    1 root     root       1,   3 Jan  1  1970 /dev/null

The permissions seem to be okay. 

The second problem is that packages which require patching (like "vim" or
"gentoo-sources") fail - packages w/o patches (like "strace") can be merged just
fine. I dont get why emerge accesses /root/tmp - the permission denied is most
likely the sandbox, no?

Here's the uname -a from mandrake:
# uname -a
Linux  2.4.8-26mdk #1 Sun Sep 23 17:06:39 CEST 2001 i686 unknown

I'm kinda lost. Trying to install a stage2 as i write this, but i suppose that
this wont work either.

-phoen][x-
Comment 1 phoen][x 2002-09-19 13:06:47 UTC
It looks like some sandbox issue, maybe you have a clue about it Martin?
If you need additional information, tell me what you need and i'll get it.

-phoen][x-
Comment 2 Martin Schlemmer (RETIRED) gentoo-dev 2002-09-19 14:17:39 UTC
# set | grep TMP


And paste.  As for the /dev/null problems ... not sure, maybe a mandrake kernel
thing ?  Could he maybe boot off a gentoo livecd or something and try again ?
Comment 3 phoen][x 2002-09-26 05:51:35 UTC
Hmm, well he installed mandrake 9.0 rc3 last friday. I was curious, so i asked
him if he could chroot and try to install gentoo from stage3 again. It worked
flawlessy. It looks like this is a mandrake 8 issue - i dont have mandrake 8
around so feel free to find a tester and add him to the CC-list.

Sorry for not being able to run your command, Martin.

-phoen][x-
Comment 4 phoen][x 2002-10-04 02:07:01 UTC
Okay, i met this user (mushmoro4e) in #gentoo who had the same problem.

You where right martin, the mdk TMP/TMPDIR vars are kinda messed up. 
He fixed this problem with "export TMP=/tmp ; export TMPDIR=/tmp". 

Maybe we should add that to portage?

-phoen][x-
Comment 5 Martin Schlemmer (RETIRED) gentoo-dev 2002-10-07 13:14:20 UTC
One is taken care of, the other I missed.  Will fix now, thanks.