Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Been asked 1000 times. Gentoo on a G4 Mac [Solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC
View previous topic :: View next topic  
Author Message
antyx
n00b
n00b


Joined: 12 Jul 2005
Posts: 8
Location: WI

PostPosted: Tue Jul 12, 2005 5:17 pm    Post subject: Been asked 1000 times. Gentoo on a G4 Mac [Solved] Reply with quote

I've been playing with settings trying to get my G4 MAC to boot correctly into Gentoo and i cant figure it out. i guess i should start by asking what files i need to post before somebody can help me to ge this to work? And if anybody can help me to get this working.

Any help would be great.

Thanks
Antyx. :?


Last edited by antyx on Wed Jul 20, 2005 12:29 am; edited 1 time in total
Back to top
View user's profile Send private message
JoseJX
Retired Dev
Retired Dev


Joined: 28 Apr 2002
Posts: 2774

PostPosted: Tue Jul 12, 2005 5:33 pm    Post subject: Reply with quote

Well, it would be better to start with what exactly is going wrong?
Is it the LiveCD?
Your install?
Does it start yaboot?

The devil is always in the details. ;)
_________________
Gentoo PPC FAQ: http://www.gentoo.org/doc/en/gentoo-ppc-faq.xml
Back to top
View user's profile Send private message
antyx
n00b
n00b


Joined: 12 Jul 2005
Posts: 8
Location: WI

PostPosted: Tue Jul 12, 2005 6:06 pm    Post subject: Reply with quote

the live cd works, i ran through the gentoo linux 2005.0 PPC handbook, i think i configured yaboot correctly...when it boots it goes to a white screen which reads "Loading second stage bootstrap..." ... but then it hangs there.
Back to top
View user's profile Send private message
phlogistonjohn
n00b
n00b


Joined: 21 Mar 2005
Posts: 16
Location: MA, US

PostPosted: Thu Jul 14, 2005 11:33 pm    Post subject: Reply with quote

I had this error, and got it working by changing two things, so I'm not sure which one actually solved the problem.

1) I added a ofboot=<openfirmware-path> line to yaboot.conf
2) The documentation does not say to run ybin -v after doing a mkofboot -v, but it may just have been the changes I made to yaboot.conf

My whole yaboot.conf:
Code:

## Example yaboot.conf for ybin and yaboot >= 0.6
## see man yaboot.conf for more details.

## Change `unconfigured' to your bootstrap partition eg: /dev/hda2
boot=/dev/hda2

## device is the OpenFirmware device path to the disk containing
## kernel images.  if your disk is /dev/hda you can find the
## OpenFirmware path by running the command: ofpath /dev/hda DO NOT
## specify a partition number for this!  On IBM hardware you can
## generally comment this out.

device=hd:

ofboot=/pci@f2000000/mac-io@17/ata-4@1f000/disk@0:2

## partition is the partition number where the kernel images are
## located.  The kernel images should be on your root filesystem, so
## this is usually the same partition number as your root filesystem.
## so if root = /dev/hda3 (the 3rd partition) then you should have
## partition=3  This *MUST* be set correct or yaboot won't boot!  This
## option can be either set globally as shown here, or per image in
## the image= sections

partition=4

## delay is the amount of time in seconds the dual boot menu (if one
## is configured, by the presense of macos, macosx, etc options here)
## will wait before choosing the default OS (GNU/Linux or the value of
## defaultos=).  If you omit this then the value of timeout=
## (converted to seconds) will be used.

delay=10

## timeout is the amount of time in tenths of a second that yaboot
## will wait before booting the default kernel image (the first image=
## section in this config file or the value of default=).

timeout=40
install=/usr/lib/yaboot/yaboot
magicboot=/usr/lib/yaboot/ofboot

## Change the default colors, fgcolor is the text color, bgcolor is
## the screen background color. (default: fgcolor=white, bgcolor=black)
#fgcolor=black
#bgcolor=green

## Password supplied in plaintext, required for yaboot to boot, unless
## restricted is also present (see below). Be sure to
## chmod 600 /etc/yaboot.conf if you set this!

