Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Ultra2 Disk Config & Silo.Conf & FSTAB
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc
View previous topic :: View next topic  
Author Message
robasan
n00b
n00b


Joined: 07 Dec 2004
Posts: 24
Location: Austin

PostPosted: Sat Dec 18, 2004 12:50 am    Post subject: Ultra2 Disk Config & Silo.Conf & FSTAB Reply with quote

I have the following question about an UltraSparc2: How should my /dev/sda be setup, along with silo.conf and fstab?

Machine info:
*Ultra2 2x300mhz proc, 1024 Ram, turbografx card, onboard nic.
*OPB or whatever at 3.25
*Set static ip to 192.168.1.113 192.168.1.255 255.255.255.255 192.168.1.1 and then set 3 nameservers in /etc/resolve.conf
*Downloaded sparc64 stage 3 from gentoo mirror last week. tar -xvjpf stage.xxxx
*Downloaded portage from gentoo mirror. tar -xvjf portage..xxx -C /gentoo/mnt/usr
*Compiled kernel is 2.9 mb (well below the 3.5 mb limitation)
I copied compiled kernel by arch/sparc64/boot/image /boot/kernel-2.4.28-sparc-r1
I copied .config with cp .config /boot/config-2.4.28-sparc-r1

I followed the Gentoo manual with this:
/dev/sda1 /mnt/gentoo (ext2) 1024MB
/dev/sda2 swap 2048MB (I have 1 gig riam)
/dev/sda3 whole disk slice for sun
/dev/sda4 /mnt/gentoo/usr (ext3) 10Gig
/dev/sda5 /mnt/gentoo/var (ext3) 10 Gig
/dev/sda6 /mnt/gentoo/home (ext3) 13 or so Gig

I then went through the handbook to the letter.

When I got to fstab, I read conflicting accts on Gentoo forums and elsewhere about what it should look like. The hand book says "don't add a /boot partition as willl potentially confuse some boot loaders" Yet 'sucessful' Ultra2 people said to have /boot and not mount the /dev/sda3 partition (sun whole disk slice thingy). Others point to /dev/sda1 is the / partition and no /boot partition.
Well, I'm clueless.

Silo.conf:
I did the following, just like the manual suggested:

partition = 1
root = /dev/hda4
timeout = 150
image = /boot/kernel-2.4-28-sparc-r1
label = linux

I got the "file not executable" when I rebooted.

I've tried alternate fstab and silo.conf to no avail.

What I would like is for someone with knowledge to tell me what I have done wrong and what these files should look like. I'm a noob, so any help would be great.

Do I mount the /dev/sda3 in /etc/fstab?
Is /dev/sda1 supposed to be / or is /dev/sda4?
Doesn't really matter to me.
If someone could be so kind as to "TELL" me what fstab, silo, and anything I'm missing should look like, you would have a faithful lapdog forlife.

Cheers from Noobville,
_________________
The next kernel rev has never addressed the basic problem: my innate incompetence.
Back to top
View user's profile Send private message
ibtim13
Tux's lil' helper
Tux's lil' helper


Joined: 12 Sep 2003
Posts: 84
Location: Troy, NY

PostPosted: Sat Dec 18, 2004 7:14 am    Post subject: Reply with quote

Hello, I've got a similar enough system that works great.

my fstab looks like this:

Code:

# /etc/fstab: static file system information.
# $Header: /home/cvsroot/gentoo-src/rc-scripts/etc/fstab,v 1.14 2003/10/13 20:03:38 azarah Exp $
#
# noatime turns off atimes for increased performance (atimes normally aren't
# needed; notail increases performance of ReiserFS (at the expense of storage
# efficiency).  It's safe to drop the noatime options if you want and to
# switch between notail and tail freely.

# <fs>             <mountpoint>    <type>     <opts>            <dump/pass>

# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
/dev/sda1      /boot      ext2            noauto,noatime      1 1
/dev/sda4      /      ext3      noatime         0 1
/dev/sdb1      /home      ext3      noatime         0 2
/dev/sda2      none      swap      sw         0 0
/dev/cdroms/cdrom0   /mnt/cdrom   auto      noauto,ro      0 0


# NOTE: The next line is critical for boot!
none         /proc      proc      defaults      0 0

# glibc 2.2 and above expects tmpfs to be mounted at /dev/shm for
# POSIX shared memory (shm_open, shm_unlink).
# (tmpfs is a dynamically expandable/shrinkable ramdisk, and will
#  use almost no memory if not populated with files)
# Adding the following line to /etc/fstab should take care of this:

none         /dev/shm   tmpfs      defaults      0 0
none          /proc/openprom   openpromfs   defaults      0 0


and my silo.conf looks like this:

Code:

partition = 1 #boot partition
root = /dev/sda4
timeout = 150
default = new

image = /boot/vmlinux-2.6.7
   label = linux

image = /boot/vmlinux-new
   label = new



Everything works perfectly for me, at least in terms of having a functional
system with a 2.4 kernel...
_________________
Grrr, can't think of anything clever right now, I'll go back and edit this later (9/12/2003)
Back to top
View user's profile Send private message
spam_
Tux's lil' helper
Tux's lil' helper


Joined: 14 Jan 2004
Posts: 105
Location: /dev/null

PostPosted: Sat Dec 18, 2004 3:54 pm    Post subject: Reply with quote

First of all, you really should be using ext3 for the root partiton. This happens to also be your boot partition, but it doesn't matter since ext3 is the same as ext2 except it has an additional (hidden) journal file. Boot the livecd, do not mount the filesystems, and do a "tune2fs -j /dev/sda1". This will add the journal to your ext2 filesystem, which turns it into ext3. All your data will be left untouched.

Now, the conf files. Try these (wordwrap may get the best of me, be careful...):

/etc/fstab
Code:

# /etc/fstab: static file system information.
# $Header: /home/cvsroot/gentoo-src/rc-scripts/etc/fstab,v 1.14 2003/10/13 20:03:38 azarah Ex
p $
#
# noatime turns off atimes for increased performance (atimes normally aren't
# needed; notail increases performance of ReiserFS (at the expense of storage
# efficiency).  It's safe to drop the noatime options if you want and to
# switch between notail and tail freely.

# <fs>                  <mountpoint>    <type>          <opts>                  <dump/pass>

# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
/dev/sda1               /           ext3            noatime          1 1
/dev/sda2               none            swap            sw,pri=0                0 0
/dev/sda4                /usr              ext3        noatime                 1 2
/dev/sda5               /var              ext3        noatime                  1 2
/dev/sda6               /home           ext3        noatime                  1 2

/dev/cdroms/cdrom0      /mnt/cdrom      iso9660         noauto,ro               0 0

# NOTE: The next line is critical for boot!
none                    /proc           proc            defaults                0 0

# glibc 2.2 and above expects tmpfs to be mounted at /dev/shm for
# POSIX shared memory (shm_open, shm_unlink).
# (tmpfs is a dynamically expandable/shrinkable ramdisk, and will
#  use almost no memory if not populated with files)
# Adding the following line to /etc/fstab should take care of this:

none                    /dev/shm        tmpfs           defaults                0 0

