File System, C language
$30-5000 USD
Paid on delivery
File System on Linux server (user level emulation). FAT16
<colgroup> <col width="66" /></colgroup>
| 1 MB |
| 10 KB |
| 256 Bytes |
(10KB) to run and optimise file system
file system should be optimized for general purpose use, on a 1MB storage device
block size of 256 bytes, and have a RAM footprint of 10K
time it takes to read and write to your hard disk, and to allocate and free dynamic memory In ***required***to use the library provided to emulate the Hard Disk, and to provide memory allocation.
***not***permitted to use malloc(), free(), open(), fopen() or any other memory or file management calls
**Hard Disk Emulator**
a C library containing functions that will emulate the Wintend Pii's hard disk [url removed, login to view] **pii.o**.
This is an **object file**- a set of C functions defined and documented in the [_**pii.h header file**_][1].
implementation of file system **my_fs.c**
as a library for other C programs to use
need to make use of multi-threaded programming **pthreads**.
including threads, semaphores &mutexes.
**API for File System**
[_fs_api.h_][2].
a list of system calls that file system should support
FAT16 solution
## Deliverables
FAT16 solution must:
* Use the pii.o library to provide the storage for file system
* Adhere to the API listed in fs_api.h
* Stay within the 10K RAM limit for data
* Use only the fs_malloc() and fs_free functions in pii.o to provide dynamic memory allocation (no new, malloc or free!)
* Do not use any file or memory related UNIX system calls (open, close, etc.)
**Task 2: Formatting.**
Write the fs_format() function in library that will format the virtual hard disk in accordance with fat16
**Task 3: Free Block Tracking.**
, implement chosen method of free block tracking. Write two functions in your library, one which allocates a new block to use from those available on the disk, and another which releases a given block and returns it to the list of available blocks. Ensure that read and write the free block data to and from the virtual hard disk in accordance with design.
**Task 4: Directory Structure.**
implement your chosen method of maintaining the list of files in a directory. Create a root directory for your file system, and complete the create_directory() function. Extend your test application to allow directories to be created. Implement the fs_get_directory_listing function and extend your test application to allow it to display the contents of a given directory.
**Task 5: Files**
Complete the create, delete, open, close, read and write functions in line with your design. Use test application to make sure can accurately read and write files. files can be longer than one block in size, and need to record the file length somewhere... Also, an application may have more than one file open at a time, so use of those 'id' fields in the API...
**Task 6: Optimization**
dealing with concurrency
* The Pii hard disk drive will perform better when accessing consecutive blocks on the device. Improve your overall performance by ensuring the device's request queue is full of requests for consecutive blocks where possible.
* The memory allocation and freeing time on the Pii is very slow. Take advatage of caching and buffer pooling techniques to reduce the number unecessary access to the disk and memory allocation routines.
* Take advantage of concurrent reader threads to the file system, possibly on the same file. remember, it is perfectly safe to let an infinite number of threads read from the same file at the same time, but writers must be isolated
## Platform
needs run on unix platform
the pii.o file is not present
the my_fs.c is already started
im doing a fat16 implementation
need the functions in that file written in accordance with the spec
DEADLINE IS FRDIAY AM
Project ID: #3461795