3.3-linux Disk Management

Source: Internet
Author: User

Linux System Management

Disk Management, File system management

RAID Fundamentals principle, LVM2

Network management: TCP/IP protocol, linux Network properties configuration

Package Management: Rpm,yum

Process Management: Htop,glance,tsar, etc.

Sed and awk

Linux system Boot Process

Kernel Management Basics: compiling kernels, modules

Linux system cropping

Kernel+busybox

Homework: LFS


Linux Disk Management

I/O Ports (interface): I/O device address

All documents:

Open (), read (), write (), close ()

Block devices: block, Access unit "blocks", disk

Character device: Char, Access unit "character", keyboard


Device files: A driver that is associated to a device that can communicate with the corresponding hardware device

Device number:

Main device number: Major numbers, identifying device types

Second device number: Minor numbers, identifying different devices under the same type

HDD Interface type:

Parallel:

ide:133mb/s

scsi:640mb/s

Serial:

sata:6gbps

sas:6gbps

usb:480mb/s


Rpm:rotations per minute


/dev/dev_file

Device file naming for disk devices

Ide:/dev/hd

Scsi,sata,sas,usb:/dev/sd

Different devices: A-Z

/dev/sda,/dev/sdb,......

Different partitions on the same device: ...

/dev/sda1,/dev/sda2 ...

Mechanical HDD:

Track: Tracks

Cylinder: Cylinder surface

Sector: Sector (512bytes)

How to Partition:

According to the cylinder to divide

0 Track 0 Sector: 512bytes

Mbr:master Boot Record (Master boot recording)

446bytes:boot Loader

64bytes: Partition Table

16bytes: Identify a partition

2bytes:55aa

4 primary partitions or 3 primary partitions +1 extended partitions (n logical partitions)


Question: Uefi,gpt?


Partition management tool: Fdisk,parted,sfdisk

Fdisk: Up to 15 partitions can be managed for a single drive

# fdisk-l [-u] [device ...] List disk Partitions

# fdisk Device Execution partition

Command Action

A toggle a bootable flag

b Edit BSD Disklabel

C Toggle the DOS compatibility flag

D Delete a partition (delete partition)

L list known partition types (list partition types)

M Print this menu (Get Help)

n Add a new partition (create partition)

o Create a new empty DOS partition table

P Print the partition table (shows existing partitions)

Q Quit without saving changes (discard update and exit)

s create a new empty Sun Disklabel

t change a partition ' s system ID (adjust partition ID)

U Change display/entry units

V Verify the partition table

W Write table to disk and exit (writes to disk and exits)

X Extra functionality (experts only)


See if the kernel has identified a new partition

# cat/proc/partitions

Notifies the kernel to re-identify the new partition

(1) # partx-a/dev/device

-N m:n

or m,m:,:n

(2) # kpartx-a/dev/device

-f:force

CentOS 5: Using Partprobe

Partprobe [/dev/device]





3.3-linux Disk Management

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.