How can I create extended partition without GParted?
Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
You can do it with cfdisk too but it doesn't have a facility to create one. However the first logical partition created the next primary partition slot, first one of sda1 to sda4 or hda1 to hda4 that has not been used, will be converted to the "extended partition". It is far better for the understanding of how an extended partition works.
Extended partition has no usable storage of its own. Users only store data in logical partitions. The extended partition is just a "border" defining the first sector of the first logical partition and the last sector of the last logical partition.
If you use terminal partitioning tools you can understand better how partitioning works. Gaparted actually does formatting in the same process so it complicates the matter.
The reason I am doing this is because I have 4 primary partitions,and I want to be able to boot some more OS-s,and the only way to do this is(I guess) by creating extended partition under primary partition.I don't have fdisk or cfdisk installed.I was looking for a way to do this from a CLI without any program,just simply by entering commands,can I do this?
Last edited by alan_ri; 02-10-2008 at 06:05 AM.
Reason: (I guess)-forgat to say that
Thanks for the explanation syg00,I never used it so I did't know if it is program or command,but I remember when installing some OS it prompted me with that if I wan't to boot it I had to make extended partition under primary one,but did't suggested that I have to delete primary partition(there was 4 of them),and I don't wanna do that if it's possible.
Doesn't need root, just need the proper pathing - Fedora do stupid things like that. Should work as "/sbin/fdisk ...".
There are commercial (Windoze) products (Partition Magic I would guess) that can convert one of your primaries to an extended. To do it manually you really need to back the data up and delete, allocate as extended (or logical if using cfdisk) and bring the data back. Parition number will change - can cause grief depending on your setup.
Also there can be issues of broken areas of free space being inaccessable - but that is no more likely than your present arrangement.
Anybody can run "/sbin/<command-name> ..."
Security by obscurity ??? - nah, that's stoopid.
Ubuntu are equally (more) ludicrous - "fdisk -l" returns nothing; no message, nada.
"fdisk /dev/sda" gets "Unable to open /dev/sda". That at least hints at the solution - you need to use sudo. Everybody (on standard install) probably has access to everything via sudo.
And how is that different from everyone having access to everything using su -? If anything, sudo is the more flexible solution. The administrator can set up access to all, some or none of the potentially dangerous commands - and do that in a matter of seconds.
Also, security through obscurity is more helpful than you seem to think. Few administrators, regardless of OS, would fancy giving away what is installed or not. Sure, obscurity alone won't cut it but it is part of a good security policy.
It is here,now.Ok,my device is /dev/hda,and when I type: fdisk /dev/hda,this is what I get:
[root@localhost alan]# fdisk /dev/hda
The number of cylinders for this disk is set to 9729. There is nothing wrong with that, but this is larger than 1024, and could in certain setups cause problems with: 1) software that runs at boot time (e.g., old versions of LILO) 2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK)
Unable to seek on /dev/hda
Can you tell me what are the next steps to create that extended partition,or maybe I shouldn't,cause maybe I wan't be able to boot from there or will I?Also,why is there limitation with 4 primary partitions and what has to be done to have 10 OS on one HD?
Last edited by alan_ri; 02-10-2008 at 07:18 AM.
Reason: I had no script enabled