Gentoo Archives: gentoo-user

From: Bastian Balthazar Bux <BastianBalthazarBux@×××××××××.it>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] TWO (probably stupid) questions about partitions
Date: Thu, 11 Aug 2005 21:21:59
Message-Id: 42FBC032.3020508@pnpitalia.it
In Reply to: [gentoo-user] TWO (probably stupid) questions about partitions by Fernando Meira
1 Fernando Meira wrote:
2 > Hi,
3 >
4 > this is how my disk is divided:
5 > Disk /dev/hda: 40.0 GB, 40007761920 bytes
6 > 255 heads, 63 sectors/track, 4864 cylinders
7 > Units = cylinders of 16065 * 512 = 8225280 bytes
8 >
9 > Device Boot Start End Blocks Id System
10 > /dev/hda1 * 1 1275 10241406 7 HPFS/NTFS
11 > /dev/hda2 1276 4208 23559322+ f W95 Ext'd (LBA)
12 > /dev/hda3 4209 4271 506047+ 82 Linux swap / Solaris
13 > /dev/hda4 4272 4864 4763272+ 83 Linux
14 > /dev/hda5 1276 4208 23559291 b W95 FAT32
15 >
16 > Now I want to clean hda1 (which has windows) and mount there /usr and
17 > point $PORTAGE_TMPDIR there (because my gentoo system, in hda4, run out
18 > of space). Once I'm doing this, I could split that partition into
19 > smaller ones (e.g. to create /boot), but hda1 needs to be Extended. So,
20 >
21 > 1. Can /boot be inside an Extended partition? Would probably be place in
22 > hda6...
23
24 Don't know
25
26 > 2. In case of not changing my boot config (my doing Q1), will I need to
27 > re-install my bootloader in MBR anew? Or on other words, will MBR be
28 > erased when cleaning hda1?
29
30 MBR is not erased, but it need to know where /boot is, whit grub you
31 need to repeat the
32
33 grub
34 root (hd0,x)
35 setup (hd0)
36 quit
37
38 phase.
39
40 Having different partitions for an home system (with the exception of
41 /boot in hda1 ) has always revealed useless for me.
42 Also allocating 100 Mb for hda1/boot your first partition is much bigger
43 than the actual "/dev/hda4" .
44
45 What about to move your entire system in that place ? When finished this
46 leave to you the entire space hda4 space and the choice of what to with
47 that.
48
49 The easyer way I know to to this is
50 1) have handy a bootable livecd/resque disk.
51 2) substituite hda1 with
52 - hda1 = "/boot" = 50-100 Mb
53 - hda2 = "/" = all the rest
54 3) mkfs.[your preferred] /dev/hda1
55 4) mkfs.[your preferred] /dev/hda2
56 5) Stop all services you can
57 6) mkdir /mnt/TheFuture /mnt/ThePast
58 7) mount -obind / /mnt/ThePast
59 8) mount /dev/hda2 /mnt/TheFuture
60 9) mkdir /mnt/TheFuture/boot
61 10) mount /dev/hda1 /mnt/TheFuture/boot
62 11) cp -a /mnt/ThePast/* /mnt/TheFuture/
63 12) check with "ls -al /mnt/ThePast/" if there are hidden file to copy
64 13) change /mnt/TheFuture/etc/fstab /boot/grub/grub.conf
65 14) rerun your bootloader install phase (if grub see before)
66
67 reboot
68
69 Try to boot each of your S.O.
70 Warning the previous mentioned hda1 may be called hdaX from the
71 partitioner, check it.
72
73 Hint, groub admit editing of the boot parameters pressing "e" key, may
74 be handy if there are any mistake in grub.conf
75
76 >
77 > Question extra :) : what tends to be bigger /etc or /usr ?
78
79 check it yourself
80
81 #du -sh /etc /usr
82
83 "usr" is the bigger partition in the system usually
84
85 >
86 > Thanks,
87 > Fernando
88
89
90 HIH, Francesco
91 --
92 gentoo-user@g.o mailing list

Replies

Subject Author
Re: [gentoo-user] TWO (probably stupid) questions about partitions Fernando Meira <fmeira@×××××.com>