View Full Version : Partitioning for Knoppix only

01-03-2005, 02:44 AM
Hi, thanks for this great board, I decided to finally dive into Linux and for this purpose to dedicate my old Laptop, Celeron 400 Mhz 64M Ram entirely to Knoppix, that means a HD install. The live CD works without problems (with swap file) but very slow, so I definitely want it on the HD - here is my problem:

I formatted my harddisk (with windows 98 cdrom) because I thought this would be enough preparation to install Knoppix. Of course I was wrong since knoppix asks for special partitioning. So I tried it with Qparted and cfdisk, which also didnt work, it didnt write my new partitions (hda1: Linux bootable hda2: Linux swap) for some reasons, maybe I just didnt use the programs right but I dont think so - it always stayed on windows fat32.

So I went radical and wiped the complete HD with zeros, as suggested in another thread. But now of course I couldnt even start Knoppix with KDE because I needed a DOS Swap file (because of low RAM) - but no problem, there still is the shell.

So I finally tried to make partitions with fdisk, which finally worked, but still the knoppix installer says that there are not the appropriate partitions. So I am confused, what does the partitioning has to look like with fdisk so that the install is possible?

I have it something like that: /dev/hda1 bootable Linux from Cylinder 1 to Cylinder 500
/dev/hda2 Linux swap from Cylinder 501 to Cylinder 726

The HD has 6GB.

Am I gone totally wrong??? If so please tell me! I have no idea, no experience with Linux and any suggestion would be highly appreciated! Thanks!

01-03-2005, 05:23 AM
I have it something like that: /dev/hda1 bootable Linux from Cylinder 1 to Cylinder 500
/dev/hda2 Linux swap from Cylinder 501 to Cylinder 726

The HD has 6GB.

1 to 500 for linux & 500 to 750 for swap should be about 4 gig for linux & 2 gig swap; no way you need 2 gig swap. 500 Meg should be plenty.

but it should still work.

Please post what cfdisk says you now have for partitions.

01-03-2005, 05:37 AM
Thanks for the quick reply! Well I thought about that the partitions may be too big, but I also tried a swap partition of only 150 megabyte and it didnt work....

Cfdisk shows basically exactly the same as fdisk...
Its also no problem to change the partitions with Cfdisk.... so really no difference there...

I tried all sort of combinations - can you tell me what "exactly" the partitions should look like? One Linux (83) and one Linux swap (82) should be alright? :roll:
Also could you tell me what kind of partition Knoppix wants for a DOS-Swap file? I tried all sorts of (DOS R/O, FAT32) and it didnt like it...

But one thing is odd, when I tried to change the partitions with Qparted it didnt work: When i tried to "execute" (Durchführen german version) it, it brought me an error message. Unfortunately I cant remember how the message exactly was, but if thats important I will post it tonight since I got to sleep now! (I am a nightshift-slave)

Thanks again!

01-03-2005, 06:09 AM
Howdy free,

I'll have to read this a little more fully, but partitioning isn't such a deal really.

I'm surprised that the Knoppix install dosen't have a facility for partitioning built in. But, then, my install was a direct copy from the ramdisk image, so i can't say much there.

Could you post the output to the following please:

]# fdisk -l /dev/hda
]# fdisk -lu /dev/hda

From a root shell, the full output ... there will
probably be something quite straight forward
behind the problem.

What you mention as "you zeroed your hd" disturbes
me a bit though.

What did you actually do there ?

Yes, a standard Linux partition will have an "id"
of 0x83, and swap will have 0x82.

On the swap, it all depends on how much virtual memory
you think you may need. The more ram you have, the
less swap will be utilised of course. But, remember,
it is not uncommon for a process to make quite large
requests for VM. Previously, the kernels' policy was
to let it go. In that, as the allocation would
likely not be used anyway, it was not uncommon for VM
to be over allocated.

If you intend to use the v2.6.9 and above kernels though,
thats all changed. If the VM has been all allocated,
an over allocation won't be made if requested. Instead
the kernel will look for, what it determines to be,
the least important process, and send it a SIG TERM.
That will likely be the last process to try and make the grab :).

If it crops up at all, it will likely involve a
process that makes large VM requests as part
of its' normal operation. Such as imaging tools,
compilers, or running a site like this.

It has caught me recently using 200Mb's swap on
a low end box.

500Mb's should be OK, but it will depend on what you
use the box for really. The old addage "twice the ram"
dosen't apply anymore, it really does belongs to a
different era :)

I wouldn't go below 500Mb's.


01-04-2005, 12:05 AM
Thanks very much for the informative post, here is the requested output of:

# fdisk -l /dev/hda

Platte /dev/hda: 6007 MByte, 6007357440 Byte
240 Köpfe, 63 Sektoren/Spuren, 776 Zylinder
Einheiten = Zylinder von 15120 * 512 = 7741440 Bytes

Gerät Boot Start End Blocks Id System
/dev/hda1 * 1 400 3023968+ 83 Linux
/dev/hda2 401 776 2842560 82 Linux Swap

#fdisk -lu /dev/hda

