No basic authentication on windows using elasticsearch jetty plugin - elasticsearch

I installed Jetty plugin with the below command on windows8
"bin/plugin -url https://s3.amazonaws.com/www.emergi.net/elasticsearch/plugins/elasticsearch-jetty-1.0.0.zip -install elasticsearch-jetty-1.0.0"
It installed successfully and add the realm.properties file in "elasticsearch-1.0.0/config" directory.
"realm.properties" file looks like
user: pwd,readwrite
I added the below lines in "elasticsearch.yml" file
http.type: com.sonian.elasticsearch.http.jetty.JettyHttpServerTransportModule
sonian.elasticsearch.http.jetty:
config: jetty.xml,jetty-hash-auth.xml,jetty-restrict-writes.xml
I restarted the elasticsearch with "elasticsearch.bat" command.
When I put -XPUT,-XPOST or -XDELETE command, it doesnt provide any authentication.
Can anyone tel me what i missed?
I followed the same procedure in linux.It works.
Thanks in advance.

Related

Jolokia - where is jolokia-access.xml?

I recently started to use Jolokia (on Weblogic server on a Windows VM) and it was fine (i.e. I could access to http://:/jolokia/version). However, after setting up credentials for an user, I find that I couldn't access to http://:/jolokia/version and it returned 403 Forbidden error. After reading through this page (https://jolokia.org/reference/html/security.html), the issue seems related to jolokia-access.xml. I tried to find it on server (Windows VM) but failed. I also tried to search for it online but couldn't find it either.
Could you please let me know where the file is? If I need to create the file, where (i.e. path) should I put it?
Thanks!
this file is there in this path:
c:<ACTIVEMQ_DIR>\webapps\api\WEB-INF\classes\jolokia-access.xml
Try to find in the conf directory in the activemq installation directory:
c:\<ACTIVEMQ_DIR>\conf\jolokia-access.xml

install weblogic on console mode without xming

I'm trying to install weblogic server on Centos 7 with following instruction of oracle about console mode. Everything will be fine till weblogic file 's extracting on my computer. I get this message about
display enviroment variable failed
I google it and found xming as solution. But is there any solution to install weblogic without xming.
You need to do a silent install as mentioned. You can find the documentation here.
Basically, you need two files:
A response file
Here, you will set some parameters like ORACLE_HOME, proxy information if needed and installation type, etc.
An oraInst.loc file
In this file, you need to do the following(from documentation):
Replace oui_inventory_directory with the full path to the directory where you want the installer to create the inventory directory. Then, replace oui_install_group with the name of the group whose members have write permissions to this directory.
After doing all of this, you can run the command as follows;
java -jar distribution_name.jar -silent -responseFile file [-options] [()*]
I uploaded my own oraInst.loc and response files here for demonstration. I strongly suggest you to read the documentation though. Good luck.

ldap commands not recognized in windows command prompt

I am attempting to setup an LDAP server.
I installed ApacheDS and I was going through the user guide. I am trying to change the default admin password. I know I can use the Apache Directory Studio to do this, but I am required to use the command line to setup and maintain the LDAP server I create.
I found this
and it helped by showing how to use an ldif file to modify the default password.
However when I run
ldapmodify -h localhost -p 10389 -D "uid=admin,ou=system" -f conf-modify.ldif
I get the message:
'ldapmodify' is not recognized as an internal or external command, operable program or batch file.
Is there an LDAP package for windows command line tools or is there a specific directory that the ldap command must be executed from in ApacheDS
I am currently running the command from the ApacheDS install directory C:\Program Files\ApacheDS
I have been using OpenDJ and their tools. You do not need to run the LDAP server to be able to run their LDAP tools.
Runs on any(?) Java 7 or greater platform.
Open any cmd prompt and add add this command
set path=%path%;E:\Softwares\OpenLDAP\bin
and after that run your command
ldapmodify -h localhost -p 10389 -D "uid=admin,ou=system" -f conf-modify.ldif
I Hope it helps you.,
An old article, perhaps still useful for ApacheDS users.
if you have found your bin folder with dsadm.exe usw.,
then you will find your ldapsearch.exe in a parallel folder.
dsee7:
*---bin
| dsadm.exe
|
*---dsrk
+---bin
ldapsearch.exe
ldapmodify.exe
WARNING:
call pls.
ldapmodify -h
In order to see the difference between openldap and ApacheDS.
It is not working with openldap syntax.
Have a fun with experimenting. (rulez Shadows)
Hint you will see the same syntax in suchlogs in your Apache Directory Browser

Elasticsearch 1.5 can't find the plugin manager

I'm currently trying to install the JDBC river on an 1.5 elasticsearch instance.
When running:
/bin/plugin --install jdbc --url http://xbib.org/repository/org/xbib/elasticsearch/plugin/elasticsearch-river-jdbc/1.5.0.0/elasticsearch-river-jdbc-1.5.0.0.zip
I obtain the following error:
Error: Could not find or load main class org.elasticsearch.plugins.PluginManager
Do you have any idea of the origin of the problem?
EDIT: I tried
bin/plugin
And get the same error, so it's not related to the url.
EDIT2: I'm using Windows.
The url http://xbib.org/repository/org/xbib/elasticsearch/plugin/elasticsearch-river-jdbc/1.5.0.0/elasticsearch-river-jdbc-1.5.0.0.zip is incorrect.
If you check the url http://xbib.org/repository/org/xbib/elasticsearch/plugin/elasticsearch-river-jdbc/1.5.0.0/ in your browser, you will see there is no elasticsearch-river-jdbc-1.5.0.0.zip file there. There is however a jar file of the same name. Perhaps you meant to use that one instead?
./bin/plugin --install river-jdbc --url http://xbib.org/repository/org/xbib/elasticsearch/plugin/elasticsearch-river-jdbc/1.5.0.4/elasticsearch-river-jdbc-1.5.0.4.jar

SonarQube Proxy Configuration, Tricky

I cannot get the proxy configuration to work for SonarQube 4.0 so that I can install plugins.
When i open http://localhost:9000/updatecenter/available it displays the error: "Not connected to update center. Please check your internet connection and logs."
In sonar.log I read: "org.sonar.api.utils.HttpDownloader$HttpException: Fail to download [http://update.sonarsource.org/update-center.properties]. Response code: 403"
In sonar.properties I configured it with the same proxy which I use for other programs:
sonar.updatecenter.activate=true
http.proxyHost=<host>
http.proxyPort=<port>
http.proxyUser=<username>
http.proxyPassword=<password>
I tried the same to configure in wrapper.properties, but it didn't work either by the way.
For the proxy host I tried the short and the full name. For the username I tried just the username and with <DOMAINNAME>\<username> and <DOMAINNAME>\\<username>.
Nothing of it worked. Any ideas?
My proxy configuration works and looks the following way:
http.proxyHost=proxy.domain.de
http.proxyPort=8888
Note that there is no "http://" or anything else before the URL.
Also, I do not use proxy authentication, so I left "proxyUser" and "proxyPassword" commented out.
For those running SonarQube in Docker, I had no luck with any suggestion mentioned here. But I found following solution that worked for me (here):
docker run -d sonarqube -Dhttp.proxyHost=<myproxy.url.com> -Dhttp.proxyPort=<port>
and equivalent of this in a docker-compose notation:
services:
sonarqube:
image: sonarqube
command: -Dhttp.proxyHost=<myproxy.url.com> -Dhttp.proxyPort=<port>
Just an information: I had this problem also.
I can see the PlugIns but cannot download it. The problem is, you have to add this line into your sonar.properties, for the https:
# https-proxy
sonar.web.javaAdditionalOpts=-Dhttps.proxyHost=xxxxx -Dhttps.proxyPort=xxxx -Dhttps.proxyUser=xxxx -Dhttps.proxyPassword=xxxx
I used the official documentation and it works:
Using the Update Center behind a Proxy
http.proxyHost=<your.proxy.host>
http.proxyPort=<yout.proxy.port>
Regards,
At sonar.properties set the proxy without "http://", only http.proxyHost=myproxy.domain.pt
Another suggestion is to also add this lines on wrapper.conf:
wrapper.java.additional.3=-Dhttp.proxySet=true
wrapper.java.additional.4=-Dhttp.proxyHost=myproxy.domain.pt
wrapper.java.additional.5=-Dhttp.proxyPort=myproxy.port
wrapper.java.additional.6=-Dhttps.proxyHost=myproxy.domain.pt
wrapper.java.additional.7=-Dhttps.proxyPort=myproxy.port
Careful if you have a docker volume, remove it before deploy the new one with this configuration, or otherwise it will keep the original configuration
Appart from http, don't forget to set your https proxy configuration in sonar.properties (update server is behind HTTPS):
https.proxyHost=<host>
https.proxyPort=<port>
https.proxyUser=<username>
https.proxyPassword=<password>

Resources