[HOW TO] Arch Linux on NUC6i5SY - NVMe and Bridged Interfaces

This is for those:

  • Who already have NUC particularly NUC6i5SY series
  • Uses a music server (SOtM sMS-200 or uRendu)
  • Installed NVMe M.2 memory
  • Have access to music files from NAS or equivalent fileserver through SMB
  • Set Roon Server close to the music server using network bridge set-up to minimize cabling
  • Patiently waiting for ROCK and have nothing else to do. This is like the closest thing.

Thanks to @evand on this guide here. Evand’s post forms the base of this guide. I decided to create another one to cater more specifically to NUC6i5SY owners who are patiently waiting for ROCK.

Arch Linux is a minimal install and probably the lightest OS that will run Roon server. The tradeoff in using Arch Linux is it is not the most user friendy among the Linux distributions and tried a lot of them plus Solaris derivatives.

The set-up is primarily on NUC’s that uses NVMe memory, access to music files through SMB, no bootloader for faster boot time, and bridged interfaces with an endpoint (e.g. SOtM sMS-200 or uRendu). It turns out that efibootmgr is not as friendly on NVMe’s when direct booting to the OS through UEFI so that led me to modify the original guide.

The bridge set-up was added to allow setting up the Roon Server closer to the endpoint. In my case, I was able reduce the length of my ethernet cable from 13 meters down to less than a meter while eliminating any router or switches that goes in between the Roon server and the endpoint in the previous set-up. I didn’t expect to gain huge improvement with this new set-up but, to my surprise, there is.

For bridge set-up, you’ll need a USB Ethernet Adapter for the 2nd ethernet port. I purchased the Pluggable USB 3.0 Ethernet Adapter that uses the ASIX AX88179 controller chip for $14.75. You can find it here. Secret: This chip is currently supported in ROCK :slight_smile:. The USB Ethernet Adapter will be connected to the home LAN while the built-in Intel ethernet port in NUC will go to the music player.

Prepare source flash drive

For Linux:

Download the Arch Linux ISO file and write it to a flash drive as follows (where sdY represents the flash drive):

# wipefs --all /dev/sdY
# dd bs=4M if=/path/to/archlinux.iso of=/dev/sdY && sync

For Windows:

Download Rufus. Create a bootable USB drive using Arch Linux ISO image that can be downloaded from here. Use “GPT partition scheme for UEFI” and “Large FAT32”

Configure BIOS and boot from source flash drive:

  • Turn off compatibility mode and secure boot in the UEFI BIOS, connect network cable
  • Check UEFI Boot
  • You can keep Legacy Boot checked
  • Uncheck Audio if using a music server, WLAN, and Bluetooth under Onboard Devices to minimize any unnecessary electrical noise
  • Disabled “USB S4/S5 Power” under Secondary Power settings
  • Disabled “Portable Device Charging Mode” under Devices and USB
  • Check USB as Boot Device in Boot Configuration

Boot target machine from flash drive you’ve just prepared.

Partition target flash drive

After the boot sequence is completed insert the target flash drive on which you wish to install Arch Linux and determine its device name:

# lsblk

Partition the target flash drive with 512MB partition of type ef00 and the remainder as a regular Linux partition using gdisk:

# gdisk /dev/nvme0n1

Wipe out the existing partitions on the target flash drive. Use expert mode (press x) and zap the gpt tables, mbr etc. (press z). Then relaunch gdisk as above.

Once in gdisk press n and follow the prompts to size the partition table and set its type: +512MB and ef00 respectively. When done with the first partition press n again and create a second (Linux) partition utilizing the remaining space on the flash drive. When done press w and confirm writing of the partition tables.

Here’s the partition creating process for the 1st Partition:

Partition Number: 1
First Sector: 2048 (default)
Last Sector: +512MB
Hex Code or GUID: ef00

…type n

For the 2nd Partition:

Partition Number: 2
First Sector: (default)
Last Sector: (default)
Hex Code or GUID: 8300

…type w

Format partitions on target flash drive

Format the partitions FAT32 and EXT4 respectively:

# sync
# mkfs.fat -F32 /dev/nvme0n1p1
# mkfs.ext4 /dev/nvme0n1p2

Mount the Linux partition to /mnt and EFI System Partition to /mnt/boot:

# mount /dev/nvme0n1p2 /mnt
# mkdir /mnt/boot
# mount /dev/nvme0n1p1 /mnt/boot

Install Arch Linux Base System

Install the base system, generate an fstab (note the use of -U to utilize UUIDs for device identification) and load temp files to ram:

# pacstrap /mnt base

