Score:0

Salt: connection refused to proxy

es flag

I have troubles with Salt, installed on an HPC cluster. All maintenance commands (i.e. salt commands) are made from master0. The minions to be managed are named node0, node1, ..., node4. When I try to install a package on a minion (let's say python's numpy on node0), I get the following error:

[root@master0 ~]# salt 'node0' pkg.install python3-numpy
  *duplicate lines removed*
https://vault.centos.org/7.8.2003/os/x86_64/repodata/repomd.xml: [Errno 14] curl#7 - "Failed connect to master0:3142; Connection refused"

On node0, file /etc/yum.conf looks like this:

[main]
exclude=ibutils-libs*
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=5
bugtracker_url=http://bugs.centos.org/set_project.php?project_id=23&ref=http://bugs.centos.org/bug_report_page.php?category=yum
distroverpkg=centos-release
proxy=http://master0:3142

As far as I understand, node0 does not manage to connect to master0 through port 3142. Indeed, I can curl master0 on default port (80 I guess), but not on 3142:

[root@node0 ~]# curl 'http://master0:3142'
curl: (7) Failed connect to master0:3142; Connection refused
[root@node0 ~]# curl 'http://master0'
<!DOCTYPE html>
<html>
  *Some HTML stuff, not relevant here*
</body>
</html>

But I don't get where I am supposed to open this port on master0.

Note: Complete newbie here. To be honest, I don't get the point of passing through this port either, but the whole HPC structure was built by an external service provider, and I just try to handle all this stuff by my own.

Score:1
in flag

If you don't use a proxy, just remove the proxy= line from your yum.conf.

Alternatively, start your proxy server.

3142 is the default port of apt-cacher, which is used for Debian based distributions, but can also be used to cache RPM packages.

Your config indicates that it used to run on master0 (or you skipped steps you deemed irrelevant when following a tutorial).

Dorian avatar
es flag
This ridiculously works! I feel a little dumb now... What's the purpose of using a proxy here?
Dorian avatar
es flag
Actually, I though the proxy was mandatory because all traffic from minions pass through ``master0``, as evidenced by ``[root@node0 ~]# traceroute google.fr`` for example.
in flag
The purpose of the proxy is that not every node needs to download the package from the official mirror, but from a local mirror (the proxy) instead.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.