#password=secret

## Password supplied as an md5 hash, see above

#password=$1$saltstrg$HnJ/gcM3oKhNbnzUPgXTD/

## A password is only required to boot an image specified here if
## parameters are specified on the command line or if the user enters
## an image is not specified in the configuration file at all (ie.
## arbitrary file load).  restricted can also be placed in an image
## section in that case any image not including the restricted keyword
## will be fully password protected.

#restricted

## image is the kernel itself, commonly kept in / but also commonly
## found in /boot.  Note that /boot should generally not be its own
## partition on powerpcs, its not necessary and complicates things.
## Make sure /boot is on the partition specified by partition= see
## above.  /boot should never be an HFS filesystem.  You may point
## image= to a symbolic link so long as the symlink does not cross
## partition boundries.

image=/boot/kernel-2.6.10
        label=Linux
        root=/dev/hda4
        partition=4
        read-only



[/code]
Back to top
View user's profile Send private message
antyx
n00b
n00b


Joined: 12 Jul 2005
Posts: 8
Location: WI

PostPosted: Sat Jul 16, 2005 10:31 pm    Post subject: still no luck Reply with quote

ok, so i played with my yaboot.conf file a bit using yours as a model, still no luck....i was wondering if the path of the openfirmware is the same for every G4...if it isnt, then .. what would i use for that path?

also, would it help if I posted the contents of specific files like my fstab, or my yaboot.conf to help anybody figure out the problem?

one last thing, what do mkofboot -v and ybin -v do...and should i have run them after changing my yaboot.conf....i know, this is probably going to make me look like an idiot asking these questions, but Im new to gentoo, and linux as well...so im still doing alot of learning as I go.

Thanks again

in the meantime i will keep trying to figure this out.
Back to top
View user's profile Send private message
fb
l33t
l33t


Joined: 08 Dec 2003
Posts: 636
Location: New Zealand

PostPosted: Sun Jul 17, 2005 3:10 am    Post subject: Re: still no luck Reply with quote

antyx wrote:
ok, so i played with my yaboot.conf file a bit using yours as a model, still no luck....i was wondering if the path of the openfirmware is the same for every G4...if it isnt, then .. what would i use for that path?


I don't think it is the same for every mac, there is a command to find it but I cannot remember
from the top of my head.

antyx wrote:
also, would it help if I posted the contents of specific files like my fstab, or my yaboot.conf to help anybody figure out the problem?


Yes it would. At least we could make a correct yaboot.conf file for you.

antyx wrote:
one last thing, what do mkofboot -v and ybin -v do...and should i have run them after changing my yaboot.conf....i know, this is probably going to make me look like an idiot asking these questions, but Im new to gentoo, and linux as well...so im still doing alot of learning as I go.


The real idiots don't ask questions when they have problems (believe me I have had
some students this year.... better not talk about it).
So as far as I am concerned you are OK :wink: . It took me some time to get my
system up and I wasn't new to linux.

"mkofboot" and "ybin" are indeed needed. In very rougth terms mkofboot format a
special partition for the boot loader and ybin takes your yaboot.conf and put all the right
instructions on that special partition and makes it bootable. Without them you will have no
luck trying to boot linux. You should read carefully the instruction in the handbook as you
should have created a special boot partition for this purpose.

Cheers,
Francois
Back to top
View user's profile Send private message
JoseJX
Retired Dev
Retired Dev


Joined: 28 Apr 2002
Posts: 2774

PostPosted: Sun Jul 17, 2005 3:31 pm    Post subject: Reply with quote

If you could post the output of
Code:
mac-fdisk -l /dev/hda
that would help as well. This command shows us the layout of your disk partitions.
_________________
Gentoo PPC FAQ: http://www.gentoo.org/doc/en/gentoo-ppc-faq.xml
Back to top
View user's profile Send private message
antyx
n00b
n00b


Joined: 12 Jul 2005
Posts: 8
Location: WI

PostPosted: Mon Jul 18, 2005 1:39 pm    Post subject: here are the files. Reply with quote

ok, so ...

