文件名称:
Linux如何使用UUID挂载挂载数据盘
开发工具:
文件大小: 3mb
下载次数: 0
上传时间: 2019-07-02
详细说明:
Linux如何使用UUID挂载挂载数据盘60
H ChenLong-root
266-VM
h-141×41
rootei-2-22266-VM: -ft fdisk
Disk /dev/sda: 53.7 GB, 53687E91200 bytes
255 heads, 63 sectors/track, 6527 cylinders, total 104857600 sectors
Units sectors of 1 512= 512 bytes
Sector size (logical/physical): 512 bytes /512 bytes
1/0 size (minimum/optimal): 512 bytes /512 bytes
Disk identifier: 0x00010a5a
Device Boot
start
Blocks
syste
/dev/ sda1
499711
24883283 Linux
/dev/sda2
51758164855551521768975 Extended
/dev/sda5
581768184855551521758968 e Linux LVH
Disk /dev/mapper/i--2--22266--VM-root: 51.8 GB. 51787071488 bytes
255 heads, 63 sectors/track, 6296 cyLinders, total 101146624 sectors
Units
ctors of 1 512=512 bytes
Sector size (logical/physical): 512 bytes /512 bytes
/0 size (minimum/opt
512 bytes /512 bytes
Disk identifier: OxC0000000
Disk /dev/mapper/i--2--22266--VN-root doesn 't contain a valid partition table
Disk/dev/mapper/1--2--22266--VN-swap-1: 1606 MB, 1606418432 bytes
255 heads, 63 sectors/tr
95 cylinders, total 3137536 sectors
nits= sectors of
512=512 bytes
Sector size (logical/physical): 512 bytes 512 bytes
1/0 size (minimum/optimal): 512 bytes 512 bytes
Disk identifier: 0x00000000
Disk /dev/mapper/i--2--22266--VN-swap 1 doesn't contain a valid partition table
Disk /dev/sdb: 32.2 GB, 32212254720 bytes
255 heads, 63 sectors/track, 3916 cylinders, total 62914560 sectors
Units
512- 512 bytes
Sector size (Logical/physical): 512 bytes /512 bytes
1/0 size (mini mum/optimal): 512 bytes /512 bytes
Disk identif
xe00099
Disk /dev/sdb doesn't contain a valid partition table
rooti-2-22266-WM:-#
合Cher
2266-VM:~-ssh-141
root1-2-22266-VM: -f fdisk -L
Disk /dev/sda: 53.7 GB, 53687091200 bytes
255 heads, 63 sectors/track, 6527 cylinders, total 104857600 sectors
Units sectors of 1 4 512 =512 bytes
Sector size (Logical/physical): 512 bytes /512 bytes
1/0 size (minimum/optimal): 512 bytes /512 bytes
Disk identifier: OxB9610a5a
Device Boot
tart
Blocks Id System
/dev/sda1
7648
499711
24883283L1nuX
dev/ sda2
7581c4855551521758975 Extended
/dev/sda5
5176616485555152176B968 e Linux LVH
Disk /dev/mapper/1--2--22266--VN-root: 51.8 GB, 51787071488 bytes
255 heads, 63 sectors/track, 6296 cylinders, total 101146624 sectors
Units sectors of 14 512 =512 bytes
Sector size (logicaL/physical): 512 bytes 512 bytes
1/0 size(mini mum/optimaL): 512 bytes /512 bytes
Disk identifier: Ox66000000
Disk /dev/mapper/1--2--22266--VN-root doesn't contain a valid partition table
Disk /dev/mapper/1
22266-N-swap_1:16068,1606418432 bytes
255 heads, 63 sectors/track, 195 cylinders, total 3137536 sectors
Units sectors of 1 *512=512 bytes
Sector size (logicaL/physicaL): 512 bytes /512 bytes
1/0 size (minimum/optimal): 512 bytes /512 bytes
Disk identifier: 0xG0000000
Disk /dev/mapper/i--2--22266--VM-swap 1 doesn't contain a valid partition table
01skdy/5db;32.2B.3221225412 bytes
255 heads, 63 sectors/t
3916 cylinders, total 62914560 sectors
1/0 size (minimum/optimal): 512 bytes /512 bytes
Disk identifier: OxC0600000
Disk /dev/sdb doesn't contain a valid partition table
rootei-2-22266-VM: -#t fdisk /dev/sdb
60
H ChenLong-root
266-VM
h-141×41
tors of 1* 512=512 bytes
Sector size (logical/physical): 512 bytes /512 bytes
/0 size (minimum/optimal): 512 bytes /512 bytes
Disk ident ifier: 0x0e000090
Disk /dev/sdb doesn't contain a valid partition table
roote1-2-22266-VM: -#t fdisk /dev/sdb
Device contains neither a valid dos partition table, nor Sun, SGI or osf disklabel
Building a new Dos disklabel with disk identifier exelld1f05
Changes will remain in memory only, until you decide to write them
After that, of course, the previous content won't be recoverable
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Command (m for help): n
Partition type
primary (0 primary, 0 extended, 4 free)
select (default
Partition number (1-4, default 1):1
在这里创建20GB作为第一个分区
First sector (2048-62914559, default 2048)
Using default value 2048
Last sector, +sectors or +size K, M, G)(2048-62914559, default 62914559):+20G
Command (m for help):n
Partition type
p primary (1 pr imary. 0 extended, 3 free)
e extended
把剩下的空间作为第二个分区
Partition
4. default 2):2
First sector【41945688-62914559, default41945988)
Last sector, +sectors or tsize(K, M, G)(41945088-62914559. default 62914559)
Using default value 62914559
Command( m for help):w保存磁盘分区表
The partition table has been altered
Calling ioctl) to re-read partition table
ng dis
root1-2-22266-VM: /var/wWw* ls /dev/sdb*
/dev/sdb /dev/sdb /dev/sdb2
rooti-2-22266-VM: /var/www#f mkfs ext3 /dev/sdb1
mke2fs1.42(29-Nov-2011)
Filesystem label=
os type: L
nUX
Block size=4096 (log=2)
ragment size=4096 (log=2)
Stride=o blocks, Stripe width=0 blocks
1310720 inodes. 5242880 blocks
262144 blocks (5. 00%) reserved for the super user
First data block=D
Maximum filesystem blocks=4294967296
160 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backu
32768,98304,163840,229376,294912,81926,884736,1605632,2654268
4⊙96866
Allocate
oup tables: done
writing inode tables: done
Creating journal (32768 blocks)
done
Writing superblocks and filesystem accounting information: done
root1-2-22266-VM: /var/WwW#
root1-2-22266-VM: /mnt#f mount /dev/sdb2/var/WwW
rooti-2-22266-VM: /mnt# df -h
Filesystem
Size Used Avail Use% Mounted on
/dev/ mapper/1-2-2226--WM-root4963.7G4369%
udev
489M12K489M1%/dev
tmpfs
200M868K199M1%/run
none
5.6F
⊙5.6M6%/run/Lock
none
498M
0 498M 0%/run/shm
cgroup
498M
0 498M 0%/sys/fs/cgroup
/dev/sal
228M73M144M34%/boot
/dev/sdb
9.9G151M9.2G2%/mnt
/dev/sdb
9. 9G 151M 9.2G 2%/var/wWW
rootei-2-22266-VM:/mnt#
金 ChenLong-root-2-2266-WM:/et-5h-141×41
/etc/fstab: static file system information
Use blkid to print the universally unique identifier for a
device: this may be used with UUID= as a more robust way to name devices
that works even if disks are added and removed. See fstab(5)
proc
/proc
proc node, noexec, nosuid o
/dev/mapper/1--2--22266--VM-root
ext4
errors=remount-ro e
W/boot was on /dev/sdal dur ing installation
UUID=8b7c09ac-C05a-4712-a981-06a8ea159962/boot
ext2 defaults
dev/mapper/i--2--22266--VM-swap 1 none
dev/fdo
/media/floppy auto rw, user, noauto, exec, utf8 0
/dev/sdb2
/var/wwW
ext3 defaults
root1-2-22266-VM: /etc df -h
Filesystem
Size Used avail Use% Mounted on
/dev/mapper/1--2--22266--VM-root 49G 3.7G 43G 9%/
udev
489M12K489M1%/dev
tmpfs
2N868K199M1%/run
none
5.oM0 5 oM 0%/run/lock
ne
non
498M
0 498M 0%/run/shm
cgroup
498M
0 498M 0%/sys/fs/cgroup
/dev/sda1
228N73M144M34%/boot
root1-2-22266-VM: /etc# mount
root1-2-22266-VM: /etc# df -h
Filesystem
Size Used Avail Use% Mounted on
/dev/mapper/1--2--22266--VM-root 49G 3.7G 43G 9%
udev
489M12K489M1%/dev
tmpfs
2⊙0M868K199M1%/run
none
5.N5.M⊙%/run/lock
none
498M0 498M 0%/run/shm
cgroup
498M
0 498M 0%/sys/fs/cgroup
/dev/sda1
228M73M144N34%/boot
/dev/sdb
9. 9G 151M 9.2G 2%/var/wWw
root1-2-22266-VM: /etc#
ChenLong-rooi-465-26159-WM~-55h-118×24
8192 inodes per group
Superblock backups stored on blocks
32768,98304,163849,229376,294912,819200,884736,1605632,2654208,
4996900
writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 32 mounts or
180 days, whichever comes f
Use tune2fs -c or -1 to override
M l# vi
root1-465-26159VN~]#15/dev/
Display all 183 possibilities? (y or n)
[roote1-465-26159-VM -] ls /dev/disk/by-uuid/
58b95baa-68f9-49da-97dc-3b29cfc8114ce4480b42-2b26-4dfe-b974-7c7ee789024c
a18c5fce-Baf5-4d23-aea7-08cb678clcd3 e8c9e4c5-ff91-4f84-9e7e-66eded3dac15
[rootel-465-26159-VM - ls /dev/disk/by-uuid/-l
total o
L rwxrwxrwx 1 root root 10 Jul 24 14: 30 58b95baa-08f9-49da-97dc-3b20cfc8114c ->././sda1
L rwxrwxrwx 1 root root 10 Jul 24 14: 30 a18c5fce-8af5-4d23-aea7-08cb678c1cd3-
wXrwXrwX
18018121
e4489b42-2b26
b974-7c7ce789624c
sdb
rwx rwx rwX
root1-465-26159-VM-]#
ChenLong-roti-465-26159WM:~-55h-118×24
/etc/fstab
#f Created by anaconda on Tue Jul 9 18: 31: 46 2013
Accessible filesystems, by reference, are maintained under'/dev/disk
See man pages fstab(5), finds(8), mount(8) and/or blkid(8) for more info
/dev/mapper/VolGroup-lv root
t4 defaults
UUID=58b95baa-08f9-49da-97dc-3b20cfc8114c/boot
ext4 default
12
/dev/mapper/Vo1Group-lv swap swap
swap defaults
tmpfs
tmpfs defaults
devpts gid=5, mode=620 0 0
sysfs
/sys
sysfs defaults
⊙0
UUID=e4480b42-2b26-4dfe-b974-7c70e789024c /mnt ext4 defaults
(系统自动生成,下载前可以参看下载内容)
下载文件列表
相关说明
- 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
- 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度。
- 本站已设置防盗链,请勿用迅雷、QQ旋风等多线程下载软件下载资源,下载后用WinRAR最新版进行解压.
- 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
- 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
- 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.