Printer Spooler Problem | Operating System - M03 P03
Rahul Mishra
Posted on December 1, 2020
This is a multipart blog article series, and in this series I am going to explain you the concepts of operating system. This article series is divided into multiple modules and this is the third module which consists of 10 articles.
In this article we will discuss about printer spooler problem, and how can we overcome that problem.
Printer spooler problem
- As we know that printer is a peripheral device, so it is slower in comparison of CPU and memory.
- So, if multiple users send some file to printer to print then spooler comes into play.
- Spooler is a program in printer which stores all the files coming to print and when printer is free it gives it to the printer in sequential manner.
This four line code is executed by each process in order to store its file in spooler directory to print.
Load Ri, m[in]
store SD[Ri], "F-N"
INCR Ri
store m[in], Ri
in: Shared variable
m: Memory location
Ri: Register
F-N: File name
SD: Spooler directory
-
Line 1: In line one we are loading free memory location
m[in]
, in registerRi
-
Line 2: In line two we are storing file name (F-N) in spooler directory (SD) at position
Ri
, which is for instance0
-
Line 3: In line three we are incrementing the count of
Ri
from0
to1
, so next file can be stored in at index1
-
Line 4: In line four the new file will be stored at incremented memory location
m[in]
So this was all about printer spooler problem. Hope you liked it and learned something new from it.
If you have any doubt, question, queries related to this topic or just want to share something with me, then please feel free to contact me.
📱 Contact Me
Twitter
LinkedIn
Telegram
Instagram
📧 Write a mail
🚀 Other links
Posted on December 1, 2020
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.