1 |
Am Thu, 1 Sep 2016 09:04:53 +0300 |
2 |
schrieb gevisz <gevisz@×××××.com>: |
3 |
|
4 |
> I have bought an external 5TB Western Digital hard drive |
5 |
> that I am going to use mainly for backing up some files |
6 |
> in my home directory and carrying a very big files, for |
7 |
> example a virtual machine image file, from one computer |
8 |
> to another. This hard drive is preformatted with NTFS. |
9 |
> Now, I am going to format it with ext4 which probably |
10 |
> will take a lot of time taking into account that it is |
11 |
> going to be done via USB connection. So, before formatting |
12 |
> this hard drive I would like to know if it is still |
13 |
> advisable to partition big hard drives into smaller |
14 |
> logical ones. |
15 |
> |
16 |
> For about 20 last years, following an advice of my older |
17 |
> colleague, I always partitioned all my hard drives into |
18 |
> the smaller logical ones and do very well know all |
19 |
> disadvantages of doing so. :) |
20 |
|
21 |
This has been a bad advice for at least the last 15 years when the last |
22 |
DOS-based machines died. |
23 |
|
24 |
The reasoning behind this: |
25 |
|
26 |
Hard drives are really bad at performance after the first third of |
27 |
storage space (do a benchmark, transfer speed will almost half). |
28 |
|
29 |
Next, how do you decide in front how big a partition should be? Your OS |
30 |
partition will become too small one day or another - your are going to |
31 |
put big files (swap files, program files) into the other partition. See |
32 |
previous point: This is the slow one. |
33 |
|
34 |
By this process, you will now artificially put a big gap into OS |
35 |
related files - this clearly counterfeits your original intention of |
36 |
keeping OS files close together. |
37 |
|
38 |
Most current OSes are good at keeping related files close together |
39 |
(except maybe Windows after a few Windows Updates runs, but there's |
40 |
software like MyDefrag to fix this and restore original performance), |
41 |
or there's technology to mitigate this issue (like bcache in Linux). I |
42 |
think even Windows has an optimization of allocating swap space nearby |
43 |
the heads current position, so swap fragmentation isn't even an issue. |
44 |
|
45 |
The advice which I was always given and refused, since more than 15 |
46 |
years: |
47 |
|
48 |
"But if you reinstall, you then don't have to restore all your |
49 |
data, and settings, and you can even install your programs to |
50 |
the other partition to not loose data and programs..." |
51 |
|
52 |
Sorry, bu****it. If you expect this to work (at least on Windows, but |
53 |
that's were the example is from), you will be really disappointed if |
54 |
you relied on that in case of a disaster: Windows simply stored all |
55 |
your settings and secret program data files on its C drive - which is |
56 |
gone. The installed programs are not there or do not work because |
57 |
Windows simply has no knowledge of them in the other partition after |
58 |
you reinstall, and even when you manage to start/reinstall them: Their |
59 |
state is kinda unknown or reset because "ProgramData" is missing. So |
60 |
this setup is a complete waste of performance and time. And there's no |
61 |
easy way to fix this. Tricks like symlinking C:\Users to another drive |
62 |
or use a submount are unsupported and updates will eventually fail to |
63 |
do this. |
64 |
|
65 |
I selected Windows here as the example because I expect the advice you |
66 |
mentioned comes from Windows installations. |
67 |
|
68 |
Linux, by design, works a lot better here. But still my advice is: |
69 |
Never ever partition for this reasoning. Even less, if performance is |
70 |
your concern. |
71 |
|
72 |
> But what are disadvantages of not partitioning a big |
73 |
> hard drive into smaller logical ones? |
74 |
|
75 |
Usually, none. At least for ordinary usage. Performance-wise it's |
76 |
always a better choice to use multiple physical disks if you need |
77 |
different partitions. A valid reason for separate partitions (read: |
78 |
physical drives) is special purpose software like a doctor's office |
79 |
software which puts all its data and shares below a single directory |
80 |
structure. |
81 |
|
82 |
> Is it still advisable to partition a big hard drive |
83 |
> into smaller logical ones and why? |
84 |
|
85 |
No. If you want it for logical management, there are much better ways of |
86 |
achieving this (like fs-integrated pooling, LVM, separate physical |
87 |
drives selected for their special purpose). |
88 |
|
89 |
Regarding performance: |
90 |
|
91 |
I wish Linux had options to relocate files (not just defragment) back |
92 |
into logical groups for nearby access. Fragmentation is less of a |
93 |
problem, the bigger problem is data block dislocation over time due to |
94 |
updates. In Windows, there's the wonderful tool MyDefrag which does |
95 |
magic and puts your aging Windows installation back into a state of an |
96 |
almost fresh installation by relocating files to sane positions. |
97 |
|
98 |
Is there anything similar for Linux? |
99 |
|
100 |
|
101 |
-- |
102 |
Regards, |
103 |
Kai |
104 |
|
105 |
Replies to list-only preferred. |