Platte /dev/hda: 6007 MByte, 6007357440 Byte
240 Köpfe, 63 Sektoren/Spuren, 776 Zylinder, total 11733120 sectors
Einheiten = Zylinder von 1 * 512 = 512 Bytes

Gerät Boot Start End Blocks Id System
/dev/hda1 * 63 6047999 3023968+ 83 Linux
/dev/hda2 6048000 11733119 2842560 82 Linux Swap

I hope this tells you anything useful...
I also turned the DOS compatibility flag on and off, both didnt do anything noticeable.

Regarding the zeroing out: Embarrassingly enough I cant remember the exact command nor can I find the thread here where it was written in, but I think it was a "cat" command...
It seemed to work fine - it terminated exactly like described, that is with the message that it cant write no more blabla...

01-04-2005, 03:11 AM
Hmm just as I am writing this the install process is running. Why it works now? I have no idea.

What I did is this: I formatted the harddisk again with the windows 98 cdrom. Then I partitioned the harddisk with fdisk to three partitions: one linux, one linux swap, one win95 fat 16. Still the same error message when I tried to run the installer. But then qtparted came up and showed me that alledgedly there where 3 partitions, but like this: one windows fat32, and 2 unknown. So i tried to partition it again with qtparted, and although it issued a couple of strange messages in the end I had one linux and one linux swap, and the install process was up and running. Why????

Wait, there is one difference I noted. When I started the knoppix-installer I was in shell root@ttyp0[knoppix]: instead of root@ttyp0[/]. I came there with typing "su" instead of Ctrl-Alt-F1. Does this make any difference?? Sorry if this seems dumb, but I am Linux-noob-as-can-noob-be!!! :oops:

01-04-2005, 02:01 PM
Free, I've had that same problem, can't install from the ctrl-alt-F1 konsole. I now always use a konsole from within kdm. I don't know why either but that is the way I do it now.

01-04-2005, 08:46 PM
Anyway thanks very much for the help, it works now and knoppix is running. Well it doesnt seem logical that Ctrl-Alt-F1 doesnt work, but who ever said that machines have to do with logic? It's more like voodoo.... :shock:

I ran qparted again from the now installed knoppix and it still said (in the shell) that there is something wrong with my partitions/filesystem but that its not critical. It said I should run e2fsck which seems to be some repairing tool, so lots to explore... 8)

01-04-2005, 10:15 PM
Hi Free,

You shouldn't really need to zero your drive to do
an install. I was thinking that you may have done a low
level format and screwed the disk as a result. There's
stuff the factory put on a disk as part of its' manufacture,
that will wreak it if
its not there :)

Yes, thanks for the dump, it is useful. It appears to
be a round 6Bb's.

Wait, there is one difference I noted. When I started
the knoppix-installer I was in shell
root@ttyp0[knoppix]: instead of root@ttyp0[/].
I came there with typing "su" instead of Ctrl-Alt-F1. Does this make any difference??

I sounds like you may have been trying to install
from your user account, rather than as "root". Due to the
low level, and potentially damaging access needed to
effect an install, one requires "root" privaledges to
do it. Which is basically the case during a cdrom boot
any way.

I was thinking initially, that the installer was bailing
out because it couldn't find a file system on the newly
created partitions. Which would have been really
strange, and a deffinite installer bug.

But it seems it's worked :).

You don't say how or what or where you boot knoppix's
boot loader. I would assume it was the MBR. Not my
favourite spot, but, what the heck :).

If it is on the MBR read up on your man pages and other
docs to find the correct way to uninstall it, if
ever you should decide on such a terible thing.
It will make the process of booting back into your Win OS a lot smoother.

As it is now, if it's on the MBR, the active flag
in the table wont do anything. It will use its'
config mappings to determine what to boot and what
not to.

You mention a Win partition. I lose you there a bit, i'll assume there''s two primaries.

I would have made a 500Mb or 1Gb swap as the first
partition. Then an extended.

The first logical would have been a 4Gb Linux partition.

I probably would have made the rest a second logical.
And formated it with "mke2fs", or whatever fs
formatting tool you prefer. To use as a back up, archive

Then i could install the first stage linux boot
loader to sector 0 of the extended. And then just set
the extended active from linux for a clean boot.
Point being, it makes it easier to reverse, and avoids
a lot of Win conflicts that can crop up at times.

I should run e2fsck which seems to be some repairing tool

Yes do that. Boot into a rescue floppy, or type
"single" at the prompt. It just wants to run a maintence
pass over your fs. Best done on an unmounted fs.
Though you didn't say what fs you were using ???.


01-09-2005, 05:09 AM
Thanks for the detailed answer and the advice! Yes I put it on MBR! Of course I won't consider removing knoppix, it's great! 8)

The windows partition I only had for experimental purposes, it seems illogical but one thing I have learned with computer problems that at some point one has to try out all sort of crazy things - the result can both be monstrous or nice, just like evolution... :roll:

Now I have made a third Linux partition out of it with Qparted. Filesystem is ext3 according to Quparted. I also considered it to be a bug of the installer, but since Qparted keeps giving me error messages about "strange filesystems" it's definitely something with the harddrive. I would reproduce the error-messages if I could, but at the moment I dont dare to fiddle around with it... I will do that with the floppy and e2fsck though...