SlideShare une entreprise Scribd logo
1  sur  42
Télécharger pour lire hors ligne
oraccha
http://d.hatena.ne.jp/oraccha/
MINIX

•




•                    Google Group

    https://groups.google.com/group/minixReadingClub
Andrew S. Tanenbaum




 Albert S. Woodhull
OS


     OS
•


    •




•       MINIX 3
MINIX
• 1987   MINIX 1: UNIX (v7)             OS

  • 8088   16bit

• 1997   MINIX 2

  • 386   32bit

  • v7   → POSIX.1        IEEE1003.1/ISO 9945-1

• 2006   MINIX 3 (book version   MINIX 3.1.0)
OS
•            OS

    •       CPU         IO
        •   CPU
        •


•                 OS

    •


    •              OS
1.              fork, waitpid, exec, exit, ...

2.     sigaction, sigreturn, kill, alarm, ...

3.              creat, open, close, read, write, ...

4.           mkdir, rmdir, mount, unmount, chdir, ...

5.   chmod, chown, unmask, ...

6.   time, stime, utime, times
OS


     THE   MULTICS


       VM/370


       exokernel


       MINIX 3
• OS

•

•




       P.55
Jochen Liedtke
“Toward Real Microkernels,” CACM Vol. 39, No.9, 1996.
•   A New Hope:
    •   1980                        UNIX
    •       Mach   Chorus    Mach

•   The Microkernel Strikes Back:
    •

    •       L4   Exokernel

•   Return of Virtual Machines:
    •

    •       VMWare Xen
•


    •   CPU

    •


• OS




              CPU
•



•
                 ‣CPU
    •
                 ‣
    • Peterson

    • TSL

•

•
                 Mars Pathfinder’s Sojourner
• Peterson

  •                        Dekker


  •               N

      • Filter

      • Lamport   Bakery

  • TSL
PERTERSON
int turn;
boolean interested[2];

do {                                   do {
                                                                enter region
 interested[0] = TRUE;                  interested[1] = TRUE;
 turn = 0;                              turn = 1;
 while (turn == 0 && interested[1]);    while (turn == 1 && interested[0]);

 /* critical region */                  /* critical region */   leave region
 interested[0] = FALSE;                 interested[1] = FALSE;

  /* non critical region */              /* non critical region */
} while (TRUE);                        } while (TRUE);
                         0                                       1
TSL
• Test-and-Set      Lock
    •                                       read
        write read cmp          1

•

    • ts   (System/360)
    • cas     (68000, SPARC)
    • xchg, cmpxchg     (x86)
    • ll/sc   (MIPS), ldrex/strex (ARMv6)
•                                   sleep&wakeup
• Semafore              Semaphore
    • P: down   sleep
    • V: up     wakeup
•
                                        •
    •
                                        •
    •                                   •
• CPU   I/O

•

•

    •

    •

•
MINIX 3

4     init                                       ...


3
     (pm)        (vfs)      (vm)       (inet)           (rs)
                 TTY       Ethernet
2                                                ...
    (at_wini)    (tty)     (lance)

1               (kernel)
                                      (system)         (clock)
                                                                 P.121
• boot   monitor
  •
                     init

• MINIX     kernel
  •

• init(8)
  • /etc/rc

      • service(8)

  • /etc/ttytab             getty (login)
• PM


    •


• service(8)


•                 MINIX3

    • C.Giuffrida, “We   Crashed, Now What?,” USENIX HotDep’10
•
       F4

