Skip to main content

Next fit Algorithm for RM Scheduling

  1. This algorithm uses the same assumptions used in the Rate Monotonic Scheduling
  2. This algorithm is based on the RM Scheduling algorithm for each processors
  3. The multi processor is assumed to consists of identical processors.
  4. The tasks are assumed to require no resources other than the CPU Time
  5.  

    The tasks are allocated to processors according to the classes in which they belong. Each classes contains a set of processors that is only allocated the tasks of that class.

     

    Tasks are allocated one by one to the appropriate processor classes until all the tasks have been scheduled.

    If any class fails to produce a feasible RM Schedule, then a new processor will be added to the same class and the corresponding task (which does not meets its deadline) is allocated to the new processor class.

     

    Example

    Let us say M=4 classes. The following table lists the classes

    Class

    Bound

    C1

    (0.41,1]

    C2

    (0.26,0.41]

    C3

    (0.19,0.26]

    C4

    (0, 0.19]

     

    The tasks sets are given below

     

    T1

    T2

    T3

    T4

    T5

    T6

    T7

    T8

    T9

    T10

    T11

    ei

    5

    7

    3

    1

    10

    16

    1

    3

    9

    17

    21

    Pi

    10

    21

    22

    24

    30

    40

    50

    55

    70

    90

    95

    u(i)=ei/Pi

    0.50

    0.33

    0.14

    0.04

    0.33

    0.40

    0.02

    0.05

    0.13

    0.19

    0.22

    Class

    C1

    C2

    C4

    C4

    C2

    C2

    C4

    C4

    C4

    C4

    C3

     

    Steps

  6. Since C1 class contains only one task T1, it will be RM Schedulable, so p1 is a processor under C1
  7. C2 contains three tasks, T2, T5 and T6, upon RM Scheduling T6 fails to meets its deadline, so a new processor is added to class C2. So class C2 contains two processors p2 and p5
  8. C3 is also having only one Task T11 and it will also be schedulable under RM, so p3 is a processor under C3.
  9. C4 contains 6 tasks namely, T3,T4, T7,T8,T9 and T10. All the tasks meets their deadlines under RM Scheduling, so p4 is a processor under C4
  10.  

    Processor

    Tasks

    p1

    T1

    p2

    T2, T5

    p3

    T11

    p4

    T3,T4,T7,T8,T9,T10

    p5

    T6

     

     

Comments

Popular posts from this blog

Installing ns-3.34 in Ubuntu 20.04

This post shows how to install ns 3.34 in Ubuntu 20.04 LTS Prerequisites: Fresh installation of Ubuntu Version 20.04 LTS  ns3.34 can be downloaded from here Follow the video link for complete step by step instructions on the installation.  This version fixes the compilation issues of vanet-routing-compare.cc (bug in ns3.33)  Issue the following commands after opening a terminal  $ sudo apt update $ sudo apt install g++ python3 python3-dev python-dev pkg-config sqlite3 python3-setuptools git qt5-default gir1.2-goocanvas-2.0 python3-gi python3-gi-cairo python3-pygraphviz gir1.2-gtk-3.0 ipython3 openmpi-bin openmpi-common openmpi-doc libopenmpi-dev autoconf cvs bzr unrar openmpi-bin openmpi-common openmpi-doc libopenmpi-dev tcpdump wireshark libxml2 libxml2-dev Unzip or untar the ns-allinone-3.34.tar.bz2 in the home folder (in my case its /home/pradeepkumar) $ cd ns-allinone-3.34/ $ ./build.py --enable-examples --enable-tests  Once the installation is completed, you may get an output show

Installation of ns3 in Windows 10 and Windows 11 OS using WSL (Windows Subsystem for Linux)

This post shows how to install ns-3.33 in Windows 10 through WSL (Windows Subsystem for Linux) This posts works for Windows 11 also (I have tested it on a Windows 11 ISO and it works the Same way as mentioned in the following post.) This post will work for ns-3.3x version. Prerequisites : Install Windows Subsystem for Linux with GUI: Please refer the following video  System Information: OS used: Windows 10 and WSL (Ubuntu 20.04) GUI: XServer for Windows NS3 Version: ns-3.33 See the following complete video on how to install ns3 in Windows 10 Step 0 : Open XLaunch Step 1 :  Open WSL using PowerShell and open it as Administrator Command:/  wsl $ xfce4-session The GUI of Ubuntu Opens within Windows 10 OS. Step 2 : Download ns3 from nsnam.org website through Mozilla Firefox browser Step 3: Open a Terminal  $ sudo apt update $ sudo apt install build-essential autoconf automake libxmu-dev python3-pygraphviz cvs mercurial bzr git cmake p7zip-full python3-matplotlib python-tk python3-dev qt5-q

Installing NS-3.32 in Ubuntu 20.04

This is about installing ns version 3.32 in Ubuntu 20.04 LTS. #ns3 #ns3 .32 #networksimulation The commands used in the video are given here. $] sudo apt update $] sudo apt install build-essential autoconf automake libxmu-dev python3-pygraphviz cvs mercurial bzr git cmake p7zip-full python3-matplotlib python-tk python3-dev qt5-qmake qt5-default gnuplot-x11 wireshark Download the ns-allinone-3.32.tar.bz2 package from nsnam.org and copy it to /home/ folder See the full video for detailed instructions Extract it either in GUI or using command $] tar jxvf ns-allinone-3.32.tar.bz2 $] cd ns-allinone-3.32/ $] ./build.py --enable-examples --enable-tests The above command will take some time to install all the packages  You can see the output as shown below ns3 To check whether ns3 installed successfully, use the following commands. $] cd ns-3.32/ $] ./waf --run hello-simulator You should get the output as Hello Simulator $] ./waf --run first This is the example from the ns-3.32/exa