File Management
Tags: beginners, productivity, discuss, computerscience
Published: 2023-02-28 18:28:57

## Why do we need File Management?

Research suggests that proper file management is crucial for organizing, storing, and accessing digital information efficiently and effectively, which is essential for effective work and productivity [2].

Effective file management can lead to optimized storage space utilization, as well as the regular backup and easy recovery of important files in the event of damage or loss. There are some key factors about the importance of file management, such as:

> **File Organization**
By organizing digital files into a structured and logical form, proper file management allows for a quicker access and make it easier to locate files.

> **Space Management**
Effective file management allows for more efficient storage management on the computer or other devices by regularly deleting unnecessary files, which is particularly scathing when working with limited storage capacity.

> **File Recovery** 
Through the implementation of proper file management, important files are regularly backed up so that they are easily recoverable in the event of data loss, damage, or corruption.

> **Collaboration**
Effective file management allows for easy and secure sharing and collaboration of files with others, without compromising the security or integrity of the files.

> **Security**
Proper file management allows robust security protocols to safeguard sensitive information and restrict access to important files to authorized personnel only. This protects valuable data from unauthorized access and also mitigates the risks of data breaches or cyberattacks.

As pointed out by [1], proper file management is important for organizing and securing digital files, optimizing storage space, and ensuring efficient and secure collaboration with others. In conclusion, effective file management can reduce the time needed on working with files, enhance productivity.

---

## Comparison Between FAT and NTFS

![FAT & NTFS Comparisons](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qw7hahbjttwydl892q9d.png)

---

## Tree-Structured Directory

As the name implies, a Tree-Structured Directory is a type of file organization system in which files are structured in a tree-like structure. Inside this system, the root directory is located at the top of the hierarchy, and all other directories and files are arranged beneath it in a hierarchical structure. Each directory can contain multiple subdirectories, and each subdirectory can contain additional files and directories [4].

![Tree-Structured Directory](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mnqcz2a50gf5unx1ee5s.png)
[Geeks for geeks](https://www.geeksforgeeks.org/structures-of-directory-in-operating-system/)

## Acyclic-Graph Directory

Also known as Directed Acyclic Graph (DAG) directory, is a file organization model that represents the relationship between each file in a graph form structure that is interconnected. According to [4], in a DAG directory, each file or directory is represented as a node in the graph, and each link between nodes represents a relationship between files or directories. This model is different to the Tree-Structured Directory in which a DAG can have multiple parent directories, where the Tree-Structured Directory can only have one. 

![Acyclic-Graph Directory](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sv67r72wbgzo8up113zz.png)
[Binary Terms](https://binaryterms.com/directory-structure-in-os.html)

---

## Exercise Practice Module

> Making a directory
![mkdir](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bbudwzhyctt1ryoqznrl.png)

> Creating an empty file
![touch](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/u41nylboc37b7qrrhr58.png)

> Writing a file
![nano](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7opmz2366e2opkvo8l7c.png)

> Instant write onto a file
![echo](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/z33cwupffugi1pdzyaya.png)

> Read file
![cat](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dn726h2zxy2i83cipmop.png)

> Delete file
![rm](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9jgqqe60g31zzuimtswy.png)

> Locate file location
![locate](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5hzggx5gll3v2efo9e71.png)

> Truncate file
![truncate](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iohg17ms2016fo1175du.png)

> Directory list
![pwd & cd](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x6xttjzhdtrydxvysdm6.png)

> Copy and cut file
![cp](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/w5tu9uvvwi2lldyekkhb.png)
![mv](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ak4zwnzzww1uwpiztcmu.png)

> Recursion
![rm -r](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6gzwcar30dcc640v6se6.png)

> Change access 
![chmod](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/18pfom7r8dz3pk5hjqti.png)

> Changing owner
![chown](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s7dywauuy9oxt0wqqfki.png)

---

## References
[1] Deepika, C., & Mukesh, K. (2016). Managing Digital Information: The Need for Effective File Management. International Journal of Science and Research (IJSR), 5(7), 2602-2605.
[2] Hussain, M., Fiaz, M., Ashraf, S., & Raza, S. (2017). A 
Comparative Study of File Management Techniques. Journal of 
Information Engineering and Applications, 7(2), 51-59.
[3] Johnson, R. E., & Hartmanis, J. (1990). A taxonomy of computer 
systems and their storage hierarchies. ACM Computing Surveys 
(CSUR), 22(4), 283-341.
[4] Satyanarayanan, M., Kistler, J. J., Mummert, L., Pillai, P., & Rosenblum, M. (1990). Integrated file and memory management in a client-server environment. ACM Transactions on Computer Systems (TOCS), 8(3), 238-265.
[5] Silberschatz, A., Galvin, P. B., & Gagne, G. (2018). Operating system concepts (10th ed.). Wiley.
[6] Zhang, J., & Qi, L. (2006). A new dynamic disk allocation 
algorithm based on LVM2. In Proceedings of the 2006 
International Conference on Computational Intelligence and 
Security (pp. 121-125). IEEE.

---