• is    kill
# cd servers/is
# vi dmp_kernel.c
# diff dmp_kernel.c.orig dmp_kernel.c
338c338
< ! printf("(%02u) %-7.7s %s %s %7d",
---
> ! printf("(%02u) %-7.7s %s %s %6d",
# make && make install
# kill 38
PS
 PID TTY   TIME   CMD
(-4)   ?   0h44   idle
(-3)   ?   0:00   clock
(-2)   ?   0:00   system
(-1)   ?   0:00   kernel
   5   ?   0:00   pm
   7   ?   0:00   vfs
   4   ?   0:00   rs
   8   ?   0:00   memory
:
   1   ?   0:00 init
:
 122 co    0:00 sh
 123 c1    0:00 getty
• MINIX3   book                                  v3.1.0
 ISO               Appendix B

 • MINIX3   book version (v3.1.0) current version (v3.1.8)



 • http://www.minix3.org/doc/
/USR/SRC
include           make world /usr/include


           sys           POSIX
          minix      MINIX 3 OS
          ibm        IBM PC
kernel
drivers
servers
• src/tools   make
 (       http://wiki.minix3.org/en/DevelopersGuide/RebuildingSystem)

  • /boot/boot:

  • /boot/images:

  • /sbin:

                  # cd /usr/src/tools
                  # make image
                  # make install
•   newminix
• MINIX     C/S

•



    •


        •


        •
S   kernel   R
•                                     send

                                  (          )
    • send    receive   sendrec                                   receive


    •

                                                 S   kernel   R

                                                                  receive
    •
        sendrec                       send
•

    • notify

      •
•                                              priv

    • ipc_to: IPC

    • traps: IPC          send receive           sendrec        notify

    •                               pm vfs      rs              sendrec
                    sendrec   send                    sendrec

                     pm       vfs      vm      inet     rs

                                     drivers
                                     kernel
sys_fork       PM
   sys_exec        PM        EXEC    SP
    sys_exit       PM
  sys_privctl       RS
   sys_irqctl    driver
  sys_devio      driver        I/O
  sys_umap       driver
 sys_vircopy    FS, driver
sys_physcopy     driver
 sys_getinfo        all
                                          P.208
FORK&EXEC
• UNIX              PDP-7

    •                                                    OS
                TSS

•                                   fork exec

    • fork   exec

        •                          SDS 930 TSS

    •

                        D.M.Ritchie, ”The evolution of the UNIX Time-sharing system,” 1979
•                          IDT
             iretd

•   CPU              TSS         SS   ESP
    stackframe_s

•                                           stackframe_s


•                                               iretd


    •
31                             16 15 14 13 12            8 7               0




                                    IA32
                                                                                    D
                                                                                P   P   0 0 1 0 1                           4
                                                                                    L

                                             31                             16 15                                       0


                                                    TSS                                                                     0

IDTR
                                             31                             16 15 14 13 12            8 7      5 4      0


  base        limit                                             31..16          P
                                                                                    D
                                                                                    P
                                                                                    L
                                                                                        0 D 1 1 0       0 0 0               4




                               IDT
                                             31                             16 15                                       0


                                                                                                            15..0           0

         +
             55                              31                             16 15 14 13 12

                                                                                    D
                                                                                                      8 7      5 4      0


                                                                31..16          P   P   0 D 1 1 1       0 0 0               4
                                                                                    L

                                             31                             16 15                                       0


                                                                                                            15..0           0

                                              DPL


             33   SYS386_VECTOR               P

                                              D                          1=32           0=16



                                                              5-2. IDT


                                    5.12.
                                                                                                      256
                                                          !                                                          "#$$

                                            32      255
             0        zero divide
                                                                            !                               %&'

                                                                          "#$$
                                                    !                                        ()*)+)
IA32
        SS                                        SS
        ESP                                       ESP
      EFLAGS                                    EFLAGS
                                                              IRET   pop
        CS                                        CS
        EIP                                       EIP
    (Error Code)                 CPU   push   (Error Code)



•                  push
•                         push                      push
•                    IRET                               pop
restart()

service(int)   syscall()

  save()




                           P.188
_RESTART
               struct stackframe_s (struct proc                          )
               call save                       save        jmp

                    SS                                        SS                k_stktop       _restart
                   ESP                                       ESP
                 EFLAGS                                    EFLAGS
                   CS                                        CS
                   EIP                                       EIP
           hwint_XX   ret address   (RETADR)     hwint_XX        ret address
                                                            EAX                            mov esp, k_stktop
                                                            ECX
save                                                        EDX
                                                            EBX                save
       ret                    jmp
                                                            ESP
              hwint_XX              ret        _restart                          push
                                                            EBP
                                                             ESI
  v3.1.8                                                    EDI
                                                      DS            ES
                                                      FS            GS
                               struct stackframe_s
call save


                  SS                                SS
                 ESP                               ESP
                EFLAGS                           EFLAGS
                 CS                                 CS
                 EIP                               EIP
          (Error Code)   CPU   push             old EFLAGS
                                                  old CS
                                                  old EIP
                               _exception or
_errexception
C

Contenu connexe

Tendances

BeagleBone Black: Platform Bring-Up with Upstream Components
BeagleBone Black: Platform Bring-Up with Upstream ComponentsBeagleBone Black: Platform Bring-Up with Upstream Components
BeagleBone Black: Platform Bring-Up with Upstream ComponentsGlobalLogic Ukraine
 
BeagleBone Black with Upstream Software
BeagleBone Black with Upstream SoftwareBeagleBone Black with Upstream Software
BeagleBone Black with Upstream SoftwareGlobalLogic Ukraine
 
Surge2014 talk - illumos State of the Community & POSIX Update
Surge2014 talk - illumos State of the Community & POSIX UpdateSurge2014 talk - illumos State of the Community & POSIX Update
Surge2014 talk - illumos State of the Community & POSIX UpdateGarrett D'Amore
 
Confraria SECURITY & IT - Lisbon Set 29, 2011
Confraria SECURITY & IT - Lisbon Set 29, 2011Confraria SECURITY & IT - Lisbon Set 29, 2011
Confraria SECURITY & IT - Lisbon Set 29, 2011ricardomcm
 
A Journey to Boot Linux on Raspberry Pi
A Journey to Boot Linux on Raspberry PiA Journey to Boot Linux on Raspberry Pi
A Journey to Boot Linux on Raspberry PiJian-Hong Pan
 
Introducing Swift - and the Sunset of Our Culture?
Introducing Swift - and the Sunset of Our Culture?Introducing Swift - and the Sunset of Our Culture?
Introducing Swift - and the Sunset of Our Culture?dankogai
 
明日から出来る! 指に優しいキー配列 (改訂版)
明日から出来る! 指に優しいキー配列 (改訂版)明日から出来る! 指に優しいキー配列 (改訂版)
明日から出来る! 指に優しいキー配列 (改訂版)tekezo
 
All Things Containers - TechParty FACCAT 2016
All Things Containers - TechParty FACCAT 2016All Things Containers - TechParty FACCAT 2016
All Things Containers - TechParty FACCAT 2016Fabiano Franz
 
Linux Container Basics
Linux Container BasicsLinux Container Basics
Linux Container BasicsMichael Kehoe
 
Keynote 1 - Engineering Software Analytics Studies
Keynote 1 - Engineering Software Analytics StudiesKeynote 1 - Engineering Software Analytics Studies
Keynote 1 - Engineering Software Analytics StudiesESEM 2014
 
Elephant bird build Error
Elephant bird build ErrorElephant bird build Error
Elephant bird build ErrorKapil Dewade
 
Building Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCBuilding Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCKernel TLV
 
Software Packaging for Cross OS Distribution
Software Packaging for Cross OS DistributionSoftware Packaging for Cross OS Distribution
Software Packaging for Cross OS DistributionJian-Hong Pan
 
Linux booting procedure
Linux booting procedureLinux booting procedure
Linux booting procedureDhaval Kaneria
 
明日から出来る! 指に優しいキー配列
明日から出来る! 指に優しいキー配列明日から出来る! 指に優しいキー配列
明日から出来る! 指に優しいキー配列tekezo
 
Yum server ( FTP Server )
Yum server ( FTP Server ) Yum server ( FTP Server )
Yum server ( FTP Server ) MOHSIN HASAN
 

Tendances (20)

BeagleBone Black: Platform Bring-Up with Upstream Components
BeagleBone Black: Platform Bring-Up with Upstream ComponentsBeagleBone Black: Platform Bring-Up with Upstream Components
BeagleBone Black: Platform Bring-Up with Upstream Components
 
eBPF Workshop
eBPF WorkshopeBPF Workshop
eBPF Workshop
 
BeagleBone Black with Upstream Software
BeagleBone Black with Upstream SoftwareBeagleBone Black with Upstream Software
BeagleBone Black with Upstream Software
 
Surge2014 talk - illumos State of the Community & POSIX Update
Surge2014 talk - illumos State of the Community & POSIX UpdateSurge2014 talk - illumos State of the Community & POSIX Update
Surge2014 talk - illumos State of the Community & POSIX Update
 
Confraria SECURITY & IT - Lisbon Set 29, 2011
Confraria SECURITY & IT - Lisbon Set 29, 2011Confraria SECURITY & IT - Lisbon Set 29, 2011
Confraria SECURITY & IT - Lisbon Set 29, 2011
 
A Journey to Boot Linux on Raspberry Pi
A Journey to Boot Linux on Raspberry PiA Journey to Boot Linux on Raspberry Pi
A Journey to Boot Linux on Raspberry Pi
 
Introducing Swift - and the Sunset of Our Culture?
Introducing Swift - and the Sunset of Our Culture?Introducing Swift - and the Sunset of Our Culture?
Introducing Swift - and the Sunset of Our Culture?
 
明日から出来る! 指に優しいキー配列 (改訂版)
明日から出来る! 指に優しいキー配列 (改訂版)明日から出来る! 指に優しいキー配列 (改訂版)
明日から出来る! 指に優しいキー配列 (改訂版)
 
All Things Containers - TechParty FACCAT 2016
All Things Containers - TechParty FACCAT 2016All Things Containers - TechParty FACCAT 2016
All Things Containers - TechParty FACCAT 2016
 
eBPF Basics
eBPF BasicseBPF Basics
eBPF Basics
 
Linux Container Basics
Linux Container BasicsLinux Container Basics
Linux Container Basics
 
Keynote 1 - Engineering Software Analytics Studies
Keynote 1 - Engineering Software Analytics StudiesKeynote 1 - Engineering Software Analytics Studies
Keynote 1 - Engineering Software Analytics Studies
 
Elephant bird build Error
Elephant bird build ErrorElephant bird build Error
Elephant bird build Error
 
Introduction to Modern U-Boot
Introduction to Modern U-BootIntroduction to Modern U-Boot
Introduction to Modern U-Boot
 
Building Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCBuilding Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCC
 
Linux kernel system call
Linux kernel system callLinux kernel system call
Linux kernel system call
 
Software Packaging for Cross OS Distribution
Software Packaging for Cross OS DistributionSoftware Packaging for Cross OS Distribution
Software Packaging for Cross OS Distribution
 
Linux booting procedure
Linux booting procedureLinux booting procedure
Linux booting procedure
 
明日から出来る! 指に優しいキー配列
明日から出来る! 指に優しいキー配列明日から出来る! 指に優しいキー配列
明日から出来る! 指に優しいキー配列
 
Yum server ( FTP Server )
Yum server ( FTP Server ) Yum server ( FTP Server )
Yum server ( FTP Server )
 

Similaire à オペレーティングシステム 設計と実装 第3版(20101211)

スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみたスマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみたTaro Matsuzawa
 
SMP Implementation for OpenBSD/sgi [Japanese Edition]
SMP Implementation for OpenBSD/sgi [Japanese Edition]SMP Implementation for OpenBSD/sgi [Japanese Edition]
SMP Implementation for OpenBSD/sgi [Japanese Edition]Takuya ASADA
 
イマドキなNetwork/IO
イマドキなNetwork/IOイマドキなNetwork/IO
イマドキなNetwork/IOTakuya ASADA
 
Cncf k8s_network_part1
Cncf k8s_network_part1Cncf k8s_network_part1
Cncf k8s_network_part1Erhwen Kuo
 
SMP implementation for OpenBSD/sgi
SMP implementation for OpenBSD/sgiSMP implementation for OpenBSD/sgi
SMP implementation for OpenBSD/sgiTakuya ASADA
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisktutorialsruby
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisktutorialsruby
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisktutorialsruby
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisktutorialsruby
 
09_Practical Multicore programming
09_Practical Multicore programming09_Practical Multicore programming
09_Practical Multicore programmingnoerror
 
シェル芸でライフハック(特論)
シェル芸でライフハック(特論)シェル芸でライフハック(特論)
シェル芸でライフハック(特論)Yuki Shimazaki
 
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全維泰 蔡
 
Linux Perf Tools
Linux Perf ToolsLinux Perf Tools
Linux Perf ToolsRaj Pandey
 
スケジューラからみたOSの話
スケジューラからみたOSの話スケジューラからみたOSの話
スケジューラからみたOSの話Takeshi Fujiwara
 
Linux Performance Tools 2014
Linux Performance Tools 2014Linux Performance Tools 2014
Linux Performance Tools 2014Brendan Gregg
 
How to Root 10 Million Phones with One Exploit
How to Root 10 Million Phones with One ExploitHow to Root 10 Million Phones with One Exploit
How to Root 10 Million Phones with One ExploitJiahong Fang
 
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) HypervisorAsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) HypervisorDave Voutila
 
Is That A Penguin In My Windows?
Is That A Penguin In My Windows?Is That A Penguin In My Windows?
Is That A Penguin In My Windows?zeroSteiner
 

Similaire à オペレーティングシステム 設計と実装 第3版(20101211) (20)

スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみたスマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
スマートフォン勉強会@関東 #11 どう考えてもdisconなものをiPhoneに移植してみた
 
SMP Implementation for OpenBSD/sgi [Japanese Edition]
SMP Implementation for OpenBSD/sgi [Japanese Edition]SMP Implementation for OpenBSD/sgi [Japanese Edition]
SMP Implementation for OpenBSD/sgi [Japanese Edition]
 
イマドキなNetwork/IO
イマドキなNetwork/IOイマドキなNetwork/IO
イマドキなNetwork/IO
 
SdE2 - Pilot Tock
SdE2 - Pilot TockSdE2 - Pilot Tock
SdE2 - Pilot Tock
 
Cncf k8s_network_part1
Cncf k8s_network_part1Cncf k8s_network_part1
Cncf k8s_network_part1
 
SMP implementation for OpenBSD/sgi
SMP implementation for OpenBSD/sgiSMP implementation for OpenBSD/sgi
SMP implementation for OpenBSD/sgi
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisk
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisk
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisk
 
Jonny_Martin-Asterisk
Jonny_Martin-AsteriskJonny_Martin-Asterisk
Jonny_Martin-Asterisk
 
09_Practical Multicore programming
09_Practical Multicore programming09_Practical Multicore programming
09_Practical Multicore programming
 
シェル芸でライフハック(特論)
シェル芸でライフハック(特論)シェル芸でライフハック(特論)
シェル芸でライフハック(特論)
 
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
Linux 系統管理與安全:進階系統管理系統防駭與資訊安全
 
Linux Perf Tools
Linux Perf ToolsLinux Perf Tools
Linux Perf Tools
 
スケジューラからみたOSの話
スケジューラからみたOSの話スケジューラからみたOSの話
スケジューラからみたOSの話
 
Linux Performance Tools 2014
Linux Performance Tools 2014Linux Performance Tools 2014
Linux Performance Tools 2014
 
How to Root 10 Million Phones with One Exploit
How to Root 10 Million Phones with One ExploitHow to Root 10 Million Phones with One Exploit
How to Root 10 Million Phones with One Exploit
 
Workshop@naha_val3
Workshop@naha_val3Workshop@naha_val3
Workshop@naha_val3
 
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) HypervisorAsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
 
Is That A Penguin In My Windows?
Is That A Penguin In My Windows?Is That A Penguin In My Windows?
Is That A Penguin In My Windows?
 

Plus de Ryousei Takano

Error Permissive Computing
Error Permissive ComputingError Permissive Computing
Error Permissive ComputingRyousei Takano
 
Opportunities of ML-based data analytics in ABCI
Opportunities of ML-based data analytics in ABCIOpportunities of ML-based data analytics in ABCI
Opportunities of ML-based data analytics in ABCIRyousei Takano
 
ABCI: An Open Innovation Platform for Advancing AI Research and Deployment
ABCI: An Open Innovation Platform for Advancing AI Research and DeploymentABCI: An Open Innovation Platform for Advancing AI Research and Deployment
ABCI: An Open Innovation Platform for Advancing AI Research and DeploymentRyousei Takano
 
クラウド環境におけるキャッシュメモリQoS制御の評価
クラウド環境におけるキャッシュメモリQoS制御の評価クラウド環境におけるキャッシュメモリQoS制御の評価
クラウド環境におけるキャッシュメモリQoS制御の評価Ryousei Takano
 
USENIX NSDI 2016 (Session: Resource Sharing)
USENIX NSDI 2016 (Session: Resource Sharing)USENIX NSDI 2016 (Session: Resource Sharing)
USENIX NSDI 2016 (Session: Resource Sharing)Ryousei Takano
 
User-space Network Processing
User-space Network ProcessingUser-space Network Processing
User-space Network ProcessingRyousei Takano
 
Flow-centric Computing - A Datacenter Architecture in the Post Moore Era
Flow-centric Computing - A Datacenter Architecture in the Post Moore EraFlow-centric Computing - A Datacenter Architecture in the Post Moore Era
Flow-centric Computing - A Datacenter Architecture in the Post Moore EraRyousei Takano
 
