Sunday, April 28, 2024
8
rated 0 times [  8] [ 0]  / answers: 1 / hits: 6505  / 3 Years ago, wed, september 22, 2021, 4:26:26

I have a 320GB hard disk. I only use either ubuntu or kubuntu (12.04 for now). I don't want to use windows or any other dual boot os. And i need only 3 partitions on my hard disk. One for the OS and remaining two for data storage. I don't want to create swap also.



Now can i create all primary partitions on the hard disk. Are there any disadvantages in doing so. If all the partitions are primary i think i can easily resize partitions in future.



On second thought i have the idea of using seperate partition for /home. Is it good practice . If i have to do this, i will create 4 partitions all primary. In any case i don't want to create more than 4 partitions . And i know the limit will be 4.



So is it safe to create all 3 or 4 primary partitions. Pls suggest me, What are the good practices .



(previously i used win-xp and win-7 on dual boot with 2 primary partitions and that bugged me somehow i don't remember. Since then i felt there should be only one primary partition in a hard disk.)



EDIT 1 :
Now i will use four partitions in the sequence - / , /home , /for-data , /swap . I have another question. Does a partition need continuous blocks on the disk. I mean if i want to resize partitions later, can i add space from sda3 to sda1. Is it possible and is it safe to do ?



EDIT 2 :
I have created 4partitions - ( / , /data1 , /data2 , /swap ). The first three partitions are of type ext4. Now the /data1 and /data2 partitions have root account as owner. I must have root permissions for copying normal files to those partitions which might be little inconvenient. What should i do ?? Shall i just take the ownership of these partitions and chmod them to 644. Will this work? "chown user:user /media/data1" and then "chmod 644 /media/data1/*".


More From » partitioning

 Answers
4

In principle there is no problem with all 4 primary partitions. Some of the new computers are shipping with 4 primary partitions. The main concern is, you will have no option to make any more partitions, in case you need one more.



Even though computers these days have enough RAM to run Ubuntu, the operating system has roots in older time when a swap partition was a must. So even though you may not need it, it is a good idea to have one. It will make the system feel happy.



A separate /home partition is actually an excellent idea. I put it in all my Ubuntu installs. This makes fresh installs of new versions dead simple. Sometimes upgrades from the previous versions don't go well. At other times, after four or five upgrades on top of one another, the system gets cluttered with stuff you don't need and a fresh install is the solution. In these situations a separate /home partition makes it easy to retain your personal data and settings while starting afresh with a new system install.



So if you go with /, /home, and swap you still have space for one more primary partition for data.



The partitions need not be in continuous blocks. You can leave unallocated spaces in between. For example, if you leave some unallocated space in between sda3 and sda4. You may later expand sda3 or move sda4 to the left and then expand sda4.



However, when the partitions get very full, there may not be enough space to copy files over for moving partitions. Then you won't be able to move them around. So, it may be better to adjust your partitions sooner than later.



Even though I don't remember the last time I had my data erased or corrupted by fiddling with partitions, it can happen. Sometimes it is operator error, that is, I make the wrong choice. Thus, it is very very important to backup everything in another hard drive before embarking on any kind of partition re sizing, moving, and deleting.



Hope this helps


[#34963] Thursday, September 23, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
altybol

Total Points: 364
Total Questions: 138
Total Answers: 121

Location: France
Member since Thu, May 6, 2021
3 Years ago
altybol questions
;