# Managing disks is mainly done through the disk management tool that comes with Windows.
Disk management is a common task when using a computer. It is located in the "Computer Management" console and includes error checking programs, disk defragmenters and disk defragmenters. Management applications are provided to users in the form of applications. (Recommended Learning: PHPSTORM )
## After knowing the cause of disk fragmentation, we also need to understand the read and write action of the disk when the program is running. Generally, when running a program, the work of the disk drive head is to first search for the files necessary for the program to run, then read the data, and finally do post-read processing - transfer the data to the disk cache ( Cache) and in memory. The search time is called the average seek time (Averageseektime) in hard disk performance indicators, and the unit is milliseconds (ms). The average seek time of mainstream hard disks is less than 9.5ms. If the application-related files can be placed in contiguous space on the disk, the head search time will be reduced a lot.In fact, disk fragmentation should be called file fragmentation because files are scattered and saved in different places throughout the disk instead of being continuously saved in continuous clusters on the disk.
When the physical memory required by an application is insufficient, the general operating system will generate a temporary swap file in the hard disk, and use the hard disk space occupied by the file to virtualize it into memory. The virtual memory management program frequently reads and writes the hard disk, generating a large amount of fragments. This is the main cause of hard disk fragmentation. Others, such as temporary files or temporary file directory settings generated by IE browser when browsing information, will also cause a large number of fragments in the system.File fragmentation generally does not cause problems in the system, but too many file fragments will cause the system to search back and forth when reading files, causing system performance to decrease, and in severe cases, the life of the hard disk will be shortened.
In addition, excessive disk fragmentation may lead to the loss of stored files.The above is the detailed content of What is the main way to manage disks?. For more information, please follow other related articles on the PHP Chinese website!