A Look Inside Google’s Data Center Networks
A Look Inside Google’s Data Center NetworksA Look Inside Google’s Data Center Networks
A Look Inside Google’s Data Center NetworksRyousei Takano
 
クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術Ryousei Takano
 
AIST Super Green Cloud: lessons learned from the operation and the performanc...
AIST Super Green Cloud: lessons learned from the operation and the performanc...AIST Super Green Cloud: lessons learned from the operation and the performanc...
AIST Super Green Cloud: lessons learned from the operation and the performanc...Ryousei Takano
 
IEEE CloudCom 2014参加報告
IEEE CloudCom 2014参加報告IEEE CloudCom 2014参加報告
IEEE CloudCom 2014参加報告Ryousei Takano
 
Expectations for optical network from the viewpoint of system software research
Expectations for optical network from the viewpoint of system software researchExpectations for optical network from the viewpoint of system software research
Expectations for optical network from the viewpoint of system software researchRyousei Takano
 
Exploring the Performance Impact of Virtualization on an HPC Cloud
Exploring the Performance Impact of Virtualization on an HPC CloudExploring the Performance Impact of Virtualization on an HPC Cloud
Exploring the Performance Impact of Virtualization on an HPC CloudRyousei Takano
 
不揮発メモリとOS研究にまつわる何か
不揮発メモリとOS研究にまつわる何か不揮発メモリとOS研究にまつわる何か
不揮発メモリとOS研究にまつわる何かRyousei Takano
 
High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...
High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...
High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...Ryousei Takano
 
クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~
クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~
クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~Ryousei Takano
 
From Rack scale computers to Warehouse scale computers
From Rack scale computers to Warehouse scale computersFrom Rack scale computers to Warehouse scale computers
From Rack scale computers to Warehouse scale computersRyousei Takano
 
高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud
高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud
高性能かつスケールアウト可能なHPCクラウド AIST Super Green CloudRyousei Takano
 
Iris: Inter-cloud Resource Integration System for Elastic Cloud Data Center
Iris: Inter-cloud Resource Integration System for Elastic Cloud Data CenterIris: Inter-cloud Resource Integration System for Elastic Cloud Data Center
Iris: Inter-cloud Resource Integration System for Elastic Cloud Data CenterRyousei Takano
 

Plus de Ryousei Takano (20)

Error Permissive Computing
Error Permissive ComputingError Permissive Computing
Error Permissive Computing
 
Opportunities of ML-based data analytics in ABCI
Opportunities of ML-based data analytics in ABCIOpportunities of ML-based data analytics in ABCI
Opportunities of ML-based data analytics in ABCI
 
ABCI: An Open Innovation Platform for Advancing AI Research and Deployment
ABCI: An Open Innovation Platform for Advancing AI Research and DeploymentABCI: An Open Innovation Platform for Advancing AI Research and Deployment
ABCI: An Open Innovation Platform for Advancing AI Research and Deployment
 
ABCI Data Center
ABCI Data CenterABCI Data Center
ABCI Data Center
 
クラウド環境におけるキャッシュメモリQoS制御の評価
クラウド環境におけるキャッシュメモリQoS制御の評価クラウド環境におけるキャッシュメモリQoS制御の評価
クラウド環境におけるキャッシュメモリQoS制御の評価
 
USENIX NSDI 2016 (Session: Resource Sharing)
USENIX NSDI 2016 (Session: Resource Sharing)USENIX NSDI 2016 (Session: Resource Sharing)
USENIX NSDI 2016 (Session: Resource Sharing)
 
User-space Network Processing
User-space Network ProcessingUser-space Network Processing
User-space Network Processing
 
Flow-centric Computing - A Datacenter Architecture in the Post Moore Era
Flow-centric Computing - A Datacenter Architecture in the Post Moore EraFlow-centric Computing - A Datacenter Architecture in the Post Moore Era
Flow-centric Computing - A Datacenter Architecture in the Post Moore Era
 
A Look Inside Google’s Data Center Networks
A Look Inside Google’s Data Center NetworksA Look Inside Google’s Data Center Networks
A Look Inside Google’s Data Center Networks
 
クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術
 
