PACKAGESITE pkg.conf or whatever

Suppressing the need to rant because it will only end with me looking like an idiot.

Have returned to testing FB FreeBSD as a virtual guest (now Win 7/VirtualBox). In a previous life the ports collection (from DVD) worked peachy. Now trying to get my head aroung pkg in a 9.2 environment. How the hell do I correctly set the above? I think I've read everything so either set it in pkg.conf or in env. Specifically, I'm trying to get at PHP but just getting
Code:
No valid repository found
I confirm that variable is not set. Just completely missing the point as to what it should be set to. :r
 
The correct setting is now nothing, the variable is no longer used because of multi-repository support. Instead you should create a repository configuration file under /usr/local/etc/pkg/repos. For example, /usr/local/etc/pkg/repos/FreeBSD.conf with these contents:

Code:
FreeBSD: {
  url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest",
  mirror_type: "srv",
  signature_type: "fingerprints",
  fingerprints: "/usr/share/keys/pkg",
  enabled: no
}

You can always test which repositories are in use by running pkg -vv.
 
I shall try this out, many thanks for the reply. (Subtext, was this documented anywhere @&$! where, sorry, boarding on a rant.)
 
Blimey, still frustrated (but don't go there). More man pages to read on pkg search but this is my latest chance to re-visit since last post. Updates to follow... :r
 
For what it's worth, there have already been a few threads here about this very issue. However, that does not negate the observation that this change in how to specify repositories appears to have caught many people with their pants down. So communication might have been lacking somewhat, indeed.

In fact, there have been several changes to the ports infrastructure recently and although the actual changes themselves are for the better, the way they were communicated did occasionally leave something to be desired. Sorry for the inconvenience.

Edit: disclaimer: not that I was in charge of anything though, so please don't blame me ;)
 
Since earlier today when I most recently visited the forum, I was reminiscing about the days one could in a paragraph explain almost all there is about package management, being somewhat more welcoming to newbies than most any other distro (IIRC). Accordingly, maybe there could be a port "pkg_cookbook", updated as often as the package ports, detailing (short as well as involved explanations etc.) the fifty or so most common usages and scenarios one may encounter with their usage. I further thought that maybe ports-mgmt/pkg could be coded to report upstream, optionally, on its usage (with permission) (if only for a while) so that the maintainers of such a "cookbook" could be informed of which scenarios to write about (though persons could simply grep their saved history, if any, and likewise...).
 
I absolutely blame @fonz, he who denied it...

Hmmm, I think I've copied the code okay, pkg -vv is not informative, more reading then...
 
Last edited by a moderator:
Head still being scratched.

pkg -vv reports url;

Code:
pkg+http://pkg.FreeBSD.org/freebsd:9:x86:32:/latest

pkg search php reports nowt.

Please, before I'm slapped again about not conforming to forum rules, I promise to get VirtualBox cut and paste working at the same time which might make my life simpler.
 
medsdonthelp said:
I promise to get VirtualBox cut and paste working at the same time which might make my life simpler.
Enable sshd(8) on the FreeBSD guest and use PuTTY on the Windows host to connect to it.
 
Thank you SirDice. Short update; I'm outraged. I thought I could try the cheap and nasty route. When was telnet removed from Windows? But probably outside the scope of this forum :$ Colleagues have 'raved' about Putty, another step to try.

Some feedback on whether the URl is okay and if my use of pkg search is better than incompetent would be nice.
 
Still flummoxed. pkg -vv shows Repositories: "blank". Would love to get virtual additions and PHP but failing. Web searches do not provide anything meaningful and I can't see a facility to search these forums across the board.

Can anyone throw me bone here?

A truly truly frustrating experience.
 
Did you create a custom repository entry in /usr/local/etc/pkg/repos/? If so, try removing them. If you just want the standard (official) packages you don't need to add anything. It should work "out-of-the-box".
 
So if I go completely against @SirDice' s most recent advice I re-instate /usr/local/etc/pkg/repos/FreeBSD.conf as per previous advice.

Code:
FreeBSD: {
  url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest",
  mirror_type: "srv",
  signature_type: "fingerprints",
  fingerprints: "/usr/share/keys/pkg",
  enabled: no
}

Which pkg search gives me "No valid......"

pkg -vv confirms no entry.
 
Last edited by a moderator:
Try running pkg update -f and run pkg search again. Many users have reported that pkg update -f is needed to properly get pkg(8) to update the repository metadata after updating to version 1.3.7 of ports-mgmt/pkg.
 
Ta getopt. All I can say this late in the evening is that I am (finally) getting an error msg "No address record....." which I view as progress. Dear kpa, more to checked out, thanks for the suggestion.
 
Back
Top