what would cause repo sync to fail?

Yocto related software discussions are here

what would cause repo sync to fail?

Postby edsut » Fri Oct 03, 2014 5:51 pm

I'm running behind a proxy, so I'm pretty sure that has something to do with this...
I'm trying to follow the steps on the "Getting Started with Yocto on Wandboard" page (http://wiki.wandboard.org/index.php/Get ... _Wandboard)
When I run the step "repo sync", I get lots of connection failures and eventually it gives up...

Code: Select all
$ repo sync
Fetching project meta-fsl-arm
Fetching project fsl-community-bsp-base
Fetching project meta-fsl-demos
Fetching project meta-openembedded
fatal: unable to connect to git.yoctoproject.org:
git.yoctoproject.org[0: 140.211.169.56]: errno=Connection timed out

fatal: unable to connect to github.com:
github.com[0: 192.30.252.131]: errno=Connection timed out

fatal: unable to connect to github.com:
github.com[0: 192.30.252.131]: errno=Connection timed out

fatal: unable to connect to git.openembedded.org:
git.openembedded.org[0: 140.211.169.152]: errno=Connection timed out

fatal: unable to connect to github.com:
github.com[0: 192.30.252.129]: errno=Connection timed out

fatal: unable to connect to github.com:
github.com[0: 192.30.252.129]: errno=Connection timed out

fatal: unable to connect to git.yoctoproject.org:
git.yoctoproject.org[0: 140.211.169.56]: errno=Connection timed out

fatal: unable to connect to git.openembedded.org:
git.openembedded.org[0: 140.211.169.152]: errno=Connection timed out

error: Cannot fetch meta-fsl-demos
Fetching project meta-fsl-arm-extra
error: Cannot fetch meta-fsl-arm
error: Cannot fetch fsl-community-bsp-base
error: Cannot fetch meta-openembedded
fatal: unable to connect to github.com:
github.com[0: 192.30.252.128]: errno=Connection timed out

fatal: unable to connect to github.com:
github.com[0: 192.30.252.128]: errno=Connection timed out

error: Cannot fetch meta-fsl-arm-extra

error: Exited sync due to fetch errors
$

I've got http_proxy and https_proxy set to my proxy server, and I've also run "git config --global --set http.proxy ....
Anyone have a clue what I'm missing here?
Thanks in advance,
Ed
edsut
 
Posts: 31
Joined: Thu Sep 11, 2014 5:12 pm

Re: what would cause repo sync to fail?

Postby edsut » Fri Oct 03, 2014 8:00 pm

I believe I can answer my own question now...
For repo sync to work through a proxy, do the following:
Got this from https://groups.google.com/forum/#!topic ... v1no9Ssk9o,
I'm repeating it here just in case that page goes stale...

1. Create a script as follows:
(replace YOUR_PROXY and YOUR_PROXY_PORT appropriately)

Code: Select all
#! /bin/bash
(echo "CONNECT $1:$2 HTTP/1.0"; echo; cat) | socket YOUR_PROXY YOUR_PROXY_PORT | (read a; read a; cat)


2. Export GIT_PROXY_COMMAND with full path to that script:
(replace FULL_PATH_TO_SCRIPT with full path)

Code: Select all
export GIT_PROXY_COMMAND=FULL_PATH_TO_SCRIPT/proxy-cmd.sh


Then (at least in my case) I was able to run "repo sync".
Note, depending on your system, you may also need to install 'socket'...

Code: Select all
sudo apt-get install socket
edsut
 
Posts: 31
Joined: Thu Sep 11, 2014 5:12 pm


Return to Software - Yocto

Who is online

Users browsing this forum: No registered users and 3 guests