Noob here...

When I run "sudo apt-get update" i get:

0% [Connecting to archive.raspbian.org ( ] [Connecting to archive.raspberrypi.org (]

Err http://mirrordirector.raspbian.org jessie InRelease

Err http://mirrordirector/raspbian.org jessie Release.gpg

Cannot initiate the connection to ...[so on] ... (101: Network is unreachable) ... tries to connect to archive.raspberrypi.org and same thing happen!

Pinging Google.com works with 0% loss

Pinging both IPs for mirrordirector.raspbian.org and archive.raspberrypi.org given above works with 0% loss <

Im running a Pi Zero v1.3 clean install jessie-lite Also noticed that rpi-update returns "command not found".

Im running the PI zero in headless mode over USB WITH Internet (from my PC) like this: https://learn.adafruit.com/turning-your-raspberry-pi-zero-into-a-usb-gadget/ethernet-gadget

Any suggestions?

sudo route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface         UG    202    0        0 usb0   U     202    0        0 usb0
  • are you able to ping archive.raspberrypi.org?
    – Orphans
    Nov 10, 2016 at 19:48

2 Answers 2


It can be a DNS problem too. Can you update resolv.conf by:

sudo nano /etc/resolv.conf

and then add these lines to the file:


which would use Google's DNS server.

Save and reboot and try the apt-get command again and see if this helps.


Disable Avast!!!

Avast Firewall or some shield was messing up with me...

  • How would someone disable it? Why not make a rule that allows what is obviously valid traffic. Nov 10, 2016 at 1:16
  • avast on raspbian?..
    – Orphans
    Nov 10, 2016 at 19:48
  • @Orphans Presumably this means the problem was not Pi related after all.
    – goldilocks
    Nov 11, 2016 at 13:49
  • @goldilocks The answer does not make any sence at all.
    – Orphans
    Nov 11, 2016 at 15:16
  • 2
    @Orphans I dunno. The question does say it's about a Pi Zero used as an OTG ethernet gadget, meaning traffic was routed through the PC. On which a firewall or anti-virus software may have created the problem.
    – goldilocks
    Nov 11, 2016 at 20:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.