This project was an assignment for the Operating Systems class at the University of Victoria. The programs diskinfo
and disklist
will return information regarding the file system superblock, FAT, and directory content, with diskget
allowing users to copy a file from the file system root directory to the current directory.
make
make clean
Display information about the file system super block and FAT.
./diskinfo.o test.img
Super block information:
Block size: 512
Block count: 6400
FAT starts: 2
FAT blocks: 50
Root directory start: 53
Root directory blocks: 8
FAT information:
Free Blocks: 6192
Reserved Blocks: 50
Allocated Blocks: 158
Display content for the file system root directory.
./disklist.o test.img /
F 735 mkfile.cc 2005/11/15 12:00:00
F 2560 foo.txt 2005/11/15 12:00:00
F 3940 disk.img.gz 2009/08/04 21:11:13
Copy a file from the file system root directory to the current directory. If the specified file is not found in the file system, an error message will be displayed.
./diskget.o test.img mkfile.cc foo2.txt