Problem with installing pkg

Status
Not open for further replies.

szymex73

Cadet
Joined
Feb 27, 2014
Messages
5
Hello,
I have problem with installing pkg.
When I enter pkg
Code:
[root@freenas ~]# pkg                                                         
The package management tool is not yet installed on your system.               
Do you want to fetch and install it now? [y/N]: y                             
Bootstrapping pkg please wait                                                 
_http._tcp.pkg.FreeBSD.org                                                     
pkg: fail to extract pkg-static                                               
[root@freenas ~]# 

I have error.:(
 

joelmusicman

Patron
Joined
Feb 20, 2014
Messages
249
That's wierd. I've never had issues using pkg and it was installed from the get-go. Which version of FreeNAS are you running?
 
D

dlavigne

Guest
Yes, the exact version is important as somewhere along the way pkg got mucked up in one of the FreeNAS versions and we're trying to track down when.
 

szymex73

Cadet
Joined
Feb 27, 2014
Messages
5
I have another problem
Code:
[root@freenas ~]# pkg_add -r pkg                                                                                                   
Error: Unable to get ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-9-stable/Latest/pkg.tbz: No address record             
pkg_add: unable to fetch 'ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-9-stable/Latest/pkg.tbz' by URL                   
[root@freenas ~]# 
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Well, 99% of the time that means that your system had no access to the internet. The cause will have to be investigated. Were you trying to do a package add on the FreeNAS usb stick? That's kind of what it looks like, and that is exactly what is NOT recommended. That's what jails are for. ;)
 

jthenley

Cadet
Joined
Apr 13, 2014
Messages
2
I just ran into the same problem and worked out what was wrong. To actually answer your question, it is failing as the root file system / is mounted as read-only. Remount it read-write and run pkg again.

#mount -o rw /
#pkg
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Yeah.. and it's read only because you aren't supposed to install anything to begin with! ANYTHING you want to install should go in a jail. If these limitations are too limiting, FreeBSD awaits you. ;)
 

jthenley

Cadet
Joined
Apr 13, 2014
Messages
2
Understood, cute dog by the way. I quite like FreeBSD with the FreeNAS components pre-installed, I had to add some bits to the core FreeBSD platform. Next you'll be telling me I'm not supposed to run it as a virtual machine under Xen!
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Understood, cute dog by the way. I quite like FreeBSD with the FreeNAS components pre-installed, I had to add some bits to the core FreeBSD platform. Next you'll be telling me I'm not supposed to run it as a virtual machine under Xen!

We do have threads on that topic.. there's risk involved, and if you come by later and have a problem we'll delete your thread as we've given the warnings that you are on your own if it breaks.
 
Status
Not open for further replies.
Top