Is there any benefit to partioning hdd data-only disk?

I have a newly formatted ext4 1TB HDD that I intend to use only for data. This is a single user machine though the drive or folders within it may be shared out via NFS .

Is there any advantage to partitioning the drive?


Solution 1:

One ext4 partition will suffice. You can assign folders within it with differing rights in case you have multiple users.

Solution 2:

No Partition or 1 Partition?

It is possible to format the whole disk without any partition and without any partition table.

However, it is recommended that You have at least one partition covering the whole disk. See answers to How do I add an additional hard drive? in this site for other examples of creating a single partition covering the whole drive.

I suppose you want to know the advantage of having more than one partition in this data disk. Here are some advantages:

Multiple Users

Let us suppose my wife is a telenovela fan and wants to setup a way to download 6 episodes every week. My son is a gamer and wants to save his steam game data in the extra drive.

If I have only one partition in a few weeks the partition will be full of TV episodes and my son won't be able to save his game or vice versa.

One solution is to create two partitions. Even if the Telenovela partition is full the game-data partition will have space and the other way around.

There are other ways of assigning disk quota to users: Using 'quota' for disk limits that does not require creating multiple partitions.

Second Drive as a File Server

This use-case is similar to above, but instead of having multiple local users, you have other users who use the data drive as a network drive and dump their data in this drive. Even though there are ways to manage network data storage quota in a file server, you may want different partitions for different network users.

Partitions v Quota

Using user and or group quotas for local or remote users' data needs is the "proper" way to go about it. However, setting it up may be daunting to new users especially those who are not familiar with the command line. One advantage of this approach is one can change the quotas without messing with the partitions.

On the other hand, setting up the new disk with two or more partition seems easier especially with a GUI application like Gparted. You don't have to learn and remember new commands. On the negative side, if you need a different quota assignment, you have to resize the partitions which always involves a risk of data loss resulting from mistakes or power failure etc.

Single User

It is harder to think of a situation where a single user may need two data partition, but it is not impossible.

One possibility is you are working on two different data intensive projects and one of them may generate huge amount of data filling up the whole disk. If that happens the code for that project will stop working at the same time the second project will also fail if the data from two projects are not in separate partitions.

Hope this helps