Ubuntu – How to determine device name for NMVe SSDs during install

16.04dmraidmdadmraid

I'm in the beginning of installing 16.04 Ubuntu flavor to rig. I'll use two NMVe SSDs in a RAID0 config. I have all of the commands lined up, I just miss one crucial bit: the actual device name of the SSDs. The install DVD is mounted as /dev/sda1, but I don't see any other /dev/sd* device besides a in /dev.

I'm an oldschool Linux guy, and I know that /dev filesystem has changed multiple times over the years. How do I figure out the device names?

One extra info about my machine is that it has an SLI GPU configuration, which takes up the PCIe lines from the shipset AFAIK (that's why plain GT80 doesn't have NMVe M.2s AFAIK), so it can very well happen that MSI might have used an extra chipset in the GT80S Titan series to provide PCIe lines (?). I'm not sure if that affects the device names, the NMVe drives for sure are not on the SATAIII controllers.

The RAID volume is configured and assembled in the BIOS. I could successfully install Win10 in 20 mins, so they function fine. During Ubuntu install I turn off the Secure mode and set UEFI with CSM.


sda here is a thumb drive:

root@ubuntu-studio:~# lsblk
NAME   MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda      8:0    1  1.9G  0 disk 
└─sda1   8:1    1  1.9G  0 part /media/ubuntu-studio/D43E-C473
sr0     11:0    1  2.6G  0 rom  /cdrom
loop0    7:0    0  2.5G  1 loop /rofs

The RAID controller is there. Is it a problem that it is listed as AHCI?

root@ubuntu-studio:~# lspci -nnk
00:00.0 Host bridge [0600]: Intel Corporation Sky Lake Host Bridge/DRAM Registers [8086:1910] (rev 07)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Skylake Host Bridge/DRAM Registers [1462:1171]
00:01.0 PCI bridge [0604]: Intel Corporation Sky Lake PCIe Controller (x16) [8086:1901] (rev 07)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:01.1 PCI bridge [0604]: Intel Corporation Sky Lake PCIe Controller (x8) [8086:1905] (rev 07)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:08.0 System peripheral [0880]: Intel Corporation Sky Lake Gaussian Mixture Model [8086:1911]
    Subsystem: Micro-Star International Co., Ltd. [MSI] Skylake Gaussian Mixture Model [1462:1171]
00:14.0 USB controller [0c03]: Intel Corporation Sunrise Point-H USB 3.0 xHCI Controller [8086:a12f] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H USB 3.0 xHCI Controller [1462:1171]
    Kernel driver in use: xhci_hcd
00:14.2 Signal processing controller [1180]: Intel Corporation Sunrise Point-H Thermal subsystem [8086:a131] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H Thermal subsystem [1462:1171]
00:16.0 Communication controller [0780]: Intel Corporation Sunrise Point-H CSME HECI #1 [8086:a13a] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H CSME HECI [1462:1171]
    Kernel driver in use: mei_me
    Kernel modules: mei_me
00:17.0 RAID bus controller [0104]: Intel Corporation SATA Controller [RAID mode] [8086:2822] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] SATA Controller [RAID mode] [1462:1171]
    Kernel driver in use: ahci
    Kernel modules: ahci
00:1c.0 PCI bridge [0604]: Intel Corporation Sunrise Point-H PCI Express Root Port #1 [8086:a110] (rev f1)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:1c.1 PCI bridge [0604]: Intel Corporation Sunrise Point-H PCI Express Root Port #2 [8086:a111] (rev f1)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:1c.2 PCI bridge [0604]: Intel Corporation Sunrise Point-H PCI Express Root Port #3 [8086:a112] (rev f1)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:1c.3 PCI bridge [0604]: Intel Corporation Sunrise Point-H PCI Express Root Port #4 [8086:a113] (rev f1)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:1c.4 PCI bridge [0604]: Intel Corporation Sunrise Point-H PCI Express Root Port #5 [8086:a114] (rev f1)
    Kernel driver in use: pcieport
    Kernel modules: shpchp
00:1f.0 ISA bridge [0601]: Intel Corporation Sunrise Point-H LPC Controller [8086:a150] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H LPC Controller [1462:1171]
00:1f.2 Memory controller [0580]: Intel Corporation Sunrise Point-H PMC [8086:a121] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H PMC [1462:1171]
00:1f.3 Audio device [0403]: Intel Corporation Sunrise Point-H HD Audio [8086:a170] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H HD Audio [1462:1171]
    Kernel driver in use: snd_hda_intel
    Kernel modules: snd_hda_intel
00:1f.4 SMBus [0c05]: Intel Corporation Sunrise Point-H SMBus [8086:a123] (rev 31)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Sunrise Point-H SMBus [1462:1171]
    Kernel modules: i2c_i801
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GM204M [GeForce GTX 970M] [10de:13d8] (rev a1)
    Subsystem: Micro-Star International Co., Ltd. [MSI] GM204M [GeForce GTX 970M] [1462:1171]
    Kernel modules: nvidiafb, nouveau
01:00.1 Audio device [0403]: NVIDIA Corporation GM204 High Definition Audio Controller [10de:0fbb] (rev a1)
    Subsystem: Micro-Star International Co., Ltd. [MSI] GM204 High Definition Audio Controller [1462:1171]
    Kernel driver in use: snd_hda_intel
    Kernel modules: snd_hda_intel
02:00.0 3D controller [0302]: NVIDIA Corporation GM204M [GeForce GTX 970M] [10de:13d8] (rev a1)
    Subsystem: Micro-Star International Co., Ltd. [MSI] GM204M [GeForce GTX 970M] [1462:1171]
    Kernel modules: nvidiafb, nouveau
04:00.0 Network controller [0280]: Qualcomm Atheros QCA6174 802.11ac Wireless Network Adapter [168c:003e] (rev 32)
    Subsystem: Bigfoot Networks, Inc. QCA6174 802.11ac Wireless Network Adapter [1a56:1535]
    Kernel driver in use: ath10k_pci
    Kernel modules: ath10k_pci
05:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS5249 PCI Express Card Reader [10ec:5249] (rev 01)
    Subsystem: Micro-Star International Co., Ltd. [MSI] RTS5249 PCI Express Card Reader [1462:1171]
    Kernel driver in use: rtsx_pci
    Kernel modules: rtsx_pci
06:00.0 Ethernet controller [0200]: Qualcomm Atheros Killer E2400 Gigabit Ethernet Controller [1969:e0a1] (rev 10)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Killer E2400 Gigabit Ethernet Controller [1462:1171]
    Kernel driver in use: alx
    Kernel modules: alx

I tried dmraid too:

~# dmraid -r *
no block devices found

Best Answer

The key to the solution was to switch the controller in the BIOS from RAID mode to AHCI. After that Linux saw the devices (/dev/nvme0p0, /dev/nvme1p0).

NVMe drives can be driven in many different ways: see 1st figure in https://en.wikipedia.org/wiki/M.2. I still need to try how nvme_load=YES boot option influences the situation, since the involvement of AHCI supposedly won't provide optimal performance.

The most help I got from:

  1. https://superuser.com/questions/1022849/m-2-samsung-sm951-nvme-ssd-not-recognized-on-linux
  2. http://www.dell.com/support/article/us/en/19/SLN299303/pt
  3. https://docs.google.com/document/d/16d0zsdNJ48A7HVA1VfGlMORxA6BudN0d-lLQN1vA1E4/edit

I ended up with Ubuntu Studio 16.04, and I implemented the RAID with btrfs. That proved to get through the last parts of the installation. Intel RST would be a soft RAID after all too, and btrfs's performance supposed to be good. fstrim for 1 TB can last 24 hours is another experience


Weekly fstrim still takes a long time (often 30-60 minutes or more) Monday mornings...

Related Question