AIST Super Green Cloud: lessons learned from the operation and the performanc...
AIST Super Green Cloud: lessons learned from the operation and the performanc...AIST Super Green Cloud: lessons learned from the operation and the performanc...
AIST Super Green Cloud: lessons learned from the operation and the performanc...
 
IEEE CloudCom 2014参加報告
IEEE CloudCom 2014参加報告IEEE CloudCom 2014参加報告
IEEE CloudCom 2014参加報告
 
Expectations for optical network from the viewpoint of system software research
Expectations for optical network from the viewpoint of system software researchExpectations for optical network from the viewpoint of system software research
Expectations for optical network from the viewpoint of system software research
 
Exploring the Performance Impact of Virtualization on an HPC Cloud
Exploring the Performance Impact of Virtualization on an HPC CloudExploring the Performance Impact of Virtualization on an HPC Cloud
Exploring the Performance Impact of Virtualization on an HPC Cloud
 
不揮発メモリとOS研究にまつわる何か
不揮発メモリとOS研究にまつわる何か不揮発メモリとOS研究にまつわる何か
不揮発メモリとOS研究にまつわる何か
 
High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...
High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...
High-resolution Timer-based Packet Pacing Mechanism on the Linux Operating Sy...
 
クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~
クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~
クラウドの垣根を超えた高性能計算に向けて~AIST Super Green Cloudでの試み~
 
From Rack scale computers to Warehouse scale computers
From Rack scale computers to Warehouse scale computersFrom Rack scale computers to Warehouse scale computers
From Rack scale computers to Warehouse scale computers
 
高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud
高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud
高性能かつスケールアウト可能なHPCクラウド AIST Super Green Cloud
 
Iris: Inter-cloud Resource Integration System for Elastic Cloud Data Center
Iris: Inter-cloud Resource Integration System for Elastic Cloud Data CenterIris: Inter-cloud Resource Integration System for Elastic Cloud Data Center
Iris: Inter-cloud Resource Integration System for Elastic Cloud Data Center
 

Dernier

"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 

Dernier (20)

"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 

