📜  分时操作系统和多道程序操作系统的区别

📅  最后修改于: 2021-09-28 10:22:53             🧑  作者: Mango

先决条件 – 不同类型的操作系统

1. 分时:
分时是多道程序的逻辑扩展,在这种分时操作系统中,许多用户/进程在各自的时隙中分配了计算机资源。在这种情况下,处理器时间与多个用户共享,这就是为什么它被称为分时操作系统。对于不同的过程,它有一个固定的时间片。它的主要目的是交互式响应时间。

分时操作系统的好处:

  • 快速响应。
  • 减少 CPU 空闲时间。
  • 所有的任务都有特定的时间。
  • 减少软件重复的可能性。
  • 提高响应时间。

分时操作系统的缺点:

  • 它消耗大量资源。
  • 需要高规格的硬件。
  • 它存在可靠性问题。
  • 安全和完整性问题。
  • 数据通信问题的概率。

2. 多道程序:
多道程序操作系统允许通过监视进程状态并在进程之间切换来执行多个进程。在这个处理器和内存使用不足的问题得到解决,多个程序在 CPU 上运行,这就是为什么它被称为多道程序。它没有固定的进程时间片。其主要目的是资源利用。

多道程序操作系统的好处:

  • 没有CPU空闲时间。
  • 任务并行运行。
  • 响应时间更短。
  • 最大化计算机的总作业吞吐量。
  • 提高资源利用率。

多道程序操作系统的缺点:

  • 有时长时间的工作必须等待很长时间。
  • 跟踪所有进程有时很困难。
  • 需要 CPU 调度。
  • 需要高效的内存管理。
  • 在执行期间没有用户与任何程序交互。

分时和多道程序的区别:

S.No. TIME SHARING MULTIPROGRAMMING
01. Time Sharing is the logical extension of multiprogramming, in this time sharing Operating system many users/processes are allocated with computer resources in respective time slots. Multiprogramming operating system allows to execute multiple processes by monitoring their process states and switching in between processes.
02. Processors time is shared with multiple users that’s why it is called as time sharing operating system. Processor and memory underutilization problem is resolved and multiple programs runs on CPU that’s why it is called multiprogramming.
03. In this process, two or more users can use a processor in their terminal. In this, the process can be executed by a single processor.
04. Time sharing OS has fixed time slice. Multi-programming OS has no fixed time slice.
05. In time sharing OS system, execution power is taken off before finishing of execution. In multi-programming OS system before finishing a task the execution power is not taken off.
06. Here the system works for the same or less time on each processes. Here the system does not take same time to work on different processes.
07. In time sharing OS system depends on time to switch between different processes. In Multiprogramming OS, system depends on devices to switch between tasks such I/O interrupts etc.
08. System model of time sharing system is multiple programs and multiple users. System model of multiprogramming system is multiple programs.
09. Time sharing system maximizes response time. Multiprogramming system maximizes response time.
10. Example: Windows NT. Example: Mac OS.