LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 12-09-2008, 04:58 AM   #1
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Rep: Reputation: 15
Cannot Find Map file


Build : LFS 6.4
Kernel : 2.6.27.4

I get the message:

Dec 8 12:08:08 mybuild2 kernel: Inspecting /boot/System.map-2.6.27.4
Dec 8 12:08:08 mybuild2 kernel: Cannot find map file.
Dec 8 12:08:08 mybuild2 kernel: Loaded 40810 symbols from 1 module.
Dec 8 12:08:08 mybuild2 kernel: Linux version 2.6.27.4 (root@mybuild2) (gcc version 4.3.2 (GCC) ) #1 SMP Wed ec 3 18:16:38 GMT 2008

However the /boot/System.map-2.6.27.4 file does exist and everything does seem to boot okay.

So is this a problem I need to worry about?
 
Old 12-13-2008, 08:44 AM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
Yes, in short. It affects things.

Try 'ls -l /boot/System.map' - does it point at your shiny new System-map-version? Try removing it.
 
Old 12-14-2008, 02:23 PM   #3
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by business_kid View Post
Yes, in short. It affects things.

Try 'ls -l /boot/System.map' - does it point at your shiny new System-map-version? Try removing it.
Yes it does and I have tried removing it and also rebuilding the kernel with no luck.
 
Old 12-15-2008, 01:36 PM   #4
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
Quote:
Originally Posted by gazza1z View Post
Yes it does and I have tried removing it and also rebuilding the kernel with no luck.
Ah, excellent.

System.map is in the top of the kernel source.

cp /usr/src/linux_<version>/System.map /boot/System.map-<version>

That should fix it.
 
Old 12-16-2008, 09:03 AM   #5
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by business_kid View Post
Ah, excellent.

System.map is in the top of the kernel source.

cp /usr/src/linux_<version>/System.map /boot/System.map-<version>

That should fix it.
Tried that and it still can't find the map file. It must be a problem with the 2.6.27.4 kernel as I have the 2.6.22.5 kernel installed on a USB stick of exactly the same size and type as the 2.6.27.4 one and there isn't a problem.
 
Old 12-17-2008, 11:16 AM   #6
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
Either you ran 'make clean' or you haven't permissions. There is some silly nonsense there, as a kernel build makes a System.map. Nobody can particularly help you. Hunt around as root and sort it.
 
Old 12-18-2008, 02:24 PM   #7
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by business_kid View Post
Either you ran 'make clean' or you haven't permissions. There is some silly nonsense there, as a kernel build makes a System.map. Nobody can particularly help you. Hunt around as root and sort it.
I must have permissions as I build and install as root. I run make mrproper as the LFS6.4 book says and I chown -R 0:0 on the linux source directory.
 
Old 12-19-2008, 12:52 PM   #8
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
This way?
http://www.linuxfromscratch.org/lfs/...08/kernel.html

make mrproper removes everything from your build, leaving only a vanilla kernel. Even your .config is gone, unless you made a backup. If you repeat the 'make' with a copy of your backup, you won't have to install anything except the System.map

cp (your backup kernel .config) /usr/src/linux-*
make
cp System.map /boot/System.map-2.6.27.4

If you have a boot partition, remember that if it's not mounted and you write to it, the files go into the directory /boot. Then you mount the partition, and the files are invisible.

Also try

updatedb
locate System.map*

to search the disk for it. typos are possible in lfs - Take it from someone whop made many.
 
Old 12-22-2008, 11:18 AM   #9
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by business_kid View Post
This way?
http://www.linuxfromscratch.org/lfs/...08/kernel.html

make mrproper removes everything from your build, leaving only a vanilla kernel. Even your .config is gone, unless you made a backup. If you repeat the 'make' with a copy of your backup, you won't have to install anything except the System.map

cp (your backup kernel .config) /usr/src/linux-*
make
cp System.map /boot/System.map-2.6.27.4

If you have a boot partition, remember that if it's not mounted and you write to it, the files go into the directory /boot. Then you mount the partition, and the files are invisible.

Also try

updatedb
locate System.map*

to search the disk for it. typos are possible in lfs - Take it from someone whop made many.
I've done all that you have suggested with no luck. I'm now on kernel version 2.6.27.10 and it can't find that one either. However both kernels do conpile and boot to a command line. The only way I could do this though was to use the config file from my 2.6.22.5 system and run make oldconfig.

Otherwise succesfully booting a kernel is impossible without a kernel panic, how I managed it with the 2.6.22.5 version I don't know. It was more luck than anything else.

There are so many options most of which mean nothing to me (and to most people I suspect). Anyway rant over.

I think the main problem I have is that I've installed LFS onto USB 2.0 sticks and I wouldn't have these problems if I install LFS on a hard disk.

Thanks for all your help.
 