FSTAB:(only the non-commented lines)(and the tabs are off, im typing this out.......i only have one net connection to use...)

/dev/hda4 /boot ext3 defaults,noatime 0 1
/dev/hda3 / swap sw 0 0
/dev/cdroms/cdrom0 /mnt/cdrom auto noauto,user 0 0

none /proc/ proc defaults 0 0

none /dev/shm tmpfs nodev,nosuid,noexec 0 0


yaboot.conf

boot=/dev/hda2
device=hd:
ofboot=/pci@f2000000/pci-bridge@d/mac-io@17/ata-4@1f000/disk@0:


partition=4
delay=10
timeout=40
install=/usr/lib/yaboot/yaboot
magicboot=/usr/lib/yaboot/yaboot

image=/boot/kernel-2.6.10-gentoo-r8
label=Linux
root=/dev/hda4
partition=4
read-only

and the mac-fdisk -l /dev/hda:

/dev/hda1 Apple_partition_map Apple 63@1 (31.5k) Partition map
/dev/hda2 Apple_Bootstrap bootstrap 1600@64 (800.0)k NewWorld bootblock
/dev/hda3 Apple_UNIX_SVR2 swap 1048576@1664 (512.0M) Linux Swap
/dev/hda4 Apple_UNIX_SVR2 root 38961312 @ 1050240 (18.6G) Linux native
Back to top
View user's profile Send private message
fb
l33t
l33t


Joined: 08 Dec 2003
Posts: 636
Location: New Zealand

PostPosted: Mon Jul 18, 2005 10:26 pm    Post subject: Reply with quote

OK I compared with mine and I am not sure there are any problem with
your yaboot.conf. But you can try this (inspired by mine and yours):
Code:
boot=/dev/hda2
device=/pci@f2000000/pci-bridge@d/mac-io@17/ata-4@1f000/disk@0:

partition=4
delay=10
timeout=40
install=/usr/lib/yaboot/yaboot
magicboot=/usr/lib/yaboot/yaboot

image=/boot/kernel-2.6.10-gentoo-r8
label=Linux
root=/dev/hda4
read-only


Now, on mine I cannot open an initial console at the moment and it takes
some time before X kicks in and give me a graphical login so it may be
worth to wait a few minutes before declaring it a failure. Don't forget
you should have run "mkofboot -v" at least once before, if you didn't
do it now, and each time you change yaboot.conf "ybin -v" must be
run. If you run it from the live cd there are special instructions for it to
really take effect be sure to follow the handbook closely.

Francois
Back to top
View user's profile Send private message
JoseJX
Retired Dev
Retired Dev


Joined: 28 Apr 2002
Posts: 2774

PostPosted: Tue Jul 19, 2005 1:10 am    Post subject: Reply with quote

I'm not sure if it was the copying procedure or if it's actually wrong, but your fstab should look more like this:

Code:

/dev/hda4               /               ext3            noatime                 0 1
/dev/hda3               none            swap            sw                      0 0
/dev/cdroms/cdrom0      /mnt/cdrom      auto            noauto,ro,user          0 0
none                    /proc           proc            defaults                0 0
none                    /dev/shm        tmpfs           defaults                0 0


You do not need the /boot section and I'm guessing that your root partition is formatted for ext3.

Hope that helps.
_________________
Gentoo PPC FAQ: http://www.gentoo.org/doc/en/gentoo-ppc-faq.xml
Back to top
View user's profile Send private message
antyx
n00b
n00b


Joined: 12 Jul 2005
Posts: 8
Location: WI

PostPosted: Wed Jul 20, 2005 12:29 am    Post subject: Thanks for all the help Reply with quote

I wanted to thank everybody for the help in figureing this out....i have a booting G4 linux box :-D.

Jose, my fsab did look like that, i just had problems copying it to another computer.

fb, thanks for the help getting the 'device=" line correct in my yaboot.conf.....but ultimately what did it i think is wehn i added the

Code:

initrd=/boot/initrd-2.6.10-gentoo-r8
initrd-size=8192


in the yaboot.conf file. ( i had some help from a local linux friend as well)

again, tnaks for the help everybody....
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum