Shared file. LINUX Virtual File System. Hard link. Linux ext2fs. Disk layout in general. Linux: ext2fs & ext3fs, Windows NTFS Distributed Processing



Similar documents
Network File System (NFS) Pradipta De

CS 377: Operating Systems. Outline. A review of what you ve learned, and how it applies to a real operating system. Lecture 25 - Linux Case Study

CHAPTER 17: File Management

File Systems Management and Examples

COS 318: Operating Systems. File Layout and Directories. Topics. File System Components. Steps to Open A File

Chapter 2: Remote Procedure Call (RPC)

Chapter 11 Distributed File Systems. Distributed File Systems

Chapter 11: File System Implementation. Operating System Concepts with Java 8 th Edition

We mean.network File System

Infrastructure that supports (distributed) componentbased application development

Two Parts. Filesystem Interface. Filesystem design. Interface the user sees. Implementing the interface

Chapter 12 File Management. Roadmap

Chapter 12 File Management

File System Management

1. Introduction to the UNIX File System: logical vision

Linux Kernel Architecture

Survey of Filesystems for Embedded Linux. Presented by Gene Sally CELF

The Linux Virtual Filesystem

Chapter 11: File System Implementation. Operating System Concepts 8 th Edition

COS 318: Operating Systems

Network Attached Storage. Jinfeng Yang Oct/19/2015

Lehrstuhl für Informatik 4 Kommunikation und verteilte Systeme. Middleware. Chapter 8: Middleware

Operating Systems. Design and Implementation. Andrew S. Tanenbaum Melanie Rieback Arno Bakker. Vrije Universiteit Amsterdam

Outline. Operating Systems Design and Implementation. Chap 1 - Overview. What is an OS? 28/10/2014. Introduction

TELE 301 Lecture 7: Linux/Unix file

Microkernels, virtualization, exokernels. Tutorial 1 CSC469

Windows OS File Systems

Recovering Deleted Files in Linux

Operating Systems File system mounting, sharing, and protection. File System Mounting