Old 12-23-2008, 07:10 AM   #10
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
ok. You sound like you are getting there. But if you lose System.map you are doing something wrong. After the make there should be a system.map (presuming you have modules. It should be in the kernel source. Copying it to /boot should succeed. Check these steps.

Configuring your kernel is an education. Take your time and read the help.

If you blank out, you can do: make allmodconfig. That makes all things as modules where possible. You can usually ignore options that require server support (= cpu time from a server).

I back up every .config to /root. There are web guides on kernel building. We are running

make modules_install, aren't we?? Send exact errors.

Last edited by business_kid; 12-23-2008 at 07:15 AM.
 
Old 12-26-2008, 07:51 AM   #11
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by business_kid View Post
If you blank out, you can do: make allmodconfig. That makes all things as modules where possible. You can usually ignore options that require server support (= cpu time from a server).

make modules_install, aren't we?? Send exact errors.
I build everything statically. I make absolutely sure I don't make any modules. Now I know this makes the kernel bigger but I have 2GB of RAM and I haven't installed X windows yet. So I don't run make modules_install.

I tried reading the /etc/modprobe.conf man and info pages but I can't make head or tail of them so I don't use modules at all.
 
Old 12-27-2008, 04:09 AM   #12
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
Thanks for that. I never considered that as a possibility.

I would run 'make modules' and 'make modules_install' as the lfs book says. That will create a System.map appropriate to your kernel. Then install it and we can kill off this thread. By now you must have been told "FBBG"
Follow the Book; The Book is Good!

The story with modprobe.conf requires a little explaining: Prior kernel versions (2.0, 2.2) had a very dodgy module interface, which peaked at user friendliness in the 2.4 kernels. So, of course, it was blindingly obvious that this had to be rewritten :-/. The 2.6 kernel interface gave us 'features' that didn't work, and were later dropped. As soon as you get used to one thing, the rule is they have to change it. So it's not modprobe.conf any more, it's /etc/modprobe.d/files (Don't ask me why)

To cut to the chase, you go around your devices driven by modules and throw in lines as required.

alias device module, e.g.
alias eth0 via-rhine #loads the via rhine module when the kernel is looking for eth0. It's a way of telling the kernel what driver to use.

options via-rhine <whatever> e.g.
options via-rhine -c1 -b3 -x2

would pass those options to the via rhine module every time it was put in. Alsa throws in a bit of this. I haven't had to use it elsewhere - it's for things like isa sound cards and weirdo devices.

Forget the rest.

Last edited by business_kid; 12-27-2008 at 04:10 AM. Reason: mistake
 
Old 12-29-2008, 06:01 AM   #13
gazza1z
Member
 
Registered: Sep 2008
Posts: 30

Original Poster
Rep: Reputation: 15
The LFS6.4 book actually states:

Install the modules, if the kernel configuration uses them:

The operative word being if. Since I make sure there are no CONFIG options set to m in my config file I don't run make modules_install.

Your right though I think it is about time this thread is closed. I've done a bit of googling and it appears LFS have had this problem since version 5.1, opensuse has this problem and RedHat has had it since 1996! So I not the only one

Thanks for all your help especially concerning the /etc/modprobe.d/files directory as I was wondering what this was for if there was an /etc/modprobe.conf file
 
Old 12-30-2008, 03:55 AM   #14
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
Quote:
Originally Posted by gazza1z View Post
The LFS6.4 book actually states:

Install the modules, if the kernel configuration uses them:

The operative word being if. Since I make sure there are no CONFIG options set to m in my config file I don't run make modules_install.

If you ran make modules and System.map appeared, I would give them hell on the lfs list over that. BTW, I disagree with making non modular kernels. If you ever had an issue with a module (Like I did for 4 years with ehci-hcd) having it non modular is a disaster. I could always run 'rmmod -f ehci_hcd). Also, I remember days of low ram, dodgy modules needing options, and have certain habits formed.
 
Old 01-29-2009, 05:35 PM   #15
trevork1954
LQ Newbie
 
Registered: Jan 2009
Location: Bath, UK
Distribution: Debian, LFS
Posts: 1

Rep: Reputation: 0
Just an additional note (yes, I know this thread is closed!): I've had exactly the same problem in LFS6.4 with a lovingly hand-crafted kernel and (just like gazza1z) I worked exactly from the book. System.map-($uname -r) is present in /boot AND I soft-linked it to /boot/System.map.

I built LFS 6.3 last year in a similar manner with no problems at all (so it's unlikely I've been an idiot this time).

Unfortunately (according to the klogd manual page) there are some drivers that require the map, so I can't just ignore it (and I hate unexplained things in my distro anyway). There's been no subsequent Internet posting that solves this issue, so I guess I'll have to trawl through the source code for klogd next :-(
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mount command cant find smb directories but file-browsers can map to them. robertbas Linux - Networking 2 09-21-2006 03:12 AM
Where can find some articles about /boot/System.map sailershen Linux - General 1 04-02-2006 10:46 PM
SYSERR(root): hash map "generics": missing map file /etc/mail/genericstable.db? singying304 Linux - Networking 4 02-28-2005 06:49 AM
cannot find map file. No module symbols loaded - kernel modules not enabled. jjorloff1 Linux - Software 3 01-06-2005 11:02 AM
DVD Playback error: Unable to find map file (Slackware w/ KDE) shaun85 Linux - Newbie 1 10-15-2004 11:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 06:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration