PDA

View Full Version : Creating partitions in linux..actually all my gentoo questions go here.



Peegee
02-25-2004, 03:08 PM
I'm installing Gentoo on my P3 (I'm using a P4 here), but I don't know how to repartition everything. I'd like to delete the entire hard drive and start anew, but there isn't any /dev/hda (or any directories for that matter) around. What do I do?

(According the instructions in gentoo.org I'm booting using liveCD and I have a connection to the internet)

Dr Unne
02-25-2004, 05:34 PM
Did you read the install directions? http://www.gentoo.org/doc/en/handbook/handbook.xml?part=1&chap=4#doc_chap3 Once you boot off the LiveCD, there has to be a /dev/hda, assuming your hard drive is plugged in and working. Do ls /dev | grep hd if you don't think there is one.

Peegee
02-25-2004, 06:54 PM
Okay my stupidity knows no limits -- I was in some directory outside of root.

-_- *feels so stupid*

edit: okay I'm here now: http://www.gentoo.org/doc/en/handbook/handbook.xml?part=1&chap=7

When I type "emerge --usepkg vanilla-sources" I get an illegal instruction error. I've tried using gentoo-sources and just emerge itself. *sigh*

Dr Unne
02-25-2004, 10:51 PM
<i>Okay my stupidity knows no limits -- I was in some directory outside of root.</i>

You mean you were logged in as a user other than root?

<i>When I type "emerge --usepkg vanilla-sources" I get an illegal instruction error. I've tried using gentoo-sources and just emerge itself. *sigh*</i>

What is "illegal instruction error"?

Did you read this?

<i>Choose your kernel source and install it using emerge. From now onwards we will use emerge --usepkg which will install a prebuilt package if available (for GRP users) and download it otherwise. In other words, if you are not using prebuilt packages, you can omit the --usepkg option, but you don't have to. Furthermore, you can abbreviate the --usepkg option by using -k.</i>

Are you using GRP? If not, you don't want the --usepkg option. Just <b>emerge whatever-sources</b>. You already did <b>emerge sync</b> and <b>emerge system</b> and whatnot, right? If those worked, there's no reason <b>emerge whatever-sources</b> shouldn't work too. Substituting something for "whatever" of course. (Get gentoo-sources, they're nice. They have patches to increase performance for desktop users. )

At least you're almost done with the install. If you can survive compiling the kernel, you'll be set.

Peegee
02-25-2004, 10:53 PM
I wasn't logged in as a user. I was just in another 'directory', like for example /bin/dev (not that directory but some other one).

I don't know what illegal instruction means, but what you told me didn't work ;_; Typing 'emerge' by itself gives me the illegal instruction error as well. I'm supposed to be in root directory when I do this right?

Is it possible to download the kernel and then install? How do I go about doing that if so?

Nait
02-25-2004, 10:55 PM
Originally posted by Moo Moo the Ner Cow
Yes I'm almost done. My brain hurts and I'm starting to hate linux


Welcome to the club. Btw, old Linux-partitions make for a great anime-storage if nothing else.

Dr Unne
02-25-2004, 11:02 PM
Did you forget the / on the front of /dev/hda then, maybe? If you're in any directory and you say "fdisk /dev/hda", it should work. It doesn't matter what directory you're in. On the other hand if you say "fdisk dev/hda", then it looks for CURRENT_DIRECTORY/dev/hda, which probably doesn't exist. That's the difference between "absolute" and "relative" filenames. If you type the fully-qualified pathname starting from /, then you can reference any file from anywhere.

If you hate Linux, don't use it. It's not for everyone. Pick one: an OS which does everything by itself, but does the wrong thing half the time and leaves you no chance to fix the problems, or an OS which mostly forces you to do everything yourself, but which consistently does what you tell it to do and nothing more (and nothing less), and which as a result gives you the chance to do the right thing 100% of the time. You can have user-friendly, or you can have something that works, but not both, for the most part. It's up to you if you'd rather have something friendly that sucks rather than something unfriendly that works.

Peegee
02-25-2004, 11:12 PM
I can use linux if it's installed. :)

I think I know what the problem is...by stating another. Way back when they told me to type env-update it gave me that illegal instruction error. *confused*

Dr Unne
02-25-2004, 11:17 PM
What illegal instruction error? What does it say? If you post the exact error someone (i.e., me) can tell you what's wrong.

Peegee
02-25-2004, 11:26 PM
The exact error is illegal instruction

ie:

cdimage / # env-update [ enter ]
Illegal instruction
cdimage / #

ie:

cdimage / #emerge gentoo-sources
Illegal instruction
cdimage / #

ie:

cdimage / #emerge
IIlegal instruction
cdimage / #

you get the idea. ;_;

Dr Unne
02-25-2004, 11:46 PM
So far as I know, "Illegal instruction" means that you're trying to run an executable that was compiled for an architecture different from what your processor actually supports. For example something compiled for AMD64 when you actually have a Pentium 4 or something. What kind of processor do you have and which CD did you download? There's a part of the install where you have to set CHOST, CFLAGS and CXXFLAGS in /etc/make.conf. What did you set them as?

Endless
02-26-2004, 12:04 AM
Last night you were getting the stage3 install archive for a <b>PIV</b>, and you're installing it on a <b>PIII</b>. Are you using the PIII install, or the PIV? If you're installing it on the PIII, as you said in your first post, then get the PIII install.

Peegee
02-26-2004, 12:04 AM
Using the liveCD to boot, I downloaded the pentium4 stage3 tar file from here (http://adelie.polymtl.ca/releases/x86/2004.0/stages/pentium4/).

CHOST=i686-pc-linux-gnu //should this be i586?
CFLAGS="-march=athlon-xp -pipe -O2" // I have a pentium 4, so I don't know what to put here
CXXFLAGS="${CFLAGS}"

edit: >_< @ endless *starts over*

Dr Unne
02-26-2004, 12:34 AM
So far as I know, i586 is just an old pentium1. i686 is fine for you.

If you have a P4, you want CFLAGS="-march=pentium4 -pipe -Os" The -O flag you use is up to you, but I use -Os.

Peegee
02-26-2004, 12:43 AM
Thanks. And P3 is just CFLAGS="-march=pentium3 -pipe -Os" ?

*does so anyway* xD

Dr Unne
02-26-2004, 12:48 AM
It says all this (and much more) in the comments in /etc/make.conf, by the way. It also says not to use -march=pentium4 because of bugs in GCC, but I use it anyways. :)

Peegee
02-26-2004, 02:57 AM
>_<

I got up to configuring the bootloader. I chose grub, ran it. It compiled or installed or whatever. I ran grub, and it 'crashed'!! I couldn't do anything so I had to reboot.

So here's my question: how do I recover what I've done? The drives aren't mounted, and there's no files. *confused again*

Dr Unne
02-26-2004, 03:35 AM
Your files are still there, you just need to chroot into your install. Something like this.

1) Boot from CD.
2) mkdir /mnt/gentoo (if it doesn't already exist)
3) mount /dev/hda3 /mnt/gentoo (hda3 being the root partition for your Gentoo install on your HD... yours may be different)
4) mount /dev/hda1 /mnt/gentoo/boot (hda1 being your boot partition for your Gentoo install on your HD, yours may be differentl)
5) mount -t proc none /mnt/gentoo/proc
6) mount -o bind /dev /mnt/gentoo/dev
7) chroot /mnt/gentoo /bin/bash (This will take you "into" your Gentoo install on your HD, as though you'd booted to it)
8) env-update (just in case)

If grub crashes again for some reason, you shouldn't have to reboot (and you really shouldn't ever do that, especially with something like grub that's editing your MBR :(). Instead hit CTRL+C to kill it. Grub shouldn't be crashing though. Something's not good, if it does.

Peegee
02-26-2004, 11:36 AM
What a timesaver :)

I finished all the steps, rebooted, removed the cd, and the computers starts spitting a continuous stream of GRUB...like

GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB

and so forth ad infinitum -_-

So where did I go wrong? When I boot from the liveCD what step should I go back to? I tried redoing the grub config...all the files are there, etc.

Endless
02-26-2004, 04:24 PM
You can try this:
http://mail.gnu.org/archive/html/bug-grub/2002-09/msg00118.html

(although I still think you should have used the stage3 for p3 if you haven't)

I also saw a page where someone said he installed Mandrake in it's minimal install, just to have grub put right, then went back to gentoo to finish the setup.

Dr Unne
02-26-2004, 06:30 PM
http://forums.gentoo.org/ is the answer to all problems Gentoo by the way. Search the forums, any question you might think of has been answered 10 times there.

Post your grub.conf here, maybe you have a typo. Also are you using RAID? Because that screws stuff up. I don't know how to configure grub or lilo to work with RAID.

Peegee
02-27-2004, 12:29 PM
Okay, I gave up on gentoo, and install the (rediculously) simple Lycoris Linux

xD

I just need this computer to have two programs: folding@home, and mozilla firefox. How do I 'install' firefox? I extracted the files, but the firefox exec file doesn't do anything (yes it has chmod +x)

pointless question: The install comes with mozilla, but the interface and icons look very much like netscape. In fact I think this is a netscape browser. Was mozilla in any way affiliated with netscape?

Dr Unne
02-27-2004, 05:29 PM
Installing programs is different for each distro. Look it up on the Lycoris website.

Netscape is based on Mozilla, yes. Netscape = Mozilla + crap.