Solved portsnap fetch error

Hi , I'm a FreeBSD (version 11 amd64) new user since yesterday and I have a problem with portsnap fetch and pkg(8).
(I'm sorry for my English, I'm not good, I hope you'll understand me and help me ) .

When I do portsnap fetch I have this on output :
Code:
Looking up portsnap.FreeBSD.orgmirrors ... 6 mirrors found 
Fetching public key from ec2-eu-west-1.portsnap.freebsd.org... failed
Fetching public key from your-org.portsnap.freebsd.org... failed
Fetching public key from sourcefire.portsnap.freebsd.org... failed
Fetching public key from ec2-ap-northeast-1.portsnap.freebsd.org... failed
Fetching public key from ec2-sa-est-1.portsnap.freebsd.org... failed
Fetching public key from ec2-ap-southeast-2.portsnap.freebsd.org... failed
No mirrors remaining , giving up

I'm connect with ethernet mod , ping -c 3 8.8.8.8 output :
Code:
PING 8.8.8.8 (8.8.8.8):56 data bytes
64 bytes from 8.8.8.8 : icmp_seq=0 tt1=59 time=16.411 ms
64 bytes from 8.8.8.8 : icmp_seq=1 tt1=59 time=16.849 ms
64 bytes from 8.8.8.8 : icmp_seq=2 tt1=59 time=16.864 ms
--- 8.8.8.8 ping statistics ---
3 packets transmitted, 3 packets received , 0.0% packet loss 
round-trip min/abg/max/stddev= 16.411/16.708/16.864/0.210 ms

Here's my /etc/resolv.conf:
Code:
# Generated by resolvconf 
#nameserver my ip 
(i added google DNS to try , i saw that in similar thread but it doesn't work for me )
nameserver 8.8.8.8
nameserver 8.8.4.4
option edns0

Thanks for read and really I'm sorry for my English.
 
What happens if you do this?
fetch http://ec2-eu-west-1.portsnap.freebsd.org/pub.ssl

You should get a file called pub.ssl in the directory you run this from. That's all the portsnap code is doing at the stage where you get the error.

If you still get an error, post the output of nslookup ec2-eu-west-1.portsnap.freebsd.org so we can see if it's a DNS issue or something else...
 
thanks for reply , i can't use nslookup "command not found ", and i can't download because pkg doesn't work too :/
pkg
Code:
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 from pkg+http://pgk.FreeBSD.org/FreeBSD:11:AMD64/quaterly please wait ...
pkg: Error fetching  http://pkg.FreeBSD.org/FreeBSD:11:AMD64/quaterly/Latest/pkg.txz : No adress record
A pre-built vversion of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports :'ports-mgmt/pkg'
I have already tried to change PACKAGESITE with setenv PACKAGESITE http://pkg.freebsd.org/freebsd:11:x86:64/latest but i have the same probleme :(
 
Code:
http://pgk.FreeBSD.org/FreeBSD:11:AMD64/quaterly/Latest/pkg.txz
Did you enable a different repository? It looks like you've made several typos in the URL. It's pkg.freebsd.org, not pgk.freebsd.org.
 
it's my fault ^^ i wrote output because , i have install freebsd in other computer (i can't copy/past) but the error message is
Code:
http://pkg.FreeBSD.org/FreeBSD:11:AMD64/quaterly/Latest/pkg.txz
sorry ^^
 
Check your DNS settings (/etc/resolv.conf). Ping those IP addresses, if you get a response use drill(1) (similar to dig(1)) to find out if they actually respond to DNS requests.
 
thanks for reply , here's my drill output :
Code:
;;->>HEADER<<- opcode: QUERY , rcode, NOERROR, id : 9034
;; flags: qr rd ra ; QUERY: 1 , ANSWER : 13 , AUTHORITY: 0, ADDITIONAL :0
;;QUESTION SECTION :
;; .         IN           NS

;;ANSWER SECTION :
.            1954           IN            NS               a.root-servers.net.
.            1954           IN            NS               b.root-servers.net.
.            1954           IN            NS               c.root-servers.net.
.            1954           IN            NS               d.root-servers.net.
.            1954           IN            NS               e.root-servers.net.
.            1954           IN            NS               f.root-servers.net.
.            1954           IN            NS               g.root-servers.net.
.            1954           IN            NS               h.root-servers.net.
.            1954           IN            NS               i.root-servers.net.
.            1954           IN            NS               j.root-servers.net.
.            1954           IN            NS               k.root-servers.net.
.            1954           IN            NS               l.root-servers.net.
.            1954           IN            NS               m.root-servers.net.

;;AUTHORITY SECTION :

;;ADDITIONAL SECTION :

;;Query time : 16msec
;; SERVER: 8.8.4.4
;;WHEN: Tue Nov 1 14:21:26 2016
;; MSG SIZE rcvd: 228

Thanks, I tried with setenv PACKAGESITE http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest/ but still doesn't work
 
"It does not work" doesn't tell us anything. What is the error you're getting?
 
sorry this is the output
Code:
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 from pkg+http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest please wait ...
pkg: Error fetching  http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest/Latest/pkg.txz : No adress record
A pre-built vversion of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports :'ports-mgmt/pkg'

No adress record (error )
 
yes it's the same probleme i think pkg -vv
Code:
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 from pkg+http://pgk.FreeBSD.org/FreeBSD:11:amd64/latest please wait ...
pkg: Error fetching  http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest/Latest/pkg.txz : No adress record
A pre-built vversion of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports :'ports-mgmt/pkg'
 
yes it's the same probleme i think pkg -vv
Code:
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 from pkg+http://pgk.FreeBSD.org/FreeBSD:11:amd64/latest please wait ...
pkg: Error fetching  http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest/Latest/pkg.txz : No adress record
A pre-built vversion of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports :'ports-mgmt/pkg'
How about pkg-static -vv? The static version should be preinstalled...
 
Bootstrapping pkg from pkg+http://pgk.FreeBSD.org/FreeBSD:11:amd64/latest please wait ...
Ouch .. exactly the same typo at same place for the second time ... are you sure it is a typo ?
 
What happens if you try fetch http://pkg.freebsd.org/FreeBSD:11:amd64/latest/Latest/pkg.txz (keeping in mind what ASX just mentioned, since you can't copy-paste from the affected box...)
 
^^ really sorry i copy/past my bad post and changed (because i can't directly copy/paste i have two computer one on FreeBSD and one on Debian) but it's "pkg" not "pgk" on my screen ^^
 
When i do fetch http://pkg.freebsd.org/FreeBSD:11:amd64/latest/Latest/pkg.txz
i have
Code:
fetch : http://pkg.freebsd.org/FreeBSD/11:amd64/latest/Latest.pkg.txz : No adress record
 
I assume the Debian machine does have a working internet connection? Why don't you secure shell into the FreeBSD machine? That way you can properly copy/paste information. It's going to be very difficult for us to help out if we can't be sure the information you're posting is correct or not.
 
So now i'm connect with ssh on my debian machine i can repost all thing :
portsnap fetch
Code:
Looking up portsnap.FreeBSD.org mirrors... 6 mirrors found.
Fetching public key from ec2-eu-west-1.portsnap.freebsd.org... failed.
Fetching public key from your-org.portsnap.freebsd.org... failed.
Fetching public key from sourcefire.portsnap.freebsd.org... failed.
Fetching public key from ec2-sa-east-1.portsnap.freebsd.org... failed.
Fetching public key from ec2-ap-southeast-2.portsnap.freebsd.org... failed.
Fetching public key from ec2-ap-northeast-1.portsnap.freebsd.org... failed.
No mirrors remaining, giving up.


ping -c 3 8.8.4.4
Code:
PING 8.8.4.4 (8.8.4.4): 56 data bytes
64 bytes from 8.8.4.4: icmp_seq=0 ttl=58 time=13.920 ms
64 bytes from 8.8.4.4: icmp_seq=1 ttl=58 time=13.834 ms
64 bytes from 8.8.4.4: icmp_seq=2 ttl=58 time=14.430 ms

--- 8.8.4.4 ping statistics ---
3 packets transmitted, 3 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 13.834/14.061/14.430/0.263 ms



drill
Code:
;; ->>HEADER<<- opcode: QUERY, rcode: NOERROR, id: 43447
;; flags: qr rd ra ; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;; .   IN   NS

;; ANSWER SECTION:
.   6607   IN   NS   f.root-servers.net.
.   6607   IN   NS   h.root-servers.net.
.   6607   IN   NS   j.root-servers.net.
.   6607   IN   NS   i.root-servers.net.
.   6607   IN   NS   m.root-servers.net.
.   6607   IN   NS   c.root-servers.net.
.   6607   IN   NS   g.root-servers.net.
.   6607   IN   NS   l.root-servers.net.
.   6607   IN   NS   b.root-servers.net.
.   6607   IN   NS   a.root-servers.net.
.   6607   IN   NS   d.root-servers.net.
.   6607   IN   NS   e.root-servers.net.
.   6607   IN   NS   k.root-servers.net.

;; AUTHORITY SECTION:

;; ADDITIONAL SECTION:

;; Query time: 15 msec
;; SERVER: 8.8.8.8
;; WHEN: Tue Nov  1 15:53:58 2016
;; MSG SIZE  rcvd: 228

pkg
Code:
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 from http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest, please wait...
pkg: Error fetching http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest/Latest/pkg.txz: No address record
A pre-built version of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports: 'ports-mgmt/pkg'.

Thank you , it's copy/past with ssh connection
 
Well, just the fact you can SSH into the FreeBSD machine shows it definitely has network access. You can also ping the Google DNS servers so getting out of your local network works too. What's in /etc/resolv.conf?
 
in my /etc/resolv.conf
i have that
Code:
# Generated by resolvconf
  # nameserver 89.2.0.1
  # nameserver 89.2.0.2
   nameserver  8.8.8.8
   nameserver  8.8.4.4
   options edns0
 
Here's my /etc/resolv.conf:
Code:
# Generated by resolvconf
#nameserver my ip
(i added google DNS to try , i saw that in similar thread but it doesn't work for me )
nameserver 8.8.8.8
nameserver 8.8.4.4
option edns0
I’ve noticed you have set the option edns0 in resolv.conf.

From (NetBSD, I couldn't find that option in FreeBSD's man page) resolve.conf(5) that option states:

Code:
edns0

DNS query packets with EDNS0
extension is not compatible with non-EDNS0
DNS servers.  The option must be used only
when all the DNS servers listed in nameserver
lines are able to handle EDNS0 extension.
Try without that option.
 
i removed option edns0 but i still have the same error message
pkg
Code:
Do you want to fetch and install it now? [y/N]: y
Bootstrapping pkg from pkg+http://pkg.FreeBSD.org/FreeBSD:11:amd64/quarterly, please wait...
pkg: Error fetching http://pkg.FreeBSD.org/FreeBSD:11:amd64/quarterly/Latest/pkg.txz: No address record
A pre-built version of pkg could not be found for your system.
Consider changing PACKAGESITE or installing it from ports: 'ports-mgmt/pkg'.

portsnap fetch
Code:
Looking up portsnap.FreeBSD.org mirrors... 6 mirrors found.
Fetching public key from ec2-eu-west-1.portsnap.freebsd.org... failed.
Fetching public key from your-org.portsnap.freebsd.org... failed.
Fetching public key from sourcefire.portsnap.freebsd.org... failed.
Fetching public key from ec2-ap-southeast-2.portsnap.freebsd.org... failed.
Fetching public key from ec2-sa-east-1.portsnap.freebsd.org... failed.
Fetching public key from ec2-ap-northeast-1.portsnap.freebsd.org... failed.
No mirrors remaining, giving up.
 
Try these two commands:
Code:
ping google.com
ping freebsd.org
 
Back
Top