[Solved] Use second HD in PC for storing music

I have installed a second HD in desktop PC that I want to use to store musicfiles.
I need a “cookbook” how to get this to appear as INTERNAL2 in Volumio.

Here is output of fdisk -l

volumio@volumio-2-hd:/data$ sudo fdisk -l

Disk /dev/loop0: 513.3 MiB, 538263552 bytes, 1051296 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 2.7 TiB, 3000592982016 bytes, 5860533168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/sda: 298.1 GiB, 320072933376 bytes, 625142448 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: C8195E35-3CC4-42FE-AFCC-FF2C9A1FD42B

Device Start End Sectors Size Type
/dev/sda1 2048 999423 997376 487M EFI System
/dev/sda2 999424 6836223 5836800 2.8G Linux filesystem
/dev/sda3 6836224 625142414 618306191 294.9G Linux filesystem

Disk /dev/sdc: 3.7 TiB, 4000787030016 bytes, 976754646 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x8b429008

It is Disk /dev/sdc I want to use.

hoping for help what commands to enter and where in Linux file structure.

Mount ‘/dev/sdc3’ to a suitable mount point such as ‘/mnt/INTERNAL2’. This can be done temporarily to test, or in fstab permanently (Google). Make a symbolic link from ‘/var/lib/mpd/music’ to your mountpoint so that Volumio/mpd can find it.

This is not actually helping me, I have tried to understand some tutorials on the net, but I only get more confused.

What steps do I have to perform?

Is this all steps or is something missing?

-partition How?
-mountpoint how? where?
-mount where? how?
-fstab how to alter?
-symbolic link where? how?

I am not very good at linux systems.

I now have this partition:

Disk /dev/sdb: 2.7 TiB, 3000592982016 bytes, 5860533168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: CD79E493-430F-49D3-86F7-AD8BB5FDD943

Device Start End Sectors Size Type
/dev/sdb1 2048 5860533134 5860531087 2.7T Linux filesystem

Any suggestions?

Mount points:

volumio@volumio-2-hd:/mnt$ ls -l
total 4
lrwxrwxrwx 1 root root 14 Jun 14 17:04 INTERNAL -> /data/INTERNAL
drwxrwxrwx 2 volumio volumio 4096 Jun 22 15:33 INTERNAL2
drwxrwxrwx 2 root root 3 Jun 14 17:04 NAS
drwxrwxrwx 2 root root 3 Jun 14 17:04 UPNP
lrwxrwxrwx 1 root root 6 Jun 14 17:04 USB -> /media

When i try to mount it i get this faultcode:

volumio@volumio-2-hd:/mnt$ mount /dev/sdb1 /mnt/INTERNAL2
mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
missing codepage or helper program, or other error

Firstly, apologies for misreading your ‘fdisk’ output in the OP… there is no partition ‘/dev/sdc3.’

Add the partition to be mounted to ‘/etc/fstab’ (use ‘sudo nano’):

/dev/sdb1 /mnt/INTERNAL2 ext4 defaults 0 2

Substitute your filesystem type for ext4. You may well want to read up on alternatives to the ‘defaults’ option.

Make a symbolic link:

ln -s /mnt/INTERNAL2 /var/lib/mpd/music/INTERNAL2

Edit: have you formatted your partition?
Edit 2: I’m a little confused now about the id of your second hard disk…sdb or sdc?

The disk is sdb.
sdc is USB HD

I formatted the partition and added it to fstab, but when I restart the PC the fstab seems to get overwritten and sdb1
is not present in the file and of course not mounted.
Anything to do with the USB disk being present?

I manually mounted the disk and created the symbolic link, after an update through the WEB UI Internal2
is found.

So remaining problem is the fstab-file, why does it get overwritten?

One more thing, how to access the Internal2 from my network, is it
configuring something in Samba?

You haven’t described your volumio setup … are you booting from a USB stick or is Volumio installed on a hdd?

With regard to access to INTERNAL2, you probably need to make it a samba share (like ‘Internal Storage’ (INTERNAL) already is).

I am booting from HD.

I Understand that I have to edit smb.conf

[global]
netbios name = Volumio
server string = Volumio Audiophile Music Player
workgroup = WORKGROUP
security = user
map to guest = Bad User
encrypt passwords = yes
wins support = yes
local master = no
preferred master = no
os level = 30

[Internal Storage]
comment = Volumio Internal Music Folder
path = /data/INTERNAL
read only = no
guest ok = yes

[Internal Storage2]
comment = Volumio Internal Music Folder
path =??? What to put here?
read only = no
guest ok = yes

[USB]
comment = Volumio Internal Music Folder
path = /mnt/USB
read only = no
guest ok = yes

[NAS]
comment = Volumio Internal Music Folder
path = /mnt/NAS
read only = no
guest ok = yes

path=/mnt/INTERNAL2

I now got everything working, EXCEPT the fstab issue.

Are there any startup script/scripts that can be modifed to mount the extra disk at restart/boot?

fstab is indeed overwritten on reboot, but you can make your change permanent by editing ‘/etc/fstab.tmpl’ to include the changes you want adding to fstab. Please be very careful in your edits here, and double check that you have correctly identified the correct device to be mounted.

Now it works!

Thank You very much

regards
/Sören

As I understand the guides here, you use ext4 format (correct?), could I use fat32 or exfat instead?
This would make it easier to copy new music to the drive from Windows…

yes, you can.
Just substitute" ext4" by “vfat” (for FAT32).
Microsoft only announced exFAT integration a few hours ago, so this is going to take while…

Thanks!
However, I’m not quite sure what you mean with ‘Microsoft only announced exFAT integration a few hours ago’.
I have used exFAT with Windows for ‘ages’…