LinuxQuestions.org
Visit Jeremy's Blog.
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 06-18-2005, 01:04 AM   #1
daly1
Member
 
Registered: May 2005
Distribution: gentoo ROCKS
Posts: 32

Rep: Reputation: 15
Question Multi-Arch LFS


Is this http://documents.jg555.com/multi-arch/x86 the guide on building 32 and 64 bit libraries for x86_64? I have been trying to build LFS for a while on my Athlon and have managed to go all the way to the end, bar being able to boot as I could not compile grub on my machine.

I would assume that multi-arch would mean so, but I do not see any difference between the way the packages are compiled in this document and the normal LFS book.

Thanks.
 
Old 06-18-2005, 05:32 AM   #2
Harmaa Kettu
Member
 
Registered: Apr 2005
Location: Finland
Posts: 196

Rep: Reputation: 30
Quote:
Is this http://documents.jg555.com/multi-arch/x86 the guide on building 32 and 64 bit libraries for x86_64?
No, multi-arch != multilib.
I remember reading somewhere that x86_64-multilib is going to be one of the architectures supported by the multi-arch version of LFS, but as you can see by going a directory up (http://documents.jg555.com/multi-arch/), it is not available yet.
Quote:
have managed to go all the way to the end
You have ended up with x86_64 system without 32-bit support.
Quote:
I could not compile grub on my machine.
Grub does not support x86_64. Lilo works fine.
 
Old 06-18-2005, 10:39 AM   #3
daly1
Member
 
Registered: May 2005
Distribution: gentoo ROCKS
Posts: 32

Original Poster
Rep: Reputation: 15
Talking

Thanks for the reply. Could you please explain the difference between multi-arch and multilib?

I did compile lilo, but had problems booting it. I kept getting this silly L 01 01 01 01 error or L 09 09 09 09, no matter what I did, or no matter how much I edited /etc/lilo.conf or /etc/fstab on the LFS system.

The main problem with LILO, was trying to run the LILO command from within the chroot. I could neither run it or run fdisk on the hard disk carrying the LFS System. I guess the system protects from changing hard drive settings or writing to the MBR from within a chroot. I also tried copying /mnt/LFS/etc/lilo.conf to my system's /etc/lilo.conf, changing the name of the kernel to use from /boot/lfskernelimage to /mnt/LFS/boot/lfskernelimage, running LILO from the host to write the MBR, but keeping the file on the LFS system without any references to /mnt/LFS, but that did not work.

I then made a link from /boot/lfskernelimage to /mnt/LFS/boot/lfskernelimage and making lilo.conf on both the host and LFS system to look identical and running LILO from the host, but that did not work either!

I was so close and yet so far
 
Old 06-19-2005, 10:39 PM   #4
daly1
Member
 
Registered: May 2005
Distribution: gentoo ROCKS
Posts: 32

Original Poster
Rep: Reputation: 15
Hello all,

Does anyone have an answer to the question above?

Thanks.
 
Old 06-19-2005, 11:58 PM   #5
kjordan
Member
 
Registered: Jul 2004
Distribution: LFS, I felt the itch and scratched it
Posts: 227

Rep: Reputation: 31
The system doesn't protect against changing the MBR in a chroot environment, otherwise the LFS book wouldn't work. Did you make sure to disable CFLAGS or any other optimizing flags when you compiled LILO? Posting the configuration files may help as well.
 
Old 06-20-2005, 12:15 AM   #6
daly1
Member
 
Registered: May 2005
Distribution: gentoo ROCKS
Posts: 32

Original Poster
Rep: Reputation: 15
Question

I compiled without any flags. My system is a suse 9.3 running on a sata hard disk. I am building my LFS system on hdd.

FROM WITHIN THE CHROOT:
This is my lilo.conf file:
boot=/dev/hdd

image=/boot/lfskernel-2.6.9
label=LFS
root=/dev/hdd1
read-write

running lilo produces:
mediacentre:/ # lilo
Fatal: raid_setup: stat("/dev/hdd")

running fdisk -l /dev/hdd and fdisk /dev/hdd produces:
mediacentre:/ # fdisk -l /dev/hdd
mediacentre:/ # fdisk /dev/hdd

Unable to open /dev/hdd

FROM WITHIN THE HOST SYSTEM:
mediacentre:/ # fdisk -l /dev/hdd

Disk /dev/hdd: 20.0 GB, 20020396032 bytes
16 heads, 63 sectors/track, 38792 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

Device Boot Start End Blocks Id System
/dev/hdd1 * 1 389 196024+ 83 Linux
/dev/hdd2 390 1649 635040 82 Linux swap / Solaris
/dev/hdd3 1650 38792 18720072 83 Linux

Thanks.
 
Old 06-20-2005, 01:11 AM   #7
kjordan
Member
 
Registered: Jul 2004
Distribution: LFS, I felt the itch and scratched it
Posts: 227

Rep: Reputation: 31
Did you run the command (i.e. /sbin/udevstart) to fill your /dev directory?
 
Old 06-20-2005, 07:18 AM   #8
daly1
Member
 
Registered: May 2005
Distribution: gentoo ROCKS
Posts: 32

Original Poster
Rep: Reputation: 15
Red face

Crap!! I don't believe that I did not check this!!!

OK, so /dev is empty bar /dev/pts, /dev/shm and /dev/null. Running udevstart does nothing as my /sys directory is empty. Not sure how that happenned. I will review the book and see where that is populated.

Thank a hundred million times
 
Old 06-20-2005, 08:25 AM   #9
daly1
Member
 
Registered: May 2005
Distribution: gentoo ROCKS
Posts: 32

Original Poster
Rep: Reputation: 15
Thumbs up

Got it!! Thank you so very very much

The problem was not running this before rentering the chroot:
mount -t proc proc $LFS/proc
mount -t sysfs sysfs $LFS/sys

Running this, chrooting, and then running udevstart was the fix.

Thank you very much again.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
LFS Book Chapter 6 - 1st step (chroot to /mnt/lfs) doens't work bauld Linux From Scratch 11 03-15-2006 12:31 AM
How to Boot Multi Windows & Multi Linux olkar Linux - Newbie 5 10-03-2005 11:52 AM
LFS-7.0-cross-lfs-20050902-x86_64-Multilib Basel Linux From Scratch 0 09-03-2005 05:03 AM
How do you change card# of multi multi-media cards. Nichole_knc Slackware 3 12-01-2004 12:49 PM
GRUB, Multi Linux/Multi Disk Boot gtnorton Linux - Software 1 03-16-2003 03:48 AM

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

All times are GMT -5. The time now is 06:04 AM.

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