Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Secondary Storage Management Submitted by: Sathya Anandan(ID:123)

Similar presentations


Presentation on theme: "1 Secondary Storage Management Submitted by: Sathya Anandan(ID:123)"— Presentation transcript:

1 1 Secondary Storage Management Submitted by: Sathya Anandan(ID:123)

2 2 Topics Covered in this Presentation:  The Memory Hierarchy 1.The Memory Hierarchy 2.Transfer of Data Between Levels 3.Volatile and Nonvolatile Storage 4.Virtual Memory  Disks 1.Mechanics of Disks 2.The Disk Controller 3.Disk Access Characteristics

3 3 Secondary Storage Management: Database systems always involve secondary storage like the disks and other devices that store large amount of data that persists over time.

4 4 The Memory Hierarchy: A typical computer system has several different components in which data may be stored. These components have data capacities ranging over at least seven orders of magnitude and also have access speeds ranging over seven or more orders of magnitude.

5 5 The Memory hierarchy from the text book as follows:

6 6 Cache: It is the lowest level of the hierarchy is a cache. Cache is found on the same chip as the microprocessor itself, and additional level- 2 cache is found on another chip. Data and instructions are moved to cache from main memory when they are needed by the processor. Cache data can be accessed by the processor in a few nanoseconds.

7 7 Main Memory: In the center of the action is the computer's main memory. We may think of everything that happens in the computer - instruction executions and data manipulations - as working on information that is resident in main memory Typical times to access data from main memory to the processor or cache are in the 10-100 nanosecond range

8 8 Secondary Storage: Essentially every computer has some sort of secondary storage, which is a form of storage that is both significantly slower and significantly more capacious than main memory. The time to transfer a single byte between disk and main memory is around 10 milliseconds.

9 9 Tertiary Storage: As capacious as a collection of disk units can be, there are databases much larger than what can be stored on the disk(s) of a single machine, or even of a substantial collection of machines. Tertiary storage devices have been developed to hold data volumes measured in terabytes.

10 10  Tertiary storage is characterized by significantly higher read/write times than secondary storage, but also by much larger capacities and smaller cost per byte than is available from magnetic disks.

11 11 Transfer of Data Between Levels:  Normally, data moves between adjacent levels of the hierarchy.  At the secondary and tertiary levels, accessing the desired data or finding the desired place to store data takes a great deal of time, so each level is organized to transfer large amount of data or from the level below, whenever any data at all is needed.

12 12  The disk is organized into disk blocks and the entire blocks are moved to or from a continuous section of main memory called a buffer.

13 13 Volatile and Nonvolatile Storage: A volatile device "forgets" what is stored in it when the power goes off. A nonvolatile device, on the other hand, is expected to keep its contents intact even for long periods when the device is turned off or there is a power failure.

14 14  Magnetic and optical materials hold their data in the absence of power. Thus, essentially all secondary and tertiary storage devices are nonvolatile. On the other hand main memory is generally volatile.

15 15 Virtual Memory: When we write programs the data we use, variables of the program, files read and so on occupies a virtual memory address space. Many machines use a 32-bit address space; that is, there are 2(pow)32 bytes or 4 gigabytes.

16 16  The Operating System manages virtual memory, keeping some of it in main memory and the rest on disk. Transfer between memory and disk is in units of disk blocks.

17 17 Disks: The use of secondary storage is one of the important characteristics of a DBMS, and secondary storage is almost exclusively based on magnetic disks

18 18 Mechanics of Disks: The two principal moving pieces of a disk drive are a disk assembly and a head assembly. The disk assembly consists of one or more circular platters that rotate around a central spindle The upper and lower surfaces of the platters are covered with a thin layer of magnetic material, on which bits are stored.

19 19 A typical disk format from the text book is shown as below:

20 20  0’s and 1’s are represented by different patterns in the magnetic material. A common diameter for the disk platters is 3.5 inches. The disk is organized into tracks, which are concentric circles on a single platter. The tracks that are at a fixed radius from a center, among all the surfaces form one cylinder.

21 21 Top View of a disk surface from the text is as shown below:

22 22  Tracks are organized into sectors, which are segments of the circle separated by gaps that are magnetized to represent either 0’s or 1’s. The second movable piece the head assembly, holds the disk heads.

23 23 The Disk Controller: One or more disk drives are controlled by a disk controller, which is a small processor capable of: Controlling the mechanical actuator that moves the head assembly to position the heads at a particular radius. Transferring bits between the desired sector and the main memory.

24 24  Selecting a surface from which to read or write, and selecting a sector from the track on that surface that is under the head. An example of single processor is shown in next slide.

25 25 Simple computer system from the text is shown below:

26 26 Disk Access Characteristics: Seek Time: The disk controller positions the head assembly at the cylinder containing the track on which the block is located. The time to do so is the seek time. Rotational Latency: The disk controller waits while the first sector of the block moves under the head. This time is called the rotational latency.

27 27  Transfer Time: All the sectors and the gaps between them pass under the head, while the disk controller reads or writes data in these sectors. This delay is called the transfer time. The sum of the seek time, rotational latency, transfer time is the latency of the time.

28 28 Any Questions?

29 29 Reference: Database Systems The complete Book-Second Edition


Download ppt "1 Secondary Storage Management Submitted by: Sathya Anandan(ID:123)"

Similar presentations


Ads by Google