Posts

Showing posts from December, 2024

8th Week: CTS 334

Wow our last week at CTS 334, As we approach the end of the course, we can reflect on this week's topic, which focused on persistence as it applies to operating systems. However, this concept can also be viewed in the context of us as students in the Online Computer Science program. In operating systems, persistence makes sure that data outlives the processes that create it, using things like the file system to write data onto hard drives and SSDs. This allows data to remain persistence even after the computer shuts down. In a similar way, students demonstrate persistence by tackling everything from understanding complex topics to staying focused on the ultimate goal of completing the program. We endure life’s challenges, from balancing work and family responsibilities to completing assignments. This persistence reflects how the operating system preserves data, ensuring it remains intact and accessible despite interruptions. As we finish this course and this year, we carry forward ...

7th Week: CST 334

Hello everyone: This week we covered CST 334 Topic: Persistence, which includes concepts such as I/O Devices, hard disk drives, RAID, files, directories, and file system implementation. I/O devices involve system architecture and methods to communicate with devices like polling, interrupts, and DMA to move data. Device drivers control the details of device communication so the operating system can focus on other tasks while the driver handles that part. Hard disk drives have been the primary form of persistent data storage in computers for a long time. Modern drives consist of sectors, which are blocks of memory typically 512 bytes each, that can be read or written individually. A disk is essentially an array of these sectors, ranging from zero to a maximum number, with each sector representing an addressable space. Updates to disk must be atomic. RAID stands for Redundant Array of Inexpensive Disks that offers good reliability and performance by distributing data across multiple d...

6th Week: CST 334

Hello everyone, This week we learned about semaphores. They are a key synchronization tool for managing concurrency in multi threaded programs. A semaphore is a variable that controls access to shared memory through atomic operations. Its main functions are sem_wait(), which decrements and blocks other threads if the semaphore's value is zero, and sem_post(), which increments and unblocks, allowing another thread access to the shared memory. Semaphores, if used with reader/writer locks allow multiple readers while blocking writers. However, they must be used carefully to avoid bugs like deadlocks and race conditions.  In Lab 6, we used semaphores to solve the producer-consumer problem by signaling between producers and consumers to keep track of the buffer's state when it was empty or full.  Correct semaphore use allows threads to work safely within critical sections.