Note that /dev/sda3 does not get mounted, it in fact isn't even needed for linux - only Solaris needs it. All my systems, BTW, use lilo or silo with a seperate /boot on ext3, sized about 64M, and root on whatever device (on my Ultra 1 it's a 2-disk RAID0) running reiserfs. Works fine, and takes care of the pitfalls of root on RAID too. No reason not to do it that way all the time. Also, the "noatime" option helps speed things up by not writing the access time of any files; otherwise, every time a file is opened it will generate a disk write. If you want to use atimes, just get rid of the noatime option (when it's the only option in fstab replace it with "defaults").


/etc/silo.conf:
Code:

partition = 1
root = /dev/sda1
timeout = 150
image = /boot/kernel-2.4-28-sparc-r1
label = linux

Notes on silo.conf: you will probably just want the box to boot immediately instead of timing out or having you hit enter. To do this, in the OBP do "setenv boot-file linux" and "setenv auto-boot? true", and comment out the "timeout = 150" line in silo.conf. You should also run silo -f after updating the conf file. Technically you don't have to rewrite the bootblock every time, but it doesn't hurt, and is required in some cases (old version of silo already installed, etc).
Back to top
View user's profile Send private message
robasan
n00b
n00b


Joined: 07 Dec 2004
Posts: 24
Location: Austin

PostPosted: Sat Dec 18, 2004 11:22 pm    Post subject: silo.conf Reply with quote

I setup silo.conf as you suggested....

when I rebooted, it says "cannot find /boot/kernel-2.4.28-sparc-r1" (unknown ext2 error)"
Image not found ... try again
boot:

here's my question: the handbook says, that after compiling kernel, which is 3.2mb, to cp arch/sparc64/boot/image /boot/<your kernel>

so I typed it as cp arch/sparc64/boot/image /boot/kernel-2.4.28-sparc-r1

when I go to cd /usr/src/linux and type ls -l /usr/src/linux .... it points to
linux-2.4.28-sparc-r1
is this the wrong name?
how do I find out what my kernel name should be...
I thought I understood...but now...I'm sure I didnt...

when I boot back using live cd and mount /dev/sda1 /boot ...
ls give me the following:
vmlinux
kernel-2.4-28-sparc-r1
System.map
config-2.4-28-sparc-r1
and some other files...

is this what should be there in /boot?
i'm still confused as to what I should type when I do the cp arch/sparc64/boot/image /boot/??????????

thanks
_________________
The next kernel rev has never addressed the basic problem: my innate incompetence.
Back to top
View user's profile Send private message
spam_
Tux's lil' helper
Tux's lil' helper


Joined: 14 Jan 2004
Posts: 105
Location: /dev/null

PostPosted: Sun Dec 19, 2004 10:07 pm    Post subject: Re: silo.conf Reply with quote

You're getting confused because the guide is using a seperate /boot, while yours is not seperate - it is instead part of the root partition.

About copying the kernel image: after booting the livecd, mounting the partitions as in the fstab (prepend /mnt/gentoo to every mount point - mount /dev/sda1 to /mnt/gentoo, /dev/sda4 to /mnt/gentoo/usr, etc), and chrooting, do this:

Code:

$ cp /usr/src/linux/vmlinux /boot/vmlinux-2.4.28-sparc-r1

... this method being my way of naming the kernel images - it can be done any way you want. silo.conf should refer to /boot/vmlinux-2.4.28-sparc-r1 in this case. The guide is unclear when it talks about a seperate /boot, which I think is the better/more correct way to do things (although it really doesn't matter and you shouldn't switch now that it's already been done).

There should be no other images needed for the kernel itself - I have no idea what they're trying to do with arch/sparc64/boot/image, but it is not necessary. You should copy vmlinux into /boot, like above, and maybe also copy the .config used with a similar name (cp /usr/src/linux/.config /boot/config-2.4.28-sparc-r1) for reference.

Edit: Just for reference, I'm just gonna go ahead and post my versions of the relevant files here in case anyone else wants to know what I'm talking about. System is an Ultra 1E/200 with Creator and a qpti1000 SE Fast-Wide SCSI Sbus card, two 4.2GB SCSI disks in a RAID0 (chunksize 64k with persistent SB, over /dev/sda3 and /dev/sdb2), one external 4.2GB disk for music, seperate /boot on /dev/sda1, swap striped over 150M of each disk.

/etc/fstab:
Code:

/dev/sda1               /boot           ext3            noauto,noatime          1 1
/dev/md0                /               reiserfs        noatime                 1 1
/dev/sda2               none            swap            sw,pri=0                0 0
/dev/sdb1               none            swap            sw,pri=0                0 0
/dev/sdc1               /mnt/mp3        reiserfs        noatime         1 1
/dev/cdroms/cdrom0      /mnt/cdrom      iso9660         noauto,user,ro          0 0

none                    /proc           proc            defaults                0 0
none                    /dev/shm        tmpfs           defaults                0 0


/etc/silo.conf:
Code:

partition = 1
root = /dev/md0

image = /vmlinux-2.4.29-pre1_spam
        label = linux

image = /vmlinux
        label = linux-old


Notes: "partition = 1" refers to first partition of the disk the OBP has "disk" aliased to, in my case /dev/sda1. "/dev/md0" is root filesystem device created by RAID0. The kernel paths are relative to the boot partition, NOT the root partition (this is a major GOTCHA!), so the "/boot" is dropped in the kernel paths. "/boot/vmlinux" is a known working kernel, "/boot/vmlinux-2.4.29-pre1_spam" is my current custom kernel.

ls -lh /boot:
Code:

lrwxrwxrwx  1 root root    1 Nov 14 19:31 boot -> .
-rw-r--r--  1 root root 1.0K Jun 25 06:45 fd.b
-rw-r--r--  1 root root  512 Jun 25 06:45 first.b
-rw-r--r--  1 root root 1.0K Jun 25 06:45 generic.b
-rw-r--r--  1 root root  784 Jun 25 06:45 ieee32.b
-rw-r--r--  1 root root 7.1K Jun 25 06:45 isofs.b
drwx------  2 root root  12K Nov 14 19:16 lost+found
-rw-------  1 root root 7.5K Nov 15 15:48 old.b
-rw-r--r--  1 root root  151 Nov 14 20:07 raidtab
-rw-r--r--  1 root root  61K Dec 11 13:14 second.b
-rw-------  1 root root 1.1K Dec 11 13:14 silo.conf
-rw-r--r--  1 root root  59K Jun 25 06:45 silotftp.b
-rw-r--r--  1 root root  512 Jun 25 06:45 ultra.b
-rwx------  1 root root 2.2M Nov 15 15:46 vmlinux
-rwx------  1 root root 2.4M Dec 11 13:14 vmlinux-2.4.29-pre1_spam

Notes: raidtab is my RAID config file, it's supposed to be /etc/raidtab but it doesn't do me much good to store the RAID config on the RAID I'd need it to mount... it's stored as /boot/raidtab and symlinked from /etc/raidtab. It's invaluable when portage upgrades SILO over the current version, leaving me with a non-booting system (grrr :roll:), and I have to get the LiveCD to mount my root FS.

ls -lh /etc/silo.conf:
Code:

lrwxrwxrwx  1 root root 15 Nov 15 15:46 /etc/silo.conf -> /boot/silo.conf

Notes: silo needs silo.conf on the boot partition, but at the same time expects to find it at /etc/silo.conf when used on a running system to verify file syntax. I like to put my silo.conf in /boot and then symlink /etc/silo.conf to the real one in /boot.
Back to top
View user's profile Send private message
robasan
n00b
n00b


Joined: 07 Dec 2004
Posts: 24
Location: Austin

PostPosted: Sat Dec 25, 2004 5:14 pm    Post subject: SOLVED: See previous posts Reply with quote

Issues solved thanks to all the outstanding help and patience of the posts in this question.

THANK YOU...

:D
Currently settingup LAMP (Settting Up LAMP by Rosebrock and Filson ..ISBN 0782143377... )
This is book is great for NOOBS like me...
_________________
The next kernel rev has never addressed the basic problem: my innate incompetence.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc 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