Inferno OS
-
Upload
dipun-patra -
Category
Documents
-
view
82 -
download
5
Transcript of Inferno OS
![Page 1: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/1.jpg)
1
Inferno
Distributed Programming With Inferno®
Larry RauMember of Technical Staff
Inferno Network Software SolutionsLucent Technologies, Inc
http://www.lucent.com/inferno
aVsonline.blogspot.comaVs997 techfamily
![Page 2: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/2.jpg)
2
Inferno®
The Inferno OS
• Lightweight OS for networked devices– portable -- StrongARM, PowerPC, x86, MIPS,
SPARC.– Integrated DIS™ VM -- supports portable
machine independent code modules.– Provides “distributed computing” capability
through Namespace and Styx™ Technologies – Authentication and Encryption between
nodes.
![Page 3: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/3.jpg)
3
Inferno®
Distributed Computing Capabilities
• The Inferno OS is built around a unique method of distributed computing– All resources represented as files– A dynamically adjustable namespace– The Styx™ file access protocol
![Page 4: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/4.jpg)
4
Inferno®
Inferno File Systems
• Inferno views virtually everything as a file system– network interface: /dev/tcp, /dev/udp,...– process information: /prog– window system: /dev/draw– information: /dev/user, /dev/time,
/dev/sysname, /dev/random,….
![Page 5: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/5.jpg)
5
Inferno®
Example: TCP Interface
Access a TCP/IP network by manipulating the following files:puck$ ls /net/tcp/0
/net/tcp/0/ctl
/net/tcp/0/data
/net/tcp/0/listen
/net/tcp/0/local
/net/tcp/0/remote
/net/tcp/0/status
![Page 6: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/6.jpg)
6
Inferno®
Example: /dev/draw
Access to the Inferno windowing system is via another file system:puck$ ls /dev/draw/2
/dev/draw/2/ctl
/dev/draw/2/data
/dev/draw/2/refresh
![Page 7: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/7.jpg)
7
Inferno®
Other existing file systems
• telfs: interface to telephony device
• Mfs: message store file system
• asr: interface to speech recognition
![Page 8: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/8.jpg)
8
Inferno®
Why file systems?
• Simple concept– familiar access methods: open, read, write,
etc.
• language neutral access
• Easy to distribute
![Page 9: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/9.jpg)
9
Inferno®
The Inferno Namespace
•The Inferno Namespace is a hierarchical collection of files (I.e. resources).
•Every process accesses its resources via its own namespace– can inherit from parent– share with other processes
•Local and remote resources are bound into the namespace.
![Page 10: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/10.jpg)
10
Inferno®
Primary Namespace Operations
• BIND
• MOUNT
• EXPORT
![Page 11: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/11.jpg)
11
Inferno®
The BIND Namespace Operation
• Attaches local resources to the namespace
• Moves a resource within the namespace
• Can hide resources by binding over
• Binding a directory can result in a Union Directory
![Page 12: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/12.jpg)
12
Inferno®
Union Directories
• A directory whose contents are a combination of the source and destination
• Directories can be stacked where the contents of one hide the contents of others.
• When binding you have the option of adding before or after the current contents
![Page 13: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/13.jpg)
13
Inferno®
Union Directories
tmp
/
YF1 F2 F3
AF1 A1 A2
...
......
ZF2 A1 B1
......
![Page 14: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/14.jpg)
14
Inferno®
AF1 A1 A2
A YF1 F2 F3
Union Directories
/
AF1 A1 A2
...
ZF2 A1 B1
......
bind -b /tmp/Y /A
bind -a /tmp/Z /A
![Page 15: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/15.jpg)
15
Inferno®
The MOUNT Namespace Operation
• Attaches a remote file system to the namespace
• Equivalent to a remote attach to obtain the remote file system’s root followed by a BIND operation
• Mount initiates a Styx connection over an established network connection
• Net connection can be authenticated
![Page 16: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/16.jpg)
16
Inferno®
Mounting A Remote Node
• Establish a network connection: TCP, Serial, ATM, etc.
Node2Node1
• [optional] Mutually authenticate the connection and establish session keys for encryption of all communication
• Establish a Styx session: this obtains the root of the remote file system
![Page 17: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/17.jpg)
17
Inferno®
The EXPORT Namespace Operation
• Present the current namespace to remote clients
• Listens on a network connection for a Styx session request
• Accepts the mount by providing access to the root of the namespace
• Continually responds to client file requests via the Styx protocol
![Page 18: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/18.jpg)
18
Inferno®
Exporting a Namespace
• Obtain a network connection: TCP Listen, etc
Node2Node1
• [optional] Perform mutual authentication and encryption key setup
• Wait for Styx session request
![Page 19: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/19.jpg)
19
Inferno®
Mini-Summary
• Represent all local resources as file systems
• Namespace provides a single, dynamically configured, hierarchical view of all resources (I.e. file systems)
• Remote resources attached to the namespace
![Page 20: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/20.jpg)
20
Inferno®
Writing Applications
• Applications access resources by accessing files within the namespace
• Use familiar file access functions
• Access is independent of how the files got in the namespace -- local,remote, who cares!
![Page 21: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/21.jpg)
21
Inferno®
Writing File Systems
• Inferno drivers: C modules linked with the kernel
• Limbo programs using the file2chan() system call– makes use of srv device (I.e. file system)
• Limbo written Synthetic File Systems• InfernoSpaces
– Java class library– C library
![Page 22: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/22.jpg)
22
Inferno®
Application Advantages
• Applications can assume location of resources: open(“/x/y”,…)
• Resources can be configured prior to running the applications -- (I.e. an administrative chore)
• No explicit networking code required
• Allows for network independent distributed computing
![Page 23: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/23.jpg)
23
Inferno®
The Styx™ Protocol
• A simple file access protocol• Message passing: transmit-reply (a Styx
Transaction)• Synchronous• 13 message pairs + 1 error reply• Assumes a reliable transport• Allows overlapped transactions• Mostly fixed length messages
![Page 24: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/24.jpg)
24
Inferno®
Styx Message Structure
fid Contents
Message specific data
Unsigned integer that represents “current” file
Unique identifier used to track commands
Indicates message type: initial transmission (T-message) or reply message (R-message)
tagtype
![Page 25: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/25.jpg)
25
Inferno®
Styx Transactions
• NOP• FLUSH• CLONE• WALK• OPEN• CREATE• READ
• WRITE• CLUNK• REMOVE• STAT• WSTAT• ATTACH
![Page 26: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/26.jpg)
26
Inferno®
Summary
Everything is a file +
A method to organize files +
A remote file access protocol =A Distributed Programming Model
![Page 27: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/27.jpg)
27
Inferno®
How is it being used
• Telephony– Call setup– Device control
• Text to Speech
• Network Gateways
![Page 28: Inferno OS](https://reader035.fdocuments.us/reader035/viewer/2022081719/54489553b1af9ff9778b49b5/html5/thumbnails/28.jpg)
28
Inferno®
Questions
???