Chapter 6: Kernel Headers Problem
I'm at a bit of a loss here. I've got to the bit where it says about not installing the kernel, but installing the headers because some programs need them to compile. It said before this that I needed to move the source tarballs to wherever I wanted, so I moved them all to /usr/src/lfstarballs.
I wasn't quite sure where to decompress the kernel (this will not after all be installing it, so I'm not sure where it goes at the moment) - so I made a new directory for it with the tarballs, moved the compressed kernel in there and decompress. The final decompressed kernel lands in /usr/src/lfstarballs/kernel/linux-2.4.19/ First problem: I'm told to make a symlink from /static/bin/pwd to /bin/pwd, but this already exists (symlink). Second problem: the line: make include/linux/version.h fails as well. Haven't got past this line so I don't know if any of the following will also fail. The above line gave me a: I have no name!:/usr/src/lfstarballs/kernel/linux-2.4.19# make include/linux/version.h /bin/sh: /dev/null: Permission denied /bin/sh: /dev/null: Permission denied KERNELRELEASE "2.4.19" exceeds 64 characters make: *** [include/linux/version.h] Error 1 It is a bit of a convoluted directory structure, so I thought it might be a bit long. *shrug* Never successfully compiled a kernel before, so a guess is as good as anything else. So I then decompressed the kernel in /usr/src/linux-2.4.19. Avoided the first step as per above, mrproper went fine, then I got this on the make include/linux/version.h: I have no name!:/usr/src/linux-2.4.19# make include/linux/version.h /bin/sh: /dev/null: Permission denied /bin/sh: /dev/null: Permission denied KERNELRELEASE "2.4.19" exceeds 64 characters make: *** [include/linux/version.h] Error 1 I have no name!:/usr/src/linux-2.4.19# The same problem. Ran a search on this and nothing came up. Hope someone out there knows the source of my woes :D Also, another kernel related question. When (If?) I get around to compiling the kernel, can I apply the packet-writing patch which it says on the sourceforge site is for 2.4.0-test10? 'Cause that's the latest version of it I can find. Thanks all :) |
Could you post the permissions to /dev/null and are you positive that your chrooted as root?
Are you positive that you followed this step to create all of the devices under /dev/? http://www.au.linuxfromscratch.org/v...6/makedev.html Also, just to be on the safe side, remove the symlink to /bin/pwd and re-create it... |
I, I um am a little confused. Grim's gotta good question, are you in the chrooted env? It would appear so, especially with the "I have no name" goin on.
I'd go back a pinch, make sure you didn't miss a step. Did you symlink bash to sh? http://www.linuxfromscratch.org/view...eatefiles.html That just seems like a very odd message.. Cool |
Yup, done all of these at least once. Some of them twice by now. Went back through all the steps from Chapter 6 again in case I had done something wrong. Here's how it went:
An - I'm assuming small - iritation arose when chrooting itself, the PATH variable wasn't set properly, as it couldn't find any programs, but I just used the export PATH=/static/bin:$PATH when I was in chroot and all seemed fine from there. chown -R 0:0 /static went off with no complaints. Making the directory tree gave a bunch load of errors, all along the lines of, "these already exist". Changing the permissions of /root /tmp and /var/tmp went fine also. Did an ls -l in the various directories to confirm: Code:
drwxr-x--- 2 0 0 4096 Jan 7 18:24 root Code:
drwxrwxrwt 2 0 0 4096 Jan 7 09:01 tmp Mounting proc simply said that it was already mounted. Creating the mtab symlink from /proc/mount with: ln -sf /proc/mounts /etc/mtab went fine, only thing odd was that it didn't give an error about it already existing. I deleted everything in the /bin dir, as there were all symlinks anyway. Made the /bin/bash and /bin/sh symlinks without problems. Then I deleted the group and passwd files in /etc to make them again with those mini-scripts. They both passed without error. So onto the MAKEDEV script. used MAKEDEV -v generic and it filled the screen pretty quickly with what it was up to. It looked exactly the same as before, right down to what during the first time I assumed where not important, about 20 of these lines interspersed themselves throughout the output: Code:
./MAKEDEV: /dev/null: Permission denied My spidy sense tells me that /dev/null's something to do with it. Here are the permissions for those that understand them better: Code:
crw-rw-rw- 1 0 0 1, 3 Jan 7 18:46 null |
Lets give /dev/null a test...
create a simple little file that contains anything, say "hello" somewhere. Then type this: mv /path/to/little/file /dev/null and tell us if the file disappears or gives you errors.. |
Strangely enough, it just decided to work.
Tried the /dev/null thing and it trashed the file put into it. So with that working perfectly, I rm -R * the kernel directory, rmdir linux-2.4.19 and then untar the kernel again. Ran the usual commands and it worked first time. I guess I must have forgotten something the first time around. Thanks guys :D |
Nice catch Grim! Glad you got it working Obi.
Cool |
hehe, w00t! I semi-helped somebody for the first time with a LFS (and in general, a linux) problem :D
|
he he, feels good doesn't it? That's what keeps me comin back. ;) It's addicting, trust me:
Hi room, I'm Chad, and I'm an LQ Addict :D Cool |
All times are GMT -5. The time now is 09:59 PM. |