オペレーティングシステム 設計と実装 第3版(20101211)

  • 2. MINIX • • Google Group https://groups.google.com/group/minixReadingClub
  • 3. Andrew S. Tanenbaum Albert S. Woodhull
  • 4. OS OS
  • 5.
  • 6. • • MINIX 3
  • 7. MINIX • 1987 MINIX 1: UNIX (v7) OS • 8088 16bit • 1997 MINIX 2 • 386 32bit • v7 → POSIX.1 IEEE1003.1/ISO 9945-1 • 2006 MINIX 3 (book version MINIX 3.1.0)
  • 8. OS • OS • CPU IO • CPU • • OS • • OS
  • 9. 1. fork, waitpid, exec, exit, ... 2. sigaction, sigreturn, kill, alarm, ... 3. creat, open, close, read, write, ... 4. mkdir, rmdir, mount, unmount, chdir, ... 5. chmod, chown, unmask, ... 6. time, stime, utime, times
  • 10. OS THE MULTICS VM/370 exokernel MINIX 3
  • 12. Jochen Liedtke “Toward Real Microkernels,” CACM Vol. 39, No.9, 1996.
  • 13. A New Hope: • 1980 UNIX • Mach Chorus Mach • The Microkernel Strikes Back: • • L4 Exokernel • Return of Virtual Machines: • • VMWare Xen
  • 14.
  • 15. • CPU • • OS CPU
  • 16. • • ‣CPU • ‣ • Peterson • TSL • • Mars Pathfinder’s Sojourner
  • 17. • Peterson • Dekker • N • Filter • Lamport Bakery • TSL
  • 18. PERTERSON int turn; boolean interested[2]; do { do { enter region interested[0] = TRUE; interested[1] = TRUE; turn = 0; turn = 1; while (turn == 0 && interested[1]); while (turn == 1 && interested[0]); /* critical region */ /* critical region */ leave region interested[0] = FALSE; interested[1] = FALSE; /* non critical region */ /* non critical region */ } while (TRUE); } while (TRUE); 0 1
  • 19. TSL • Test-and-Set Lock • read write read cmp 1 • • ts (System/360) • cas (68000, SPARC) • xchg, cmpxchg (x86) • ll/sc (MIPS), ldrex/strex (ARMv6)
  • 20. sleep&wakeup • Semafore Semaphore • P: down sleep • V: up wakeup • • • • • •
  • 21. • CPU I/O • • • • •
  • 22. MINIX 3 4 init ... 3 (pm) (vfs) (vm) (inet) (rs) TTY Ethernet 2 ... (at_wini) (tty) (lance) 1 (kernel) (system) (clock) P.121
  • 23. • boot monitor • init • MINIX kernel • • init(8) • /etc/rc • service(8) • /etc/ttytab getty (login)
  • 24. • PM • • service(8) • MINIX3 • C.Giuffrida, “We Crashed, Now What?,” USENIX HotDep’10
  • 25. F4 • is kill # cd servers/is # vi dmp_kernel.c # diff dmp_kernel.c.orig dmp_kernel.c 338c338 < ! printf("(%02u) %-7.7s %s %s %7d", --- > ! printf("(%02u) %-7.7s %s %s %6d", # make && make install # kill 38
  • 26. PS PID TTY TIME CMD (-4) ? 0h44 idle (-3) ? 0:00 clock (-2) ? 0:00 system (-1) ? 0:00 kernel 5 ? 0:00 pm 7 ? 0:00 vfs 4 ? 0:00 rs 8 ? 0:00 memory : 1 ? 0:00 init : 122 co 0:00 sh 123 c1 0:00 getty
  • 27. • MINIX3 book v3.1.0 ISO Appendix B • MINIX3 book version (v3.1.0) current version (v3.1.8) • http://www.minix3.org/doc/
  • 28. /USR/SRC include make world /usr/include sys POSIX minix MINIX 3 OS ibm IBM PC kernel drivers servers
  • 29. • src/tools make ( http://wiki.minix3.org/en/DevelopersGuide/RebuildingSystem) • /boot/boot: • /boot/images: • /sbin: # cd /usr/src/tools # make image # make install
  • 30. newminix
  • 31. • MINIX C/S • • • •
  • 32. S kernel R • send ( ) • send receive sendrec receive • S kernel R receive • sendrec send
  • 33. • notify •
  • 34. priv • ipc_to: IPC • traps: IPC send receive sendrec notify • pm vfs rs sendrec sendrec send sendrec pm vfs vm inet rs drivers kernel
  • 35. sys_fork PM sys_exec PM EXEC SP sys_exit PM sys_privctl RS sys_irqctl driver sys_devio driver I/O sys_umap driver sys_vircopy FS, driver sys_physcopy driver sys_getinfo all P.208
  • 36. FORK&EXEC • UNIX PDP-7 • OS TSS • fork exec • fork exec • SDS 930 TSS • D.M.Ritchie, ”The evolution of the UNIX Time-sharing system,” 1979
  • 37. IDT iretd • CPU TSS SS ESP stackframe_s • stackframe_s • iretd •
  • 38. 31 16 15 14 13 12 8 7 0 IA32 D P P 0 0 1 0 1 4 L 31 16 15 0 TSS 0 IDTR 31 16 15 14 13 12 8 7 5 4 0 base limit 31..16 P D P L 0 D 1 1 0 0 0 0 4 IDT 31 16 15 0 15..0 0 + 55 31 16 15 14 13 12 D 8 7 5 4 0 31..16 P P 0 D 1 1 1 0 0 0 4 L 31 16 15 0 15..0 0 DPL 33 SYS386_VECTOR P D 1=32 0=16 5-2. IDT 5.12. 256 ! "#$$ 32 255 0 zero divide ! %&' "#$$ ! ()*)+)
  • 39. IA32 SS SS ESP ESP EFLAGS EFLAGS IRET pop CS CS EIP EIP (Error Code) CPU push (Error Code) • push • push push • IRET pop
  • 40. restart() service(int) syscall() save() P.188
  • 41. _RESTART struct stackframe_s (struct proc ) call save save jmp SS SS k_stktop _restart ESP ESP EFLAGS EFLAGS CS CS EIP EIP hwint_XX ret address (RETADR) hwint_XX ret address EAX mov esp, k_stktop ECX save EDX EBX save ret jmp ESP hwint_XX ret _restart push EBP ESI v3.1.8 EDI DS ES FS GS struct stackframe_s
  • 42. call save SS SS ESP ESP EFLAGS EFLAGS CS CS EIP EIP (Error Code) CPU push old EFLAGS old CS old EIP _exception or _errexception C