Invocación remota (based on M. L. Liu Distributed Computing -- Concepts and Application

Middleware Lou Somers

Lecture 17. Process Management. Process Management. Process Management. Inter-Process Communication. Inter-Process Communication

File Systems for Flash Memories. Marcela Zuluaga Sebastian Isaza Dante Rodriguez

CHAPTER 2 MODELLING FOR DISTRIBUTED NETWORK SYSTEMS: THE CLIENT- SERVER MODEL

Distributed File Systems. NFS Architecture (1)

Client/Server Computing Distributed Processing, Client/Server, and Clusters

Chapter 6, The Operating System Machine Level

DualFS: A New Journaling File System for Linux

OPERATING SYSTEMS FILE SYSTEMS

COMP5426 Parallel and Distributed Computing. Distributed Systems: Client/Server and Clusters

Caché Integration with a Network Appliance Filer

Chapter 10 Case Study 1: LINUX

Objectives. Distributed Databases and Client/Server Architecture. Distributed Database. Data Fragmentation

Training on Linux System Administration, LPI Certification Level 1

Chapter 12 File Management

LSN 10 Linux Overview

Quick Start - NetApp File Archiver

Oracle Cluster File System on Linux Version 2. Kurt Hackel Señor Software Developer Oracle Corporation

SOFT 437. Software Performance Analysis. Ch 5:Web Applications and Other Distributed Systems

CSE 120 Principles of Operating Systems

CS 416: Opera-ng Systems Design

Communication. Layered Protocols. Topics to be covered. PART 1 Layered Protocols Remote Procedure Call (RPC) Remote Method Invocation (RMI)

How To Write A Network Operating System For A Network (Networking) System (Netware)

Chapter 3 Operating-System Structures

CHAPTER 15: Operating Systems: An Overview

Windows NT. Chapter 11 Case Study 2: Windows Windows 2000 (2) Windows 2000 (1) Different versions of Windows 2000

CS 153 Design of Operating Systems Spring 2015

Module 20: The Linux System

HP-UX System and Network Administration for Experienced UNIX System Administrators Course Summary

UNIX File Management (continued)

Networks and Protocols Course: International University Bremen Date: Dr. Jürgen Schönwälder Deadline:

<Insert Picture Here> Oracle Cloud Storage. Morana Kobal Butković Principal Sales Consultant Oracle Hrvatska

How To Encrypt A Computer With A Password Protected Encryption Software On A Microsoft Gbk (Windows) On A Pc Or Macintosh (Windows Xp) On An Uniden (Windows 7) On Pc Or Ipa (Windows 8) On

Ekran System Help File

Distributed Systems. REK s adaptation of Prof. Claypool s adaptation of Tanenbaum s Distributed Systems Chapter 1

On Benchmarking Popular File Systems

Distributed File Systems Part I. Issues in Centralized File Systems

Matisse Server Administration Guide

Storage and File Systems. Chester Rebeiro IIT Madras

CS3210: Crash consistency. Taesoo Kim

USING USER ACCESS CONTROL LISTS (ACLS) TO MANAGE FILE PERMISSIONS WITH A LENOVO NETWORK STORAGE DEVICE

USB 2.0 Flash Drive User Manual

Red Hat System Administration 1(RH124) is Designed for IT Professionals who are new to Linux.

Socket = an interface connection between two (dissimilar) pipes. OS provides this API to connect applications to networks. home.comcast.

Oracle Tuxedo Systems and Application Monitor (TSAM)

Network File System (NFS)

Session NM059. TCP/IP Programming on VMS. Geoff Bryant Process Software

EMC DOCUMENTUM xplore 1.1 DISASTER RECOVERY USING EMC NETWORKER

Distributed File Systems

W I S E. SQL Server 2008/2008 R2 Advanced DBA Performance & WISE LTD.

Distributed Systems. Distributed Systems

File-system Intrusion Detection by preserving MAC DTS: A Loadable Kernel Module based approach for LINUX Kernel 2.6.x

Designing an NFS-based Mobile Distributed File System for Ephemeral Sharing in Proximity Networks

An Open Source Wide-Area Distributed File System. Jeffrey Eric Altman jaltman *at* secure-endpoints *dot* com

Middleware: Past and Present a Comparison

Red Hat Certifications: Red Hat Certified System Administrator (RHCSA)

Ryusuke KONISHI NTT Cyberspace Laboratories NTT Corporation

Open Source Data Recovery

2.1 What are distributed systems? What are systems? Different kind of systems How to distribute systems? 2.2 Communication concepts

Multiple Job Scheduling Environments.

Naming. Name Service. Why Name Services? Mappings. and related concepts

SMTP-32 Library. Simple Mail Transfer Protocol Dynamic Link Library for Microsoft Windows. Version 5.2

Transcription:

Linux: ext2fs & ext3fs, Windows NTFS Distributed Processing Ch 12.8-9 [Stal 05] Ch 10.6.4, 11.6-7 Ch 20.7 [DDC 04] Ch 13 14.3 [Stal05] WEEK 9 Shared file Hard link Direct link from several directories Multiple owners, all with same rights removed from one directory available still from other locations Soft link (symbolic link) New file, which has file type: symbolic link Content of the new file: path to the actual file (string that contains directories and file name) Original file exists only in one directory ( -> just one owner) owner removes the others cannot access, the link is invalid 1 2 Hard link LINUX Virtual File System Identical interface from the applications Supports several actual different file systems All requests via VFS 3 4 Disk layout in general MBR (master boot record) Flash BIOS Partition table information about the file system type on each partition start and end points of each partition Linux ext2fs block groups Each group is one continuous area of the disk i-nodes and datablock of one group cose to each other Shorter track distances within one file All block sizes are identical(1 KB) All i-node sizes are 128B (trad. UNIX 64B) Fig. 6-11 Fig. 10-35 5 6 Syksy 2007, Tiina Niklander 17-1

ext2fs superblock 0 1 16 Number of free i-nodes 24 Block size 32 Blocks per group 40 i-nodes per group 48 Time of last write 56 Ext2signat. 64 Time of last test 72 Operating system 80 RESUID 2 0 Number of i-nodes 8 Number of reserved blocks Status 3 RESGID 4 Number of blocks Number of free blocks First data block Fragment size Fragments per group Time of mounting Status Error behav. 5 Max test interval File system revision Pad word 6 7 Max. mnt cnt Pad word ext2fs group descriptor 8192 blocks in one group Each group has a copy of the super block and group descriptor Redundant information the descriptor of group 0 is up-to-date One item for one block in the group desciptor has 24 B bg_block_bitmap location info(4 B) bg_inode_bitmap location info(4 B) bg_inode_table location info(4 B) bg_free_blocks_count (2 B) bg_free_inodes_count (2 B) bg_used_dirs_count (2 B) bg_pad, bg_reserved (6 B) blocksize Pad words 7 8 ext2fs i-node Access Control List 0 Mode 8 Access time 16 Time of modification 24 Gid 32 File attributes 40 0 88 One-stage indirect block 96 Three-stage indirect block 104 File ACL 112 Fragment address 1 2 3 4 5 6 Uid Link counter 120 Reserved (OS-dependent) File size No. of blocks 12 direct blocks Time of creation Time of deletion Reserved (OS-dependent) Two-stage indirect block File version Directory ACL Reserved (OS-dependent) 7 Linux procfs - processfile system Not a true physical file system, just an interface to process control blocks directory /proc Each subdictory has its own read() ja write() operations /proc/4321 is the directory for process 4321 read() and write() operations access a protected data structures using the control mechanisms of the file system (protection, concurrency) 9 10 NFS See Ch 10.6.4 (Fig 11.15, [SGG07] 11 Linux ext3fs ext3fs = journaling ext2fs Journaling is only an additional layer o top of ext2fs Journaling layer is undependent of the file system under it -> ext2fs does not need to know Operations follow transactional semantics [Tweedie talk, 20.7.2000] (http://olstrans.sourceforge.net/release/ols2000-ext3/ols2000-ext3.html) Main goal: shorten a recovery duration after an unplanned shutdown Fsck (e2fsck) takes hours in a big file system There is a need for better availability Compatible with ext2fs Clean, correctly unmounted ext3fs does not contain any journal information, it can be mounted also as ext2fs file system TKTL: uses ext3fs 12 Syksy 2007, Tiina Niklander 17-2

Windows NTFS: Master File Table 13 14 15 16 TCP/IP concepts 17 18 Syksy 2007, Tiina Niklander 17-3

Process communication : Ch 14 message passing Reliable / unreliable Synchronous / asynchronous Persistent / transient Binding Based on network topology or message content Static / Dynamic Message is buffered on the way 19 20 Esimerkki: header.h Esimerkki: server 21 22 Esimerkki: client 1-27 b Process communication: RPC Remote procedure call looks to the calling client as any other local procedure (or function or method) call. 23 24 Syksy 2007, Tiina Niklander 17-4

RPC Remote Procedure Call DCE architecture (example of RPC usage) Distributed Applications OSF s Distributed Computing Environment (DCE) Distributed File Service Time Service RPC Service Naming Service Security Service Threads Service 25 Transport Services / Operating System 26 RPC elements RPC stubs Hide the actual communication from the calling program Marshal and unmarshal the parameters Transportation service Needed to delivered the message containing the marshalled call Can be provided by OS or middleware Name service: look up, binding Contains interface definitions Binding a Client to a Server Client-to-server binding in DCE. 27 28 RPC: a Schematic View Passing value parameters in RPC System A System B X, Y, Y Z Thread P Y=FNCT(X,Y) FNCT(a,b) c:=comp} return c. a:=x; b:=y; RPC package RPC package 29 Steps involved in doing remote computation through RPC 30 Syksy 2007, Tiina Niklander 17-5

Steps in implementation of the client and the server DCE model Esimerkki: simple.idl IDL Interface Description Language to describe the signature of the remote procedure IDL is used to automatically generate stubs Linux rpcgen uses RPC language instead of idl /* SIMPLE.IDL */ [ uuid(004c4b40-e7c5-1cb9-94e7-0000c07c3610), version(1.0) ] interface simple void simple_operation( [in] long x, [out] long *y ); } 31 32 Esimerkki: simple-client.c Esimerkki: simple-server.c 1/3 /* SIMPLE_CLIENT.C */ #include <stdio.h> #include "simple.h" main(int argc, char *argv[]) idl_long_int x; idl_long_int y; if (argc < 2 ) x = 1; } else x = atol(argv[1]); } simple.h is automatically generated By idl compiler from simple.idl /* SIMPLE_SERVER.C */ #include <stdio.h> #include <dce/rpc.h> #include "simple.h" #define ERR_CHK(stat, msg) if(stat!= rpc_s_ok)\ fprintf(stderr,"error: %s in file: %s at line %d.\n",msg, FILE, LINE );\ exit(1); } /***** Server Control *****/ simple_operation(x, &y); /* This is the Remote Procedure Call */ printf("the answer is: %ld.\n"); return(1); } 33 main() error_status_t status; rpc_binding_vector_t *bindings; unsigned_char_t *name = "/.:/applications/simple"; 34 Esimerkki: simple-server.c 2/3 rpc_server_register_if(simple_v1_0_s_ifspec, NULL, NULL, &status); ERR_CHK(status,"Could not register interface"); rpc_server_use_all_protseqs(rpc_c_protseq_max_regs_default, &status); ERR_CHK(status,"Could not use all protocols"); rpc_server_inq_bindings(&bindings, &status); ERR_CHK(status,"Could not get binding vector"); rpc_ns_binding_export(rpc_c_ns_syntax_default, name, simple_v1_0_s_ifspec, bindings, NULL, &status); ERR_CHK(status,"Could not export bindings"); Esimerkki: simple-server.c 3/3 - the actual procedure to be called /***** Server Operation *****/ void simple_operation(idl_long_int x, idl_long_int *y) *y = ++x; } rpc_ep_register(simple_v1_0_s_ifspec, bindings, NULL, NULL, &status); ERR_CHK(status,"Could not register endpoint"); printf("listening for requests\n"); rpc_server_listen(rpc_c_listen_max_calls_default, &status); } 35 36 Syksy 2007, Tiina Niklander 17-6