# What Went Down in the First Class

It was definitely a fun filled session with **Dr. V. Sankaran**.

For starters. I started taking this course from IITM Pravartak on **Applied Database Systems Engineering**. This series will include the learnings, thoughts and experiences from the course.

Link: [https://iitmpravartak.org.in/ADSE](https://iitmpravartak.org.in/ADSE)

## What went down?

A little bit of philosophy along with a whole lot of linux. While we were deep into the ocean of processes a linux system has to handle, I was enlightened by this phrase.

> ### Everything has a priority and everyone has a preference.

That hit hard. But don't worry I'm not going to be your philosophical friend today.

So processes have both a **priority** and a **preference**. Just because a process has a higher priority doesn't mean it will get to run first. The kernel has a preference.

For instance, a process with **High Computation** requirement can have a **higher priority** but the kernel will likely choose to give CPU time to a smaller process like a **print job** with **lower priority**.

*No, the printer didn’t bribe the kernel.*

This is because running the print job will only take a very small time on the microprocessor and hence, the kernel (essentially the scheduler) will have one less process to take care of in the process queue.

It’s not all black or white but linux tries to be [fair](https://docs.kernel.org/scheduler/sched-design-CFS.html) here.

Oh! to be very clear, when and for what time a process gets to use the microcontroller is determined by 3 values: **Preference, Realtime Priority and Nice Priority**.

And…

That’s all lads. That was the first class. I swear Dr. Sankaran’s class was way more fun than what you just read.

We then went on to understand what the course will offer and the details about how we are going to play around with the linux kernel and kernel modules. Oh! I might need to brush up my C language. Every ounce of code that we write in this class will be in C. Okay, I am excited!

Sure then, I’ll be back after the next class to share what I’ve learned. Until then, **happy hacking**.

*Quick Note: some of the keywords used above may not be the actual component or field names used in the linux kernel but they should give you an idea about what exists in the kernel.*
