dlna server - stopped; can turn it on - next problem

quesst
Posts: 11
Joined: Fri Dec 14, 2012 7:36 pm

dlna server - stopped; can turn it on - next problem

Postby quesst » Fri Dec 14, 2012 7:50 pm

Hello everybody

After about 8 hours of continuous work I managed to get my amahi running. There are still some flaws I cannot get rid of. One of it is that my newly bought DLNA server app just does not start. I have installed it - which went without complaint , I rebooted the system (which may not even be necessary), I tried to turn it on again - yet, it doesn't move a fin.

Is it indexing in the background somehow, before it goes online?

I use xubuntu 12.04 on virtualbox.

Thank you for your suggestions.
quesst
Last edited by quesst on Mon Dec 17, 2012 9:56 am, edited 2 times in total.

User avatar
bigfoot65
Project Manager
Posts: 11441
Joined: Mon May 25, 2009 4:31 pm

Re: dlna server - stopped; can't turn it on...

Postby bigfoot65 » Fri Dec 14, 2012 8:08 pm

Recommend you check the logs. One thing to keep in mind is that although any Ubuntu derivative should work, we do not support them.

With that being said, it is possible there is something with that version that is causing issues. It might be fixable, just need to find out what the issue is that prevents start.
ßîgƒσστ65
Applications Manager

quesst
Posts: 11
Joined: Fri Dec 14, 2012 7:36 pm

Re: dlna server - stopped; can't turn it on...

Postby quesst » Sat Dec 15, 2012 12:34 am

Thank you for the quick reply.

The App Logs tells me:

Code: Select all

Processing ServerController#start (for 192.168.178.34 at 2012-12-15 08:17:31) [POST] Parameters: {"controller"=>"server", "id"=>"8", "action"=>"start", "authenticity_token"=>"Ur42sL0mALh9QeIOs6KTLjYGrw4hUQ4M/mmA9p/2Ybg="} Completed in 1059ms (View: 13, DB: 6) | 200 OK [http://192.168.178.10/server/start/8]
While there is nothing in Logs which would be added the time I hit Start.

Just to confirm:
- With my main coputer I can access the files over smb on amahi as I'm supposed to.

I guess I also add some more system information:
- I had to turn off DHCP and DNS server since my router needs to take this function. Otherwise the Digital-TV-Setopbox of our provider refuses to work. But even if both are turned on I cannot get DLNA running.
- I did not run any update on the system as I understand that Amahi is not tested with updates.
- I installed Vino-server to remote access the server
- I also have WUALA installed (secure online storage) which is syncing important folders. But even turned off there is no change in behaviour.

hope this information helps

User avatar
bigfoot65
Project Manager
Posts: 11441
Joined: Mon May 25, 2009 4:31 pm

Re: dlna server - stopped; can't turn it on...

Postby bigfoot65 » Sat Dec 15, 2012 5:24 pm

I believe DLNA may require the DNS server on the HDA to work.

http://www.amahi.org/faq#is-dhcp-server-required
ßîgƒσστ65
Applications Manager

quesst
Posts: 11
Joined: Fri Dec 14, 2012 7:36 pm

Re: dlna server - stopped; can't turn it on...

Postby quesst » Sun Dec 16, 2012 12:33 am

Thanks for the hint.

As I already mentioned there is no difference in the result of the not working DLNA if I turn on one of the two or both...

*Thinking: get everything running so that there is all in default state.*
Therfore: Does it create any conflicts if I have DHCP and DNS turned on at the same time in amahi and on the router (Fritzbox 7930).
--> update: I searched the internet and got a great thread regarding multiple DHCP-Servers with one submask: http://serverfault.com/questions/368512 ... ne-network

Going through that I thought wow, cool therefore I would just have to limit IP's the DHCP is handing out. But where can I do that? I did not find any settings in the Browser-GUI to do that.
Last edited by quesst on Sun Dec 16, 2012 5:53 am, edited 1 time in total.

User avatar
bigfoot65
Project Manager
Posts: 11441
Joined: Mon May 25, 2009 4:31 pm

Re: dlna server - stopped; can't turn it on...

Postby bigfoot65 » Sun Dec 16, 2012 5:43 am

It can cause conflicts. Recommend you try turning off the router DHCP and DNS. Ensure the client is getting it's IP address from the HDA and using it's DNS.
ßîgƒσστ65
Applications Manager

quesst
Posts: 11
Joined: Fri Dec 14, 2012 7:36 pm

Re: dlna server - stopped; can't turn it on...

Postby quesst » Mon Dec 17, 2012 7:32 am

One problem solved:
1. unistall DLNA
2. Make sure DNS and DHCP are turned on
3. Install DLNA --> wait - depending on the amount of files you have it takes a while till they are indexed and available.

Next Problem:
It seems that only HDA shared folder "Movies", "Music" and "Pictures" get indexed and made available. I have created an extra folder called "series" where several TV-Series are stored. Yet none of them is listed in "My DLNA-Server" on the other devices. (The formats are readable by the devices I want to watch them with. I tested the files by connecting the storage media via USB with the Fritzbox and its built-in Mediaserver with which they were working.)

User avatar
bigfoot65
Project Manager
Posts: 11441
Joined: Mon May 25, 2009 4:31 pm

Re: dlna server - stopped; can turn it on - next problem

Postby bigfoot65 » Mon Dec 17, 2012 10:37 am

That is correct, only those folders are streamed by default. If you want to add more, see the wiki guidance.

http://wiki.amahi.org/index.php/Dlna

Just edit the amahi.conf file and add a line for the other folder. You will see the current shares listed, so just copy that. Then restart amah-dlna service and it should be working.
ßîgƒσστ65
Applications Manager

quesst
Posts: 11
Joined: Fri Dec 14, 2012 7:36 pm

Re: dlna server - stopped; can turn it on - next problem

Postby quesst » Mon Dec 17, 2012 11:39 pm

Thanks for the hint. I now added the folder to the minidlna.conf file. The rest of the post may be a bit of an overkill but there is lots of information in it.

Problem: files do not become visible:
  • 1. Check rights
    I also checked the ownership of the files. It says the the owner is "500"... Never heard of that user:

    Code: Select all

    -rw-rw-r-- 1 500 users 419436544 Aug 23 2009 Criminal Minds S01E01 - Der Abgrund.avi
    Yet, the Movies I can see have the same user:

    Code: Select all

    -rw-rw-r-- 1 500 users 734597120 Feb 18 2012 10.000 BC Teil 1.avi
    When I try to change the ownership to the user "stefan" with

    Code: Select all

    sudo chown stefan:users *
    for the whole folder, it just does not do anything.
    Consequence: Skip this as user rights are the same as the ones of the visible files althought result is not satisfying.
  • 2. Check log
    I also checked the log. There I get the message

    Code: Select all

    scanner.c:719: warn: Scanning /var/hda/files/Music
    starting when I was first able to get DLNA working. But there is no entry that would indicate that

    Code: Select all

    /var/hda/files/serien
    was scanned after i added it to the minidlna.conf file.
    Consequence: I think next step would be to force DLNA to rescan the "folder list"
  • 3. Check forums for making DLNA rescanning files
    I found
    Q: I added additional share locations into the config file but they do not appear!: try removing files.db under /tmp/minidlna/ and restarting the amahi-dlna service
    in http://wiki.amahi.org/index.php/Dlna but there is noch such directory...
    Consequence: Use the information that you look for a files.db file in a minidlna folder
  • 4. Check for files.db and delete it
    Hence I went looking in the console for

    Code: Select all

    cd / find -name "*minidlna*"
    and found several files and folders. The folders containing a files.db are

    Code: Select all

    ./var/cache/minidlna ./var/lib/minidlna
    while "cache" has a files.db of 43MB. Accorging to the readable content I assumed this is the file to delete - and did so after creating files.bak. The other files.db is of 75KB. Restarting amahi-dlna service did not trigger a recreation of the files.db. A reboot of the server did.
    Solution to the problem:
    • - Backup current /var/cache/minidlna/files.db in /var/cache/minidlna/files.bak

      Code: Select all

      sudo cp /var/cache/minidlna/files.db /var/cache/minidlna/files.bak
      - Delete /var/cache/minidlna/files.db

      Code: Select all

      sudo rm /var/cache/minidlna/files.db
      - Reboot Server

      Code: Select all

      sudo reboot
      - Wait till indexing is completed.[/b]
      You can follow the process by comparing the size of the bak file with the newly created bd by entering

      Code: Select all

      ls -l /var/cache/minidlna
      in the console. Depending on whether you added or deleted files the file will become larger or smaller than the previous one. And by checking the log

      Code: Select all

      nano /var/log/minidlna.log
      where it states what it is scanned at the moment.
      - If rescan is successful delete files.bak

      Code: Select all

      sudo rm /var/cache/minidlna/files.bak
      [/b]
Comment: An automatic reindexing or at least a button to click to trigger reindexing somewhere in the hda would be most appreciated!

A small question:
Out of the log:

Code: Select all

WARNING: Inotify max_user_watches [8192] is low or close to the number of used watches [2310] and I do not have permission to increase this limit. Please do so manually by writing a higher value into /proc/sys/fs/inotify/max_user_watches.
I don't think this is critical I still wonder though what "number of used watches" means?

User avatar
bigfoot65
Project Manager
Posts: 11441
Joined: Mon May 25, 2009 4:31 pm

Re: dlna server - stopped; can turn it on - next problem

Postby bigfoot65 » Tue Dec 18, 2012 7:45 am

When you do

Code: Select all

chown
on a directory, it's best to use the -R switch. That ensures all files in the directory get the same permissions.

Code: Select all

sudo chown -R stefan:users /var/hda/files/Music
When you modify the minidlna.conf file, ensure you restart the service. That will ensure all the updates are integrated.

Since there is no front end for AMahi DLNA, there currently is no means for a reindexing button. If you want to reindex the files, recommend restarting the DLNA server. That can be done from the Amahi dashboard typically.

Not sure why you are having so many issues. I have been using DLNA on Ubuntu with no problems. Maybe you should uninstall and reinstall the app. Then make the modifications to minidlna.conf for the additional folders.

Don't have a clue about the "user watches" but it seems harmless. Maybe once you get this all sorted out you could update the wiki with additional guidance for Ubuntu. We would greatly appreciate it.
ßîgƒσστ65
Applications Manager

Who is online

Users browsing this forum: No registered users and 2 guests