Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi
I am trying to install debian in my computer. I am in the process of partitioning my hard drive. Currently, I have windows xp installed. The following is my current partition structure
1. bootable, primary, NTFS 20G
2. , logical , NTFS 20G
3. free 40G
From my understanding after reading the manual, I am suppose to create small partitions for each hierarchy and a swap partition. So I have done the following
1. bootable, primary, NTFS 20G
2. , logical , NTFS 20G
3. ,primary, Linux 120M -- root
4. ,logical, Linux 600M -- usr
5. , logical, Linux 200M --home
6. , logical, Linux 4G --var
7. , logical, Linux 50M --tmp
Then I wrote my table structure into partition 3 and exit the partition process. But I keep getting the message that the swap partition does not exist.
So my question is how am I suppose to create my partiton???
how can I create a / partition and a swap partition? I can only specify the size and the type of partition. I don't think I can crreate a name for a partition.
Also, am I suppose to create more than one extended partitions? how can I do it??
run cfdisk just type cfdisk from the console, and enter on the partition you want to be as /
then enter the partition you want as /swap
then on the swap partition, go to type on the menu, toggle with left/right and enter, then put in the value number that is listed as swap, then go to write, note the name of the partition hda2, hda3, or whatever for swap, and type swapon and whatever name you have for swap. swap space should be equal or double the size of your ram.
BTW; What do you mean by name of the partition, this is done automaticly..
You cant have more then four logical partitions on a primary, so my suggestion is:
1. bootable, primary, NTFS 20G
2. ,primary, Linux 120M -- root
3. ,logical, Linux 600M -- usr
4. , logical, Linux 200M --home
5. , logical, Linux 4G --var
6. , primary , NTFS 20G
7. , logical, Linux 50M --tmp
8. , swap , if 512 ram, put something like 200 or so.
Swap partition should be on the last primary...
In my opinio, you dont need that many partitions;
one for boot,one for root and one for home should do.
Having one for usr will just take up your free space, cuz you dont really know what you're gonna install anyways...
And of chource the rest of your winnt...
I have installed my windows xp in my bootable partition and I have a lot of files in my other NTFS partition. if I do a "Write" table structure and create all the other partitions, will it erase all my existing files?
Dont know how your installer works, it might have a nice gui frontend, if not, go for cfdisk, much easier than fdisk, but as i said, none of the partition proggies will erase things you haven't touched...
tiger99 - based on your comments you have an 80G drive. Currently you've got 2 partitions for Windows, one primary and one logical, each 20G, for a total of 40G, with the remaining 40G being free space. Let's also assume that you want to create a swap, /, /home, /usr, /var, and /tmp partitions.
You can only define up to 4 primary partitions on a hard drive, and if you need more than that, you can define up to 3 primaries and 1 logical. All the additional partitions would be created within the logical partition. As dslboy states, the cfdisk tool is great for this task, and if you've got 40G to work with, I'd suggest considering the following:
1. Create a new primary partition for swap of either 256Mg or 512Mg. In cfdisk, swap is type 82.
2. Create a new logical partition for the remainder of the disk. The file type is Linux Native, type 83.
3. Within this new logical partition, create:
/ = 12G
/usr = 10G
/var = 2G
/tmp = 2G
/home = 14G (whatever's left)
Your /home directory is where all your data lives, so you want it to be big. The 200Mg you listed originally would be way, way too small. Note that all these partition sizes are just what I'd use - you should feel free to use whatever sizes you think are appropriate. Note also that if you ask 50 people how you should partition your disk, you should expect to get 50 different answers.
I was trying to do what JW said
So, after my 2 existing partitions
1. bootable, primary, NTFS
2. ,logical, NTFS
I tried to create a primary linux partition first then a logical partition
But after I created the primary partition, it woundn't let me create logical partition. It only let me create another primary partition. And it showed that the rest of my space is unstable.
however, if I created a logical partition first, it would let me create a primary/logical after that. but I dont think I should do that
I am so confused....
Also, how can I divide the logical partition into smaller partitions??
Hmm, just make another primary, then logical, it doesn't really matter, as long as you dont get confused..
If you need to divide a partition that you can't erase, you need a more powerful tool, like partition magic or something. If not, simply enter the amount of disk space you want on thoose partitions.
You can't make ntfs partition bootable!
If you have a 80gig disk, I would consider this:
1: Whatever space you need for ntfs.
2: root (/) partition; at least 5 gig
3: swap (/swap) partition; at least or twice the amount of your ram.
3: home (/home) partition; the rest!
This is ideal because:
1. You don't know how much space you will need for /usr, so it's best to leave it at the root (/)
2. Don't mix linux with nt or fat! You don't actually need a boot partition, cuz it's only gonna be small text-based files running on it anyway so it's safe to also leave this at the root (/)
Ntfs is ntfs, so leave it.
make root partition primary, home partition logical, and swap swap
Try this, and if something happens, just give us a wink.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.