Page 1 of 1

Salix update problem behind firewall/proxy

Posted: 15. May 2014, 14:00
by nano
Hi, I'm triyng to update salix xfce 14.1 just installed, PC is behind a firewall/proxy.
After installation I can surf on Internet without problem (= network settings are ok).
To make update possibile, as standard user I've issued:

export HTTP_PROXY=http://10.41.10.252:8080

then I've checked it has been accepted:
export | grep http

which gives as result:

declare -x HTTP_PROXY="http://10.41.10.252:8080"

Then I issue (from xfce menù) Gslapt, it asks for root password and show me a panel with ALL options grayed.

I've cheched which package site-source are set:
http://salix.mirror.garr.it/mirrors/sal ... 4.1/extra/
http://salix.mirror.garr.it/mirrors/sal ... ware-14.1/
http://salix.mirror.garr.it/mirrors/salix/x86_64/14.1/

I can access to all of them via browser.

If I press update button appears progress windows but after several hours there is no progress.


At this point I've tried to update via command line:

sudo slapt-get -u
Password:
Recupero i dati dei pacchetti [http://salix.mirror.garr.it/mirrors/sal ... ware-14.1/]...Errore nel download: Couldn't connect to server
Recupero i dati dei pacchetti [http://salix.mirror.garr.it/mirrors/sal ... 4.1/extra/]...Errore nel download: Couldn't connect to server
....


I can assure that several slackware 13.37-14.0 and 14.1 installatio are perfecly working from the same office and with similar network settings so i suppose is something about salix proxy/firewall management or something about .

any help?
Thank in advantage

Nano

Re: Salix update problem behind firewall/proxy

Posted: 15. May 2014, 18:01
by gapan
It should be http_proxy, not HTTP_PROXY.

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 09:25
by nano
Thank Gapan for suggestion, but no success unfortunately...

As suggested I issued
export http_proxy="http://10.41.10.252:8080/"
and checked (as before) with
export | grep http

it answered with
declare -x http_proxy="http://10.41.10.252:8080/"

Then I issued
sudo slapt-get -u
Password:
Recupero i dati dei pacchetti [http://salix.mirror.garr.it/mirrors/sal ... ware-14.1/]...

But nothing to do, it wait forever

I tried another solution, I selected a small file on the repository and tested if connection was reachable with wget:

wget http://salix.mirror.garr.it/mirrors/sal ... README.TXT

--2014-05-16 10:55:35-- http://salix.mirror.garr.it/mirrors/sal ... README.TXT
Risoluzione di salix.mirror.garr.it (salix.mirror.garr.it)... 193.206.140.34, 2001:760:ffff:b0::34
Connessione a salix.mirror.garr.it (salix.mirror.garr.it)|193.206.140.34|:80... fallito: Connessione scaduta.
Connessione a salix.mirror.garr.it (salix.mirror.garr.it)|2001:760:ffff:b0::34|:80... fallito: La rete non è raggiungibile.

fallito: Connessione scaduta = Failed: connection timeout
fallito: La rete non è raggiungibile. = Failed: network not reachable

Then I tried:

ping 193.206.140.34
PING 193.206.140.34 (193.206.140.34) 56(84) bytes of data.
64 bytes from 193.206.140.34: icmp_seq=1 ttl=49 time=109 ms
64 bytes from 193.206.140.34: icmp_seq=2 ttl=49 time=58.5 ms
64 bytes from 193.206.140.34: icmp_seq=3 ttl=49 time=68.1 ms
64 bytes from 193.206.140.34: icmp_seq=4 ttl=49 time=92.6 ms
^C
--- 193.206.140.34 ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3004ms
rtt min/avg/max/mdev = 58.569/82.210/109.509/20.066 ms

Moreover I can browse every file from repository with Midori....

What's wrong?
It seems (my hypotesis) that export http_proxy will affected only standard user, not propagating to root.

Any ideas?

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 09:46
by gapan

Code: Select all

sudo -i
export http_proxy="http://10.41.10.252:8080/"
slapt-get -u

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 10:55
by nano
Thank, from command line it works!

installation updated

last question: how can I manage same situation with Gslapt?
Shall i enable root to login directly (no sudo or su)?

Thank

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 12:24
by gapan
You can add a new script in /etc/profile.d that exports http_proxy. That way it will work for all users, all the time, including root. Don't forget to make it executable.

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 13:35
by nano
Thank Gapan for help

I created in /etc/profile.d/ following file: export_proxy.sh

it contains:
cat export_proxy.sh

#!/bin/sh
export http_proxy="http://10.41.10.252:8080/"

made it executable for everybody:
-rwxr-xr-x 1 root root 136 mag 16 14:45 export_proxy.sh*

but execution of Gslapt still hangs when conctating repository...

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 14:36
by sjox
Hy!

Look in "/usr/share/applications/gslapt.desktop":
There you see: "gksu /usr/sbin/gslapt" it will not work!
(try to start in terminal too - as root or not)

then try in terminal:
become root and start "/usr/sbin/gslapt", without gksu - it will work!

I think gksu delete "http_proxy"

by

Re: Salix update problem behind firewall/proxy

Posted: 16. May 2014, 14:38
by gapan
Did you restart your session/reboot?

Re: Salix update problem behind firewall/proxy [SOLVED]

Posted: 16. May 2014, 16:39
by nano
Thank for the help both of you, I think the problem is solved even if with a workaround

After several efforts here what I've found about Gslapt.
variable http_proxy is defined for all users, double checked.
PC has been rebooted after every modification

a) If I try to launch Gslapt directly from menu (inserting root password when prompted) connection to repository fails (hangs until timeout).

b) If I open console and became root with sudo -i and THEN launch
/usr/sbin/gslapt, it works:
update button works
As test I've selected and installed firefox and some utilities: worked perfectly.

According to me problem is solved with this workaround.
Do you thin is possible to modify settings in order to make it working in usualk way (from menu I mean) or create a launcher with the right syntax?

Anyway THANK for your prompt support.