(Wait until it Is finished. This may take a long time. The screen may go blank due to the screen saver. Pressing to activate the screen again is safe.)

Set-Up FSTAB

# genfstab -U -p /mnt >> /mnt/etc/fstab
# nano /mnt/etc/fstab

Add the following to fstab to minimize unnecessary writes to the flash drive:

tmpfs	/var/log       tmpfs	defaults	0 0                 
tmpfs	/var/tmp       tmpfs	defaults	0 0
tmpfs	/tmp           tmpfs	defaults	0 0

Chroot into and configure the base system

Change myhostname below to whatever you’d like your RoonBridge to be identified as on your network e.g. nucroonserver

# arch-chroot /mnt /bin/bash
# hwclock --systohc --utc
# echo myhostname > /etc/hostname

Add the same hostname to /etc/hosts:

# nano /etc/hosts

Edit the file to place it in the correct location so the line looks as follows:

127.0.0.1 localhost.localdomain localhost myhostname
::1 localhost.localdomain localhost myhostname

Locale and Local Time

Set locale by uncommenting the locale you wish to use, save the file and activate the locale. For example:

# nano /etc/locale.gen

Remove the hash “#” mark before your locale, e.g. en_US.UTF-8 UTF-8

# echo LANG=en_US.UTF-8 > /etc/locale.conf
# locale-gen

Create a symbolic link /etc/localtime to your subzone file /usr/share/zoneinfo/Zone/SubZone using this command as an example:

# rm /etc/localtime
# ln -s /usr/share/zoneinfo/America/Los_Angeles /etc/localtime

Bridge Interface Configuration

Copy a sample profile from /etc/netctl/examples to /etc/netctl and modifying it by changing eth0 to the ethernet port shown by ip l. It is typically going to be something along like eno1 and enp0s20f0u3:

# ip l
# cd /etc/netctl
# cp examples/bridge my_bridge
# nano /etc/netctl/my_bridge

My set-up looks very similar to this:

Description="Bridge Connection"
Interface=br0
Connection=bridge
BindsToInterfaces=(enp0s20f0u3 eno1)
IP=static
Address=('192.168.1.100/24')
Gateway=('192.168.1.1')
DNS=('8.8.8.8' '8.8.4.4')
MACAddressOf=enp0s20f0u3
SkipNoCarrier=yes

Enable to bridge to run it permanently every reboot:
# netctl enable my_bridge

Set the root password and other essentials
# passwd

Install intel-ucode [basically intel microcode updates]:
# pacman -S intel-ucode openssh mc ffmpeg samba

Optional….If you run across mirror errors:

# nano /etc/pacman.d/mirrorlist

Delete or add a hash "#" before the mirror creating the problem.  I'm having problem on arch.nimukaito.net in my case.

Enable root login via ssh:
# cd /etc/ssh/
# cp sshd_config sshd_config.org
# nano sshd_config

Find the following line in /etc/ssh/sshd_config:
PermitRootLogin prohibit-password

Remove the # and change prohibit-password to yes
PermitRootLogin yes

Enable sshd:
# systemctl enable sshd.service

Setup to have BIOS boot the OS directly (This may be set-up already. Just left it here in case it is needed.)

# mount -t efivarfs efivarfs /sys/firmware/efi/efivars
# bootctl --path=/mnt/boot install

Determine device UUIDs and create a configuration file to add an entry for Arch Linux to the boot manager:

# blkid >> /boot/loader/entries/arch.conf
# nano /boot/loader/entries/arch.conf

Remove UUID entries other than that pertaining to the flash drive and add the following (using your device UUID):

title	Arch Linux
linux	/vmlinuz-linux
initrd	/initramfs-linux.img
options	root=UUID=Insert_Linux_Partition_UUID_Here rw

Note on the above: Use the UUID from nvme0n1p2

Flush cache and exit chroot session:
# sync && exit

Set-Up SMB Access to Music Files

It is assumed that your music files are already stored somewhere in SMB NAS.

Add the following to fstab access your music files and Roon database backup from the fileserver (SMB):

# nano /etc/fstab

//192.168.1.xx/music             /mnt/music              cifs    guest,sec=ntlm  0 0
//192.168.1.xx/roon_music        /mnt/roon_music         cifs    guest,sec=ntlm  0 0
//192.168.1.xx/media-backup      /mnt/media-backup       cifs    guest,sec=ntlm  0 0

192.168.1.xx = your SMB server

I used “music” for music files I originally organized using Mp3tag. “roon_music” can be any unorganized files you can dump for Roon to organize. Media-backup is where to backup the Roon database.

Reboot just to make sure you’ll get the Arch Linux login screen

# reboot

(At this point, you can use putty to access Roon Server remotely from your desktop.)

