- 论坛徽章:
- 0
|
有个问题想请问各位高手,你们有没有把两个同样的硬盘挂在相同的目录下面.
我试过,两个相同的硬盘挂在同一个目录下面只可以显示同一个硬盘,.
例如:"我们现在有两个40的硬盘:我们现在都mount 到根目录下面的home这个子目录下面去.:
首先我们是要先进行挂载: fdisk -l 看看这两个硬盘有没有被系统认出来:
Disk /dev/hda: 41.1 GB, 41110142976 bytes
255 heads, 63 sectors/track, 4998 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 19 152586 83 Linux
/dev/hda2 20 150 1052257+ 82 Linux swap
/dev/hda3 151 4998 38941560 83 Linux
Disk /dev/hdc: 41.1 GB, 41110142976 bytes
16 heads, 63 sectors/track, 79656 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Device Boot Start End Blocks Id System
/dev/hdc1 1 77506 39062992+ 83 Linux
Disk /dev/hdd: 41.1 GB, 41110142976 bytes
255 heads, 63 sectors/track, 4998 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdd2 2 4865 39070080 83 Linux
电脑已经认识出来这个 两硬盘了,分别是 hdc 和hdd
这个时候我们先把这两个硬盘进行分区..
首先进入到第一个硬盘hdc1
fdisk /dev/hdc
m一下是看帮助,
然后我们输入N 新建立一个分区,这个时候有两种选择一种是主分区,一种是逻辑分区,这里我们选择P
Command (m for help): m
Command action
a toggle a bootable flag
b edit bsd disklabel
c toggle the dos compatibility flag
d delete a partition
l list known partition types
m print this menu
n add a new partition
o create a new empty DOS partition table
p print the partition table
q quit without saving changes
s create a new empty Sun disklabel
t change a partition's system id
u change display/entry units
v verify the partition table
w write table to disk and exit
x extra functionality (experts only)
Command (m for help): n
Command action
e extended
p primary partition (1-4)
P
Partition number (1-4):
后面的分区我想大家都比我清楚多了,这个我就不用说了.
现在我们想把这两个硬盘同时挂载到home这个目录下面去.
我使用了这个命令: mount /dev/hdc1 /home
mount/dev/hdc2/home
我使用df -h看的时候只可以看到一个40G的硬盘挂在上面.
[root@ceshi /]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hda3 37G 2.8G 32G 8% /
/dev/hda1 145M 8.5M 129M 7% /boot
none 347M 0 347M 0% /dev/shm
/dev/hdc1 37G 23G 13G 66% /home
我不知道是为什么.但是挂都别的目录就可以了,难道是因为一个目录只可以挂一个硬盘吗?如果有人可以在一个目录下面挂两个硬盘请告诉我一下,谢谢.第一次发表帖子,希望大家多多照顾以下 |
|