You are not logged in.

#1 2008-08-09 13:31:07

sidc
Member
Registered: 2008-06-19
Posts: 76

ABS through proxy

I have searched through the forums for a way to use the abs through a proxy, but haven't found any solution so far. Is this even possible? I get the following error when i try to update my tree.

msid ~  $  sudo abs
==> Starting ABS sync...
rsync: getaddrinfo: rsync.archlinux.org 873: Temporary failure in name resolution
rsync error: error in socket IO (code 10) at clientserver.c(122) [receiver=3.0.3]

Does abs use rsync to update the tree? How do i configure the proxy setting for abs to work? (In pacman, I was able to use aria2 's proxy capabilities to get through)

Offline

#2 2008-08-09 13:36:48

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,604

Re: ABS through proxy

Yes, abs uses rsync. Have a look at the rsync man page, there should be something there.

Offline

#3 2008-08-09 14:39:22

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 3,682

Re: ABS through proxy

Set the env variable RSYNC_PROXY to the proxy address/port.

Online

#4 2008-08-09 15:14:50

sidc
Member
Registered: 2008-06-19
Posts: 76

Re: ABS through proxy

I tried it, but it doesn't work . Is the format like RSYNC_PROXY="http://username:password@proxy.com:portnumber" ?

Offline

#5 2008-08-09 15:27:17

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 3,682

Re: ABS through proxy

I think so. The proxy needs to accept connections on port 873.

You might also try using rsync over ssh, if I'm not mistaken.

Online

#6 2008-08-09 15:30:12

sidc
Member
Registered: 2008-06-19
Posts: 76

Re: ABS through proxy

I am behind a college proxy. It accepts connections over 3128. Is there any way to get around this?

I think I should use some sort of tunneling because 3128 is probably the only port open. I was able to get ssh to tunnel through, but how exactly do I do this with rsync? Can I make rsync use a ssh protocol? If so, will abs be also able to use it? ( Cause abs and rsync do not accept the same arguments and the only thing they share in common is the configuration file probably)

Last edited by sidc (2008-08-09 16:37:51)

Offline

#7 2008-08-09 17:02:19

sidc
Member
Registered: 2008-06-19
Posts: 76

Re: ABS through proxy

I was able to use abs through ssh tunneling, but now I have a new problem sad . It asks me for a root password when i try to update my abs tree.

root /home/msid #  abs
==> Starting ABS sync...
root@rsync.archlinux.org's password:

Any ideas on how to get around this?

Last edited by sidc (2008-08-10 14:11:47)

Offline

#8 2008-08-11 15:35:00

sidc
Member
Registered: 2008-06-19
Posts: 76

Re: ABS through proxy

bump

Offline

#9 2008-08-11 15:37:47

Allan
Developer
From: Brisbane, AU
Registered: 2007-06-09
Posts: 9,939
Website

Re: ABS through proxy

How exactly are you trying to ssh tunnel.  It doesn't seem to have worked right...

Offline

#10 2008-08-11 16:38:23

sidc
Member
Registered: 2008-06-19
Posts: 76

Re: ABS through proxy

By using the corkscrew application . I put the following in the ~/.ssh/config

Host *
ProxyCommand /usr/local/bin/corkscrew bsnlproxy.iitk.ac.in 3128 %h %p ~/.ssh/myauth

and I put the username and password for the proxy in the myauth file.

Offline

#11 2008-09-21 03:27:29

TheAmigo
Member
Registered: 2008-04-08
Posts: 59

Re: ABS through proxy

That's not exactly what corkscrew does.  Corkscrew lets you tunnel ssh through an http proxy server... but then you've got ssh trying to connect to an ssh server outside your proxy.  In your example, ssh was then trying to login to rsync.archlinux.org which is why it asked you for the password there.

In order to get abs (or rsync in general) to work through a proxy, you need an ssh server on the outside sad

This is what I have to do to get abs to work from the office:

~/.ssh/config:

ProxyCommand /usr/bin/corkscrew proxyserver.corp.com:1080 %h %p

Then start an ssh session that will tunnel the rsync port:

ssh -l homeuser -p 443 -L 873:rsync.archlinux.org:873 homeserver.org

Now I have localhost port 873 tunneled through ssh which is in turn using corkscrew to tunnel through an http connection through the proxy server.  The "-p 443" is a further complication that I have (you don't have this trouble because you got a password prompt):  my corp's proxy server won't let me connect to anything other than 80 or 443... so I have to run sshd on 443 at home.  Luckily, the proxy server can't tell corkscrew's tunnel apart from an https connection.

Editing /etc/abs.conf, I change the SYNCSERVER to localhost.  Then when I run abs, everything syncs up just fine.  Of course, this is all dependent on having an external ssh server that allows remote port forwarding (e.g. other than just tcp tunnels to itself).

Offline

Board footer

Powered by FluxBB