(File System) - PowerPoint PPT Presentation

1 / 39
About This Presentation
Title:

(File System)

Description:

Lecture 2 (File System) ... – PowerPoint PPT presentation

Number of Views:167
Avg rating:3.0/5.0
Slides: 40
Provided by: Zah68
Category:

less

Transcript and Presenter's Notes

Title: (File System)


1
Lecture 2
????? ?????? ?? ????? ???????? ???? ?? (File
System)
2
????? ?????? ?? ????? ???????? ???? ?? (File
System)
  • ???? ( File ) ????? ?
  • ???? ????? (File System) ????? ?
  • ???? (Disk) ???? ?
  • ?????? ??????? ?? ??????? ???? ????? ???????

3
????? ?????? ?? ????? ???????? ???? ?? (File
System)
  • ???? ( File ) ????? ?
  • ?????? ?? ?? ???? ?? ( Data ) ?? ???? ???? ??????
    ????? ???? ((Operating System ???? ??????? ?
    ?????? ??????.
  • ?? ???? ?? ???? ????? ? ?????? (Persistent) ??
    ???? ?? ??????.
  • ???? ????? (File System) ????? ?
  • ??? ???? ?????? ?? ?? ????? ???? ?????? ?? ??
    ????? ? ??? ?? ????? ?? ??????? ??????? ???? ??
    ?? ???? ????
  • ?????? ?????? ?????? (Directory service )
  • ???????? ?????? ?????? (Storage service )

4
????? ???????? ???? ?? (File System)
????? ????? ?? ???? ????? ????? ????
5
????? ???????? ???? ?? (File System)
  • ?????? ?????? ?????? (Directory )
  • ?????? ???????? ?????? (Logical Naming)
  • ?????? ?????? ? ??????? ????? ?? ?????? ( Meta
    Data )
  • ?????? ????????? ? ???? ???? ?????? (
    Organization )
  • ???????? ?????? ?????? (Storage )
  • ??????? ?????? ?? ???? ?? ?????? ? ?????
    (Persistent Reliable)
  • ????? ??????? ????? ? ??? ? ????????? ?????? ????
    ???????
  • ?? ?????? ?????? ?????? ??? ??????? (Sharing)
  • ????? ????? ?? ?????? ?? ?????? (Access Security)

6
????? ???????? ???? ?? (File System)
  • ? ??? (Disk) ???? ?
  • ?? ??? ????? ???????? ?????? ?? ???? ????? ????
    ??????? ???? ??????? ?????.
  • ?? ?????? ????? ????? ?? ???? ????? ????? ????
    ?????? ????.
  • ?????? ???? ?? ??? ? ??? ?? ???? ?
  • ??? ?????? ??? ?? ?????? ?????? ?? ??????? ????
    ??? ???? (Disk) ???? ?? ???? ????? (Disk Handler)
    ? ?? ?????? ????? ???? ???? ????? ????? ?????.

7
?????? ?????? ?????? (Directory)
  • ????????? ???????? ??? ???????? ?????? ??????
    ???? ????
  • ?????? ???? ?? ???? (Flat Directory
    Structure)
  • ?????? ?? ???? (2 Level Directory
    Structure)
  • ?????? ???????? (Tree Directory
    Structure)
  • ?????? ???? (Graph Directory
    Structure)

8
?????? ?????? ?????? (Directory)
  • 1 - ?????? ???? ?? ???? (Flat Directory
    Structure)
  • ????????? ???? ?? ?? ?? ??? ??? ???? ? ???? ??
    ??? ???? ??????? ?????.
  • ??? ?????? ??? ???? ????? ??? ????? ???? ?
    ??????? ???? ??????? ?? ????.
  • ???? ????????? ?????? ?? ??? ??? ???? ??????.
  • ????? ?? ???? ?? ?? ??? ???? ?????? ???.

9
?????? ?????? ?????? (Directory)
  • 2 - ?????? ?? ???? (2 Level Directory
    Structure)
  • ??????? ??????? ?? ?? ???? ?? ?? ?? ?????????
    ?????? ? ?????? ???? ?? ??????? ????? ???? ??
    ????.
  • ??? ????????? ??? ??????? ???? ?????? ???.

10
?????? ?????? ?????? (Directory)
  • 3 - ?????? ???????? (Tree Directory
    Structure)
  • ??? ????? ????? ?????? ??? ?? ????.
  • ?? ????? ????????? ?????? ?? ?? ????? ??? ????
    ??????.
  • ??? ????? ?? ?????? ?????? ?? ???? ?? ?? ????
    ????? ?? ???? ??? ????.
  • ??? ?? ???? ?? ???? ?? Path ????? "x/y/cat" ?????
    ?? ???.

11
?????? ?????? ?????? (Directory)
  • 4 - ?????? ???? (Graph Directory
    Structure)
  • ??? ?????? ?? ????? ?????? ??? ? ????? ?? ??????
    ?????? ?????? ? ????? ?????? (Link) ??? ???????
    ????? ?? ???? ?? ????.
  • ?? ??? ?????? ?????? ????? ??? ?????? ?? ???? ??
    ????? ????? ?????? ?? ?????? ?????? ?? ?????? ???
    ??? ?? ???? ???? ??? ??? ??? ????? (path) ?????
    ????.

12
?????? ??? ??????? ? ???? ????? (File System
Interface)
  • ?????? ????? ?? ?????? ?????? (Directory)
  • ????? ?? ??? Directory
  • ????? ? ??? ?? ??? ????? ??????
  • ????? ????? ?? ???? ?? ?? Directory
  • ????? ????? ?????? (Access Rights)
  • ????? ????? ??????
  • ?????? ????? ?? ????? ???? ?????? (Storage)
  • ?????? ????
  • ????? ?? ?? ???????? ????
  • ???? ????
  • ????? (Seek) ?? ???? ?? ????

13
?????? ?????? (File Attributes)
  • ?????? ?????? ???? ???
  • ?????? ? ??????? ????? ?? ?????? ( Meta Data)
    ???? ????? ??? ?? ?????
  • ??? ????
  • ??? ?????? ???? ) ??? ????(
  • ?????? ????
  • ??? ???? ????
  • ????? ?????? ?? ????
  • ??????? ????? ? ?????? ? ?? ??? ????? ????
  • ??? ??????? ??? ??????
  • ?????? ? ??????? ????? ?? ?????? ????? ?? ?????
    ?? ???? ?????? ?? ???? (Path) ??????? ??????.

14
?????? ??????? ?? ??????? ???? (Logical /
Physical Mapping)
  • ?? ?????? ???????
  • ?? ???? ?????? ?????? ?? ?? ???????? ????
    (Logical Records) ????? ?????.(????)
  • ?? ?????? ???? ?????
  • ???? ???? ?? ????? ?????? ?? ?? ??????? ????
    (Physical Blocks) ????? ?? ???.
  • ??????
  • ?????? ?? ?????? ??? ?? ?????? ????? ????.
    (Logical / Physical Mapping)
  • ?????????????
  • ??????? ???? ??????? ??? ?????? ????? ?? ???.
    (Fragmentation) ... (????)

15
?????? ??????? ?? ??????? ???? (Logical /
Physical Mapping)
  • ?????? ????? ?????? ??????? ?? ?????? ????? ??
    ????? ? ?????? ?? ?????? ?????
  • 1 ?????
  • ??????? ??? ????? ???? ?? ?? ????? ???
    (Portability)
  • ????? ??? ?????? ??? ????? ? ?????? ?????
    (Performance)
  • ????? ????? ?????? ????? ? ??????? ??? ?? ??????
  • ????? ?? ?????? ?????? (Disk Handler) ...
    (????)
  • 2 ?????
  • ?????? ????? ???? ???? ??????? ??? (Optimization)
  • ??????? ?????? ??????? ?? ??? ????? ... (????)

16
?????? ??????? ?? ??????? ???? (Access Methods)
  • ?????? ?? ???? ??? ?? ???? ?? ?? ???? ?????
    ???? ???????
  • ?????? ???? ??? (???? ???? ?? ???? ?? ????? ??
    ?????) (Sequential)
  • ?????? ?????? ?? ?? ???? (Direct) ...
    (??????)
  • ?????? ?? Array ?? ????? RAM (Memory Mapped)
  • ?????? ?????? ?? ??? ?? ???? (Indexed)

17
??? ? ??????? ???? ?? (Data Consistency)
  • ????? ?? ??? ???? ?? ?????
  • ?? ?????? ??????? ?????? ?? ???? ??? ????? ?? ??
    ???? ?? ??? ?? ??????? ????? ???? ??
    ????????????? ????? ?????. (?????)
  • ??? ???? ??????
  • ?? ????? UNIX ???? ??? ?? ????? ?? ??? ????? ???
    ?? ???? ?????? ??????? ????(? ?? ?? ???? ?????
    ?????? ?????) ???? ?????? ?? ???? ... (???!)
  • ?? ???? ???? ?? ????? ?? ?? ???? ???? ??? ???? ?
    ???? ??? ????? ??? ?? ?? ???? ?????? ?????? ????
    ??????? ??? ????.
  • ??????
  • ?? ?? ?? ???? ??? ) ?? ???? ???? ??? ( ???????
    ??? ??????? ??? ??? ??? ???? ?? ? ??????? ????
    ????????. (??? ???? ????)

18
??? ????? ???? ?? (Access Protection)
  • ????? ?? ????? ???? ?? ?????
  • ??? ????? ???? ?? ?? ????? ????? ?????? ?? ????
    ?????? ??????? ???? ?? ????.
  • ??? ????? ?????? ?? ?? ????? ???????
  • ?????? ( Read )
  • ????? ( Write )
  • ???? ( Execute )
  • ??? ???? ?? ( Delete )
  • ????? ????? ???? ?? ( Append )
  • ?????? ?????? ?????? ( File Attributes )
  • ?????? ?????? ( Files Directory Search )
    ... (??? ????)

19
??? ????? ???? ?? (Access Protection)
  • ?? ??????? ???? ????? ????? ???? ?????
  • ?? ??? ????? ????? ?????? ?? ????? ??????? ????
    (??? ??????) ?? ??????? ? ???????? ?? ?? ??
    ?????? ????? ????? ???? ?????? . ( Access Lists )
  • ?? Unix ??? ???? ??? ( Access Groups ) ???? ??
    ??? ?? ???? ????? ??????? ?? ?? ??? ?? ????
  • 1- ??? ?? ?? ???? ( Owner )
  • 2- ??????? ?? ???? ?? ?? ?? ???? (Group )
  • 3- ??????? ???? (Others )
    ... (?????)

  • (??? ??? ??? ???? ?? ????)

20
?????? ?? ???? ??? ?? ???? (Opening a File)
  • ?????? ?? ???? ??? ?? ???? ????? ???? ??????
  • ??? ?? ?? ???? ?????? ?? ???? ??? ?? ???? ??????
    ???? ?? ??????? ??? ????.
  • ??? ????? ?? ???? ???? ???
  • ??? ????? ?? ???? ?? ???? ???? ????? ???????
    ????? ?? ???? ?? ????? ????? ??????.
  • (?? ????)

21
?????? ?? ???? ??? ?? ???? (Opening a Files)
  • ??? ????? ?? ???? ????? ????
  • ???? ???????? ?? ?????? ??????? ????? ???
    ???????? ??????? ???????? ?? ????? ????? ?? ????
    Open File Table ??????? ?????.
  • (?? ??? ?????????)

22
?????? ?? ???? ??? ?? ???? (Opening a Files)
  • ?? ?? ??? ???????? ?? ????? ????? ???? ????
    ???????
  • ??????? ????? ????
  • ???? ???? ??? ????
  • ? ???? ???? ???
  • ???? ????? ? ??????
  • ??????? I/O
  • ????? ??? ???
  • Lock ??
  • ????
  • ??????? ????? ?? ?? Process ????
  • ????????? ????? (Pointers)
    ... (?????)
  • ??? ????? ? ?????? (Access Permissions)
  • ????

23
?????? ?? ???? ??? ?? ???? (Opening a Files)
????? ??? ????? ?? ???? ????? ????
24
??????? ?????? ??? ????(Disk Allocation)
  • ???? ???? ???? ?? ???? ?? ??? ???? ?? ?? ???????
    ?????? ???? ?????
  • 1- ??? ???
  • ????? ?????? ?? ???? ???? ???? ??? ?? ??????
    ????? (Link) ?? ????. (Linked Allocation)
  • ?? ??? ??? ???????? ?? ???? ???? ??? ???? ??????
    ???? ??? ?????? ?????? ?? ?? ????? ?? ???? ????
    ?????? ???. (????)

25
??????? ?????? ??? ????(Disk Allocation)
  • ???? ???? ???? ?? ???? ?? ??? ???? ?? ?? ???????
    ?????? ???? ?????
  • 2- ??? ???
  • ???? ? ???? ????? ?? ????? ????? ???? ??? ????
    ?? ???? ?? ?? Index ???????? ?? ???? (Indexed
    Allocation)
  • ?? ??? ??? ????? ?????? ?????? ?? ?? ????? ??
    ???? ???? ????? ????. (????)

26
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ?????? ??? ????? ?????? ????? ? ?? ?? ????? ?????
    ? ??????? ?? ?????
  • ?????? ?????? ?? ?? ?????? ???????? ???????
    (I-nodes Directories)
  • ?????? ??????? ?????? ?? ?? ?????? ????????
    ??????? (Open File Structure)
  • ????????? ???? ???? ????? ????
    (Disk Organization)
  • ???????? ?????? ??? ???? ?? ?? ???? ????? ??????
    (Network File System)

27
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ?????? ?????? ?? ?? ?????? ???????? ???????
  • ????? Directories
  • ????? I-nodes
  • ?????? Directory ????? ????
  • ?????? ???? ?? ????? ?????? ? ????? i-node ??????
    ?? ????.

28
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ?????? ?? ???? I-node ????? ????
  • ?????? ???? ????? ?? ?? ???? ?? ?? ???? I-node
    ??????? ?? ????.
  • ???? ???? ???? ??? ???? ????? ??????? 8 ????
    ????? ???? ??????.
  • ?? ??? Indexed Allocation ???? ???? ??? ?? ????
    ??????? ?? ???.
  • 12 ????? ?? ?????? (direct pointer) ????? ??????
    ?????? ?? ???? ??? ???????? ?? ?? ????? ???? ??
    96 ???? ???? ???? ????? ??????.
  • ?????? ????? ?? ???? (Single indirect pointer) ??
    16 ??? ???? ???? ????? ??? ?? ?? index ????? ????
    ?????? ????? ???.
  • ??? ? ?? ????? ?? Double indirect pointer ?? 4
    ???? ???? ???? ???? ? ?? ?? ??? ?????? ????
    ?????? ?? ?????.
  • ? ??? ????? ?? ?????????? 64 ???? ?? 32 ???? ????
    ????? ???? ?? ???.

29
???????? ?????? ??? ????? ?????? (Unix File
System)
?????? ?? ???? I-node ????? ????
30
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ?????? ??????? ?????? ?? ?? ?????? ????????
    ???????
  • ???? File Descriptor Table ??????? ????? ??
    ??????? ??? ??? ? ????????? ???? ??????? ?? ??
    process ?? ???? ?? ???.
  • ???? (OFT) Open File Table ??????? ????? ?? ????
    ??????? ??? ??? ?? ????? ? ????? ????? ?????? ??
    ???? open count ? ??? ??? ????? ?? ?? ????
    (Locks) ????? ????? ? ??? ???? ?? ? ???? ?? ????
    ?? ???.
  • ???? File Allocation Table ??????? ????? ??
    ??????? ???? ?????? ?? ???????? ?? ???.
  • ???? Table of I-nodes ?? ??? ?? I-nodes ???
    ??????? ???? ??????? ?? ?? ????? RAM ??????? ??
    ???.

31
???????? ?????? ??? ????? ?????? (Unix File
System)
?????? ??????? ?????? ?? ?? ?????? ????????
???????
32
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ????????? ???? ???? ????? ???? (Disk
    Organization)
  • ?? ???? ???? ?? ????? ???? ??? File System ????.
  • ?? ???? ????? ??? ?? Logical Disk ????? ??? ?
    ???? ?? boot block ? ?????? Cylinder group
    ??????.
  • ????? ???? ?? Logical Disk ?? ??? boot block
    ?????? ?? ???? boot strap program ??????.
  • ???? logical disk ?? ????? Cylinder group ?????
    ?????.
  • ?? Cylinder group ???? ?????? Cylinder ?????
    ?????? ??????

33
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ????????? ???? ???? ????? ???? (Disk
    Organization)
  • ?? ?? Cylinder group ?? Super block ???? ???? ??
    ???? ??????? ???? File System ??????.
  • ?? ?? Cylinder group ?? cylinder block ???? ????
    ?? ???? ??????? ????? ????? ?? ??????? ????
    (free) ? i-node ??? ???? ? ??? ??????? ????? ???
    ???? ???? ????? ??? ? ???? ??????.
  • ?? Cylinder group ???? ?? ???? ???? ??? ????
    i-node ?? ??????.
  • ???? ???? ????? ?? cylinder group ???? ???????
    ???? (data blocks) ???? ?????.

34
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ????????? ???? ???? ????? ???? (Disk
    Organization)
  • ???? ???? ???? ??????? ?? ???? ???? ?????? ????
    ???? ??????.
  • ?? ???? ???? ?? ????? ????? ???? ? ????? ?? ???
    ??? ???? ???? ??? ??? ???? )????(Sector ?????
    ?????.
  • ??????? ?????? ??????? ?????? ???? ?? ?? ?????
    RAM ?? ???? ? ?????? ???? ????????.
  • ??????? ?????? ?? ?? ??????? ????? ? ?? ??? ????
    ???? ?? ???? ???? ??????? ??????.
  • ???? ???? ?? ?? ???? ????? ?????? ???? ??
    Sector?????? ????? ???? ?????.
  • ??????? ????? ?? ???? ???? ???? ?? ????? ????
    ?????? ??? Block ?? ? Sector?? ????. ???????
  • ?????? Block ?? ??? 4 ?? 8 ???? ???? ??????.
  • ?????? Sector?? ??? 0.5 ?? 2 ???? ???? ??????.

35
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ????????? ???? ???? ????? ???? (Disk
    Organization)
  • ????? Cylinder Group ?? ???? ?????? BSD 4.2 ??
    ??? ? ?? ??? ??????? ???? ??? ?? ???? ?? ??
    ?????? ????? ????? ????? ???.
  • ???? I-node ?? ???? (? ??? ??????? ???? ??? ?????
    ??) ?? ???? cylinder group ????? ?? Directory
    ??? ??????.
  • ?? Sub-directory ?? ?? cylinder group ???? ?????
    ?????.
  • ???? ??????? ?? ?????????? ???? ???? ?? cylinder
    group ?????? ?? ???? ????? ??????? ???? ???
    ?????? (indirect blocks) ????? ?? ?? ???? ?? ??
    cylinder group ???? ????? ??????.

36
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ???????? ?????? ??? ???? ?? ?? ???? ?????
    ?????? (Network File System)
  • ???? ????? ??? ???? SUN ????? ????? ??? ??? (open
    systems) ? ??????? ??? ?????? (NFS , XDR , RPC )
    ?? ????? ????.
  • NFS ?? ?? ????????? ???? ????? ??? heterogeneous
    ????? ??? ???.
  • NFS ?? ??? Client /Server ?? ????? ????? ??
    ??????? ?? ????? ? ???? ?????? ????? ?? Unix ???
    ???.
  • ?? ????? ??????? ?? ????? Server ????? ?????? ??
    ??????? ??? ?? ?? ????? ????? ( Client ) ????.

37
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ???????? ?????? ??? ???? ?? ?? ???? ?????
    ?????? (Network File System)
  • ????

38
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ???????? ?????? ??? ???? ?? ?? ???? ?????
    ?????? (Network File System)
  • ????? Client ??????? ??????? ???? ????? (mount)
    ?? ?? ??? ?? Directory ? ???? Sub-directory ???
    ?????? ? ?? ????? Server ????.
  • ???? ????? ??? ???? ? ???? SUN ????? (Virtual
    File Systems) VFS ? ???????? i-node ?? ?? V-node
    ??????? ????.
  • V-node ????? ????? ????? ?????? ?? ??? Unique ??
    ??? Network ?? ????? ?? ????.

39
???????? ?????? ??? ????? ?????? (Unix File
System)
  • ???????? ?????? ??? ???? ?? ?? ???? ?????
    ?????? (Network File System)
Write a Comment
User Comments (0)
About PowerShow.com