SOLVED Can't install MiniDLNA in jail

Status
Not open for further replies.

HemaN

Cadet
Joined
Sep 5, 2017
Messages
3
Hello everyone! On the begining just want to say that I am completely new to FreeNAS and FreeBSD so please be patience :) .

I successfully installed FreeNAS 11 U3 to USB stick and configured simple mirror of 2 drives. Then created SMB share that can be accessed from any PC in my network. Then just wanted to install miniDLNA and my luck finished at that point. I followed this tutorial:

https://forums.freenas.org/index.ph...inidlna-on-freenas-9-3-prior-to-plugin.25395/

I stack on point 20a of this tutorial. When I type "pkg install minidlna" error code appears:


Updating FreeBSD repository catalogue...
pkg: Repository FreeBSD load error: access repo file(/var/db/pkg/repo-FreeBSD.sq
lite) failed: No such file or directory



Started to looking for solutions and found this thread:

https://forums.freenas.org/index.php?threads/jail-9-3.34821/

But I can't open FreeBSD.conf file. Tried to get to the directory /usr/local/etc/pkg/repos through Shell and open that file with ee but just blank document opens. Also tried disable VIMAGE and restart Jail - this didn't helped to. Then I looked for other solutions and found this thread:

https://forums.freebsd.org/threads/55819/

But again, when I'm trying to type "/usr/sbin/pkg bootstrap -f" I get response:


The package management tool is not yet installed on your system.
Do you want to fetch and install it now? [y/N]:



When I type "y" getting this message:


Bootstrapping pkg from file:///usr/ports/packages, please wait...
pkg: Error fetching file:///usr/ports/packages/Latest/pkg.txz: No such file or d
irectory
A pre-built version of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports: 'ports-mgmt/pkg'.


Also tried "pkg update -f" command, but getting this response:


Updating local repository catalogue...
pkg: file:///usr/ports/packages/meta.txz: No such file or directory
repository local has no meta file, using default settings
pkg: file:///usr/ports/packages/packagesite.txz: No such file or directory
Unable to update repository local


And response for "pkg upgrade" command:


Updating local repository catalogue...
pkg: file:///usr/ports/packages/meta.txz: No such file or directory
repository local has no meta file, using default settings
pkg: file:///usr/ports/packages/packagesite.txz: No such file or directory
Unable to update repository local
All repositories are up-to-date.
pkg: Repository local cannot be opened. 'pkg update' required
Checking for upgrades (0 candidates): 100%
Processing candidates (0 candidates): 100%
Checking integrity... done (0 conflicting)
Your packages are up to date.


What else can I do to solve this issue? If you need some logs just say, will place them here ASAP.

Thanks in advice.
 

JohnKnee

Dabbler
Joined
Aug 24, 2011
Messages
43
Hi,

I think part of the reason for this may be due to the fact that the packages are being upgraded from minidlna 1.1.5_1,1 to minidlna 1.2.0,1 which is the latest available. You can always find the latest version at http://pkg.freebsd.org/freebsd:11:x86:64/latest/

You can manually fetch the package if you want and install it that way. Make sure you are in the jail first.

1) fetch http://pkg.freebsd.org/freebsd:11:x86:64/latest/All/minidlna-1.2.0,1.txz
2) pkg install minidlna-1.2.0,1.txz
3) then follow the rest of the guide.

I am on version 1.2.0,1 and all works well on FreeNas 11-U3. Hope this helps.
 
Joined
Apr 9, 2015
Messages
1,258
While in the jail run

Code:
pkg update && pkg upgrade


Before you start installing. If that fails then check your DNS settings in the jail.

Code:
edit /etc/resolv.conf


If there are no DNS servers for ipv4 then add your router as one and then add something else like 8.8.8.8 or 208.67.222.222 or add all three and then try it again. I have noticed that some jails that were created with DHCP and then changed to a static IP have not been having DNS settings populated. Since I have always used autoconf for IPV6 I have not noticed if that is an issue or not.


The pkg command should work and there should be no reason to manually grab it.
 

HemaN

Cadet
Joined
Sep 5, 2017
Messages
3
Thanks guys for your tips. But the problem was somewhere else: jail did not have internet connection. I should check basics before go any further. One is teaching on mistakes, its too bad that no on someone else mistakes :) .

After few hours of fighting with ip adresses I just checked DHCP and it started to ping from inside the jail (don't like DHCP and always trying to set static IP for every device in my network). Then was able to manually install lastest MiniDLNA like JohnKnee suggested and do pkg update and upgrade like nightshader00013 said. And now MiniDLNA is working like a charm.

Hope this will help other user that are new to FreeNAS.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
So does the procedure work as written? If not, please let me know and I'll investigate and fix it.
 

HemaN

Cadet
Joined
Sep 5, 2017
Messages
3
Hello Joeschmuck,

yes, it did work with DHCP on. Without DHCP I wasn't able to manually assign IP adres to MiniDLNA. Even now if i'll try to change from DHCP to static IP address nothing changes, its still DHCP. I even tried uncheck VIMAGE but without luck. Maybe I'm doing something in wrong way.

Edit: Ok, I found reason of not being able to change from DHCP to static IP. Didn't stop jail before I tried to change IP. When I stoped it then everything works as it should. Another simple mistake :) .
 
Last edited:

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
Glad to hear that it did work as written. Sometimes when FreeNAS gets updated and I'll need to make a small adustment to the procedure to make it work again.
 
Status
Not open for further replies.
Top