ecotec
Posts: 64
Joined: Mon Jul 01, 2013 1:10 pm
Location: Norfolk

Help minidlna driving me crazy!

Sun Mar 20, 2016 5:00 pm

I'm trying to get minidlna setup and am encountering some issues, can anyone offer some advice on how to fix?

minidlna is installed on a B+, connected to external HDD formatted to ex4, I can see the device on the network but I cannot see any of the files in the folders, which suggests it may be permissions related?
Here's where I'm at so far:

Code: Select all

pi@raspberrypi ~ $sudo apt-get install minidlna
pi@raspberrypi ~ $sudo chown -R pi:pi /media/pi/250gb_pi
pi@raspberrypi ~ $ sudo usermod -a -G pi minidlna
pi@raspberrypi ~ $ sudo mkdir /var/{cache,log}/minidlna
pi@raspberrypi ~ $ sudo chown minidlna:minidlna /var/{cache,log}/minidlna

Code: Select all

sudo nano /etc/minidlna.conf

Code: Select all

pi@raspberrypi ~ $ sudo usermod -a -G pi minidlna
then restart

Code: Select all

pi@raspberrypi ~ $ sudo service minidlna restart
Here's my config file
http://pastebin.com/MqkGk0qA
I can create files on the external drive and have checked the properties of the folders and they appear to be accessible to all users,
Any advice?
Thanks!
b raspbian running get-iplayer and mini dlna server
b+ running volumio
pi 2 - dietpi - pihole, ssh and a few other bits

ecotec
Posts: 64
Joined: Mon Jul 01, 2013 1:10 pm
Location: Norfolk

Re: Help minidlna driving me crazy!

Sun Mar 20, 2016 9:05 pm

Ok made some progress, when I move my media to the SD card directly and add a line to the config file, the file is picked up and can be seen on the network.

So i'm thinking this is either permissions or location issue?

I have checked the folders and all users can read the files?

Anyone have any ideas?
b raspbian running get-iplayer and mini dlna server
b+ running volumio
pi 2 - dietpi - pihole, ssh and a few other bits

hal8000
Posts: 190
Joined: Fri Oct 04, 2013 5:22 pm

Re: Help minidlna driving me crazy!

Sun Mar 20, 2016 10:22 pm

If you look what you typed earlier:
sudo chown -R pi:pi /media/pi/250gb_pi

You created a directory called /media/pi/250gb_pi

If you look at your pastebin

media_dir=A,/media/pi/250gb/radio
media_dir=P,/media/pi/250gb/pictures
media_dir=V,/media/pi/250gb/videos
media_dir=V,/media/250gb/tv

Those directories dont match your mount point.
You can just simply call it /media/HDD and follow this example:

http://www.instructables.com/id/Raspber ... /?ALLSTEPS

However your mount point MUST be consistent so you need to post the output
of cat /etc/fstab

Bear in mind also that as you've used an ext4 filesystem then your other Pi and linux
computers can see the hard drive, but windows machines can not. If you follow the example
keep your file system as ext4 but make sure mount point use consistant naming,






media_dir=A,/media/pi/250gb/radio

ecotec
Posts: 64
Joined: Mon Jul 01, 2013 1:10 pm
Location: Norfolk

Re: Help minidlna driving me crazy!

Mon Mar 21, 2016 7:36 am

Hi hal8000, thanks for your post,

so I corrected the config file to:
media_dir=A,/media/pi/250gb_pi/radio
media_dir=P,/media/pi/250gb_pi/pictures
media_dir=V,/media/pi/250gb_pi/videos
media_dir=V,/media/250gb_pi/tv

output of /etc/fsab is as follows:
http://pastebin.com/HULUfZtg

So i'm assuming I can add a line at the bottom like:

/dev/sda1 /media/pi/250gb_pi ext4 defaults 0 2

Will this addition effect the data already on the disc?

Many thanks!
b raspbian running get-iplayer and mini dlna server
b+ running volumio
pi 2 - dietpi - pihole, ssh and a few other bits

ecotec
Posts: 64
Joined: Mon Jul 01, 2013 1:10 pm
Location: Norfolk

Re: Help minidlna driving me crazy!

Mon Mar 21, 2016 5:30 pm

Thanks, all updated and my files are available,
b raspbian running get-iplayer and mini dlna server
b+ running volumio
pi 2 - dietpi - pihole, ssh and a few other bits

hal8000
Posts: 190
Joined: Fri Oct 04, 2013 5:22 pm

Re: Help minidlna driving me crazy!

Mon Mar 21, 2016 6:38 pm

OK, you can copy and paste direct from your Pi no need to use imgur.
You need SSH access and its simpy ctrl+c and Ctrl+shift+v to paste
from linux.
If youre on windows, use putty, then SSH and I think its a right click
and drag (followed by copy)

This is what you have:
proc /proc proc defaults 0 0
/dev/mmcblk0p6 /boot vfat defaults 0 2
/dev/mmcblk0p7 / ext4 defaults,noatime 0 1

Not sure what youve done to your SD card but it has 7 partitions,
Doesn't really matter as long as you remember that / is partition 7. The only time
it may be a problem is if you had a power cut, and you had to run
a filesystem check on the card.


Yes you can append

/dev/sda1 /media/pi/250gb_pi ext4 defaults 0 2

that line to /etc/fstab.
Its only an entry to the filesystem table so the OS uses
this lookup table when you issue a mount command.

If you type:
sudo mount /media/pi/250gb_pi

your hard drive will be mounted, although its quicker
to use

sudo mount -a

Which mounts all entries. When you reboot fstab
is read and automatically mounted by the "defaults"
option. You can access man fstab for more options.

ecotec
Posts: 64
Joined: Mon Jul 01, 2013 1:10 pm
Location: Norfolk

Re: Help minidlna driving me crazy!

Mon Mar 21, 2016 7:06 pm

Many thanks for your help, its all working.

RE 7 partitions - I think this is due to be using NOOBS as my other pi shows the same output,
b raspbian running get-iplayer and mini dlna server
b+ running volumio
pi 2 - dietpi - pihole, ssh and a few other bits

hal8000
Posts: 190
Joined: Fri Oct 04, 2013 5:22 pm

Re: Help minidlna driving me crazy!

Mon Mar 21, 2016 8:14 pm

Youre welcome.

Return to “Media centres”