1

Today I purchased a ubuntu server where 2 SSD (500GB each). In server information following information was written.

SSD 500 x 2
RAID 1 (Software RAID)

Now I wanna setup a storage file server.

I am confused how 2 SSD will works since I never use dual SSD server previously.

  1. In which SSD Ubuntu Server Installed?
  2. If all store all files in /srv folder do I need to do anything?
  3. Did all ssd is counted as single storage?
  4. How will the storage file will used?

For SSD information I tested the following command. If I run following command I get following result:

$ sudo lshw -C disk
  *-disk
       description: ATA Disk
       product: WDC  WDS500G2B0A
       vendor: Western Digital
       physical id: 0.0.0
       bus info: scsi@2:0.0.0
       logical name: /dev/sda
       version: 40WD
       serial: 200511800205
       size: 465GiB (500GB)
       capabilities: gpt-1.00 partitioned partitioned:gpt
       configuration: ansiversion=5 guid=f2e52d4d-f48f-4434-9c6d-e4c7002c4fdb logicalsectorsize=512 sectorsize=512
  *-disk
       description: ATA Disk
       product: WDC  WDS500G2B0A
       vendor: Western Digital
       physical id: 0.0.0
       bus info: scsi@3:0.0.0
       logical name: /dev/sdb
       version: 40WD
       serial: 200422801375
       size: 465GiB (500GB)
       capabilities: gpt-1.00 partitioned partitioned:gpt
       configuration: ansiversion=5 guid=6e2607b0-cf37-449c-af96-0acac4359885 logicalsectorsize=512 sectorsize=512

If I run following command I get following result:

$ lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT,LABEL
NAME        FSTYPE              SIZE MOUNTPOINT        LABEL
loop0       squashfs           32.3M /snap/snapd/12704
loop1       squashfs           55.4M /snap/core18/2128
loop2       squashfs           70.3M /snap/lxd/21029
loop3       squashfs           32.3M /snap/snapd/12883
loop4       squashfs           61.8M /snap/core20/1081
loop5       squashfs           67.3M /snap/lxd/21545
sda                           465.8G
├─sda1                            1M
├─sda2      linux_raid_member     1G                   ubuntu-server:0
│ └─md0     ext4               1022M /boot
├─sda3      linux_raid_member    16G                   ubuntu-server:1
│ └─md1     swap                 16G [SWAP]
└─sda4      linux_raid_member 448.8G                   ubuntu-server:2
  └─md2                       448.6G
    └─md2p1 ext4              448.6G /
sdb                           465.8G
├─sdb1                            1M
├─sdb2      linux_raid_member     1G                   ubuntu-server:0
│ └─md0     ext4               1022M /boot
├─sdb3      linux_raid_member    16G                   ubuntu-server:1
│ └─md1     swap                 16G [SWAP]
└─sdb4      linux_raid_member 448.8G                   ubuntu-server:2
  └─md2                       448.6G
    └─md2p1 ext4              448.6G /

Also

$ df /
Filesystem     1K-blocks    Used Available Use% Mounted on
/dev/md2p1     461987712 6716124 431734132   2% /

$ df /boot
Filesystem     1K-blocks   Used Available Use% Mounted on
/dev/md0         1013688 108580    836400  12% /boot
1
  • I recommend to use df -h instead of df
    – france1
    Sep 20 at 14:57
5

Welcome to the fun world of server management!

Because you've set your system up as a RAID1, and because you've provided all of the details that are needed to answer your questions, let's get right to the questions:

In which SSD Ubuntu Server Installed?

Both. You've set your system up with a RAID1 mirroring pattern, so 100% of the bytes for each file will be on each SSD.

If all store all files in /srv folder do I need to do anything?

You will need to make sure that the accounts accessing that directory have the appropriate permissions.

Did all ssd is counted as single storage?

Yes. The output of lsblk shows you have about 448GB mounted at /, which confirms that the two SSDs are being used as a mirror.

How will the storage file will used?

The files will appear the same way as they would if you had a single SSD in the system. You don't need to do any special thinking when working with files stored on a RAID partition beyond the question of backups. While RAID1 will allow the system to continue if one device fails, it's always good to have a backup of the critical files just in case.

4
  • Why following command only shows 441G available? ` df -hBG / Filesystem 1G-blocks Used Available Use% Mounted on /dev/md2p1 441G 8G 411G 2% / ` Sep 20 at 13:31
  • 1
    A brain-freeze on my part. RAID1 is a mirror, which means that both SSDs will contain the same data. If one SSD fails, the other can continue while the other is replaced. 411GB available is correct. If you would like a great deal more, then you'll need to use RAID0 or -- perhaps ideally -- an LVM pool.
    – matigo
    Sep 20 at 13:41
  • Thanks. I accepted your answer. :) So, If want to add an 1 TB HDD for more storage, Am I need to use two 1TB HDD since current config is RAID 1? Sep 20 at 13:47
  • 1
    If you plan to add a 1TB HDD, then you can use a single disk and mount it. You do not need to use RAID unless you specifically want to mirror or stripe data across multiple devices.
    – matigo
    Sep 20 at 13:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.