Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I need to mount my secound ssd drive to /home2. I already created the folder /home2 - Now, how can i figure out which is the unused drive ? Is this /dev/sda or sdb ?

What is the exactly thing i`ve to look for to know which is the unmounted drive ?

[/]# cat /proc/mdstat
Personalities : [raid1]
md1 : active raid1 sdb2[1] sda2[0]
      524224 blocks super 1.0 [2/2] [UU]

md0 : active raid1 sdb1[1] sda1[0]
      16777088 blocks super 1.0 [2/2] [UU]

md2 : active raid1 sdb3[1] sda3[0]
      217125312 blocks super 1.0 [2/2] [UU]

unused devices: <none>

df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/md2        204G   84G  111G  44% /
tmpfs            16G     0   16G   0% /dev/shm
/dev/md1        496M   53M  419M  12% /boot
/usr/tmpDSK     1.9G   94M  1.7G   6% /tmp

root@kas [~]# fdisk -l | grep '^Disk'
Disk /dev/sdb: 240.1 GB, 240057409536 bytes
Disk identifier: 0x0007b22f
Disk /dev/sda: 240.1 GB, 240057409536 bytes
Disk identifier: 0x000c0cf1
Disk /dev/md2: 222.3 GB, 222336319488 bytes
Disk identifier: 0x00000000
Disk /dev/md0: 17.2 GB, 17179738112 bytes
Disk identifier: 0x00000000
Disk /dev/md1: 536 MB, 536805376 bytes
Disk identifier: 0x00000000
root@kas [~]# fdisk -l

Disk /dev/sdb: 240.1 GB, 240057409536 bytes
255 heads, 63 sectors/track, 29185 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0007b22f

Device Boot Start End Blocks Id System
/dev/sdb1 1 2089 16777216+ fd Linux raid autodetect
/dev/sdb2 2089 2155 524288+ fd Linux raid autodetect
/dev/sdb3 2155 29186 217125464+ fd Linux raid autodetect

Disk /dev/sda: 240.1 GB, 240057409536 bytes
255 heads, 63 sectors/track, 29185 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000c0cf1

Device Boot Start End Blocks Id System
/dev/sda1 1 2089 16777216+ fd Linux raid autodetect
/dev/sda2 2089 2155 524288+ fd Linux raid autodetect
/dev/sda3 2155 29186 217125464+ fd Linux raid autodetect

Disk /dev/md2: 222.3 GB, 222336319488 bytes
2 heads, 4 sectors/track, 54281328 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/md0: 17.2 GB, 17179738112 bytes
2 heads, 4 sectors/track, 4194272 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/md1: 536 MB, 536805376 bytes
2 heads, 4 sectors/track, 131056 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
share|improve this question

migrated from serverfault.com Mar 25 at 0:42

This question came from our site for system and network administrators.

    
We'd have to see the output from cat /proc/mdstat to be sure (please, paste it into your question, don't add it as a comment), but given the presence of three metadevices, it looks to me like you're already using both SSDs. –  MadHatter Mar 24 at 8:20
    
thanks for your answer, i did :) –  user3086396 Mar 24 at 8:23

3 Answers 3

up vote 3 down vote accepted

Both SSDs are already fully committed to your three RAID-1 partitions. You don't have any free space on either of them.

Edit: yes, that is what I am saying. The df output shows you that /dev/md[12] are mounted (I'm guessing /dev/md0 is swap; /cat /proc/swaps will confirm that). cat /proc/mdstat then tells you that /dev/mdN is a RAID-1 made up of /dev/sdaN+1 and /dev/sdbN+1, for N=0,1,2.

The fdisk output confirms this by showing us that each disc is completely filled by three RAID-autodetect partitions.

share|improve this answer
    
well, so you`re saying i dont have any free space on my secound ssd ? Why does the filesystem show me not the secound ssd with df -h ? –  user3086396 Mar 24 at 8:35
    
See my edit above. By the way, local etiquette is that when you're satisfied with an answer to your question, you accept it by clicking on the tick outline next to it. This drives the SF reputation system both for you and the author of that answer, and it prevents the question from floating up to the top of the stack forever after. My apologies if you already know this; but if you didn't, you might want to look at accepting an answer to your other, older, question, as well. –  MadHatter Mar 24 at 9:15

The df command will tell you which drives are mounted where.

share|improve this answer
    
I already did, this was the output df -h Filesystem Size Used Avail Use% Mounted on /dev/md2 204G 84G 111G 44% / tmpfs 16G 0 16G 0% /dev/shm /dev/md1 496M 53M 419M 12% /boot /usr/tmpDSK 1.9G 94M 1.7G 6% /tmp –  user3086396 Mar 24 at 8:10

I have found the need to identify individual disks in my raid arrays also and used "sudo smartctl -a /dev/sd?" to find out the serial numbers of identical disks.

You currently don't have either sda or sdb unmounted as noted by your cat /proc/mdstat showing [2/2] [UU] for all devices.

If you wanted to use one of these disks for /home2 it is likely you want to trash your RAID array - is this correct ?

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.