Download Plugins Behind Proxy


(Walker) #1

I've been banging my head against a wall trying to figure out where to put what settings to get this to work. Someone please don the Barney costume and walk me through this. Running ELK stack 6.1.1 on a Windows server behind a proxy. When running logstash-plugin install logstash-codec-nmap, I receive the following:

Validating logstash-codec-nmap
Unable to download data from https://rubygems.org - Errno::ECONNREFUSED: Connection refused - Failed to open TCP connect
ion to api.rubygems.org:443 (Connection refused - connect(2) for "api.rubygems.org" port 443) (https://api.rubygems.org/
latest_specs.4.8.gz)
ERROR: Installation aborted, verification failed for logstash-codec-nmap

I've tried adding 4-5 different variations of http_proxy/http_proxyport to the logstash-plugin file, logstash-plugin.bat, ruby file, jvm.options setting environmental options using the set command. I've also tried adding DEBUG=1 to all these files to see what the hell is going on but apparently I've eaten too many paint chips to know where this setting goes or where it's sticking it's debug output file cause I see nothing in the cmd window output and see no new files anywhere.


(Walker) #2

Anybody got anything here?


(Walker) #3

Actually, I found the correct environment variable to add but now I am getting this error:

ERROR: Something went wrong when installing 'plugin name', message: 407 "authenticationrequired"

So I went looking for similar issues with others and that led me to this file with proxy settings:
\LogStash\lib\pluginmanager\settings.xml.erb.

<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
  https://maven.apache.org/xsd/settings-1.0.0.xsd">
  <proxies>
    <% proxies.each_with_index do |proxy, idx| %>
    <proxy>
      <id><%=proxy.host%>.<%=idx%></id>
      <active>true</active>
      <protocol><%=proxy.protocol%></protocol>
      <host><%=proxy.host%></host>
      <port><%=proxy.port%></port>
      <username><%=proxy.username%></username>
      <password><%=proxy.password%></password>
    </proxy>
  <% end %>
  </proxies>
</settings>

Is this what needs to be modified, assuming change the env variables to the necessary ones?


(system) #4

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.