Install Roon Server

# curl -O http://download.roonlabs.com/builds/roonserver-installer-linuxx64.sh
# chmod +x roonserver-installer-linuxx64.sh
# ./roonserver-installer-linuxx64.sh

Access the site through Roon Remote. In case the music server is not visible when accessed through your browser, reboot it.

2 Likes

This is brilliant. I wish I saw this a couple days ago. It took me half a day to get this working https://community.roonlabs.com/t/roonserver-nuc-using-ubuntu-server/24969

I’m particularly interested in trying the bridged route. I’ve been following the Computer Audiophile thread for some time. I have my NUC currently connected to the same ethernet switch that my NAS is connected to in my office upstairs. I am using a Linksys Velop mesh system for wireless duties. I have one Velop hub connected to my switch in the office and the other downstairs, with direct connection to my sMS-200. This setup, even before when my NAS played Roon Server duty, works perfectly. Even upsampled max PCM files stream flawlessly over my mesh Wi-Fi setup. I don’t want to move my noisy NAS downstairs, but I might move the NUC closer to my sMS-200 to see if the bridged set-up improves my already great sounding system. I wonder though…will a bridged setup from NUC to sMS-200 (still accessing files from NAS over Wi-Fi) be better, worse or negligible to my existing setup with NUC and NAS connected to the same switch upstairs? I guess the question is…theoretically, will it sound “better” having NUC closer to the media or the NUC closer to the endpoint??
PS. I just ordered the tx-USBultra to brigde the gap between the sMS-200 and my 2Qute DAC.

I think you probably want the NUC (and the NAS) farther from the endpoint (I’m assuming we’re not talking really far), mostly just to eliminate any acoustic noise from those two items in the listening area and also to get the relatively electrically noisy NUC away from the audio gear. Mostly, though, just getting an Ethernet run between the NUC and your audio-optimized endpoint plus DAC is what should yield any improvement in SQ.

I’m curious to know how much difference the tx-USBultra makes once you have the sMS-200 in the chain. I’d theorize that maybe that money is better spent on a good power supply for the sMS-200 (?).

Glad to hear you’re liking the Velops. A three-pack of those is on my Amazon wish list, slated for near-term purchase.

I had Airport Extreme and Express which served me well for a long time, then tried the Netgear Orbi to eliminate dead zones, but settled on the Linksys Velop in the end. I’ve been very happy with the speed throughout the house.

I have a pretty good power supply, Wyred 4 Sound’s PS-1. I have two module installed, one that powers my 2Qute and the other powers my sMS-200. I just ordered a third module which will power the tx-USBultra. This is what sold me on giving the tx-USBultra a try: http://www.audiostream.com/content/sotm-tx-usbultra-usb-signal-regenerator.

1 Like

I’d forgotten you were all set up with a good power supply, and that’s an amazingly positive review of the tx-USBultra. Please post your impressions when you’ve had a chance to listen.

You don’t happen to have Mac instructions? :confused:

I might hit you up with a few questions, hope you don’t mind. I installed Ubuntu Server this weekend. I’m a newbie at Linux…took me many hours…but seems to be working fine.

  1. Arch Linux installed on a target flash drive, not on the M.2 SSD?

Sorry, I’m MAC illiterate.

No problem on your questions. Fire on.

The instruction was to save Arch Linux in a USB flash drive first before installing it to the M.2 SSD in NUC.

Ok I think I got you…the target flash drive (which you provide instruction to partition) you refer to in your instructions is the M.2 then, right?

Yes, that is correct.

1 Like

@TopQuark do you care to advise me on the above?

In my case, I heard significant difference having NUC closer to the endpoint in terms of bass clarity and depth of the soundstage. I can actually switch it on and off to compare since my older Roon Server set-up can still be accessible with the bridged interface although it added another router which is the NUC in this case. If I were to quantify the improvement, the impression is half of what the Intona gave me when I first installed it. But this is all wired through ethernet CAT8. Not sure if this helps but I also have the sMS-200 so it is very similar to your set-up.

With regard to Wi-Fi, I do not have experience with that. There will be latency issues for sure but I am not positive if the default set-up in Roon Server or sMS-200 can compensate for the latency. One thing for sure, having the NUC closer to the endpoint sounds better than having it closer to the media or your NAS.

1 Like

This doesn’t make any sense. If the NUC is the server feeding a Roon Ready DAC or a Roon Bridge it would not matter where it resides on your network.

Theoretically, yes. I was a skeptic myself but I got the chance to try it. This is probably best to discuss it here:

Looking at the forum it emanates from I know there’s no point reading it. If it floats your boat, great.