MARKLOGIC引导测试连接到http://localhost:8002 拒绝
使用MarkLogic java api客户端时,我执行boot-test.shMARKLOGIC引导测试连接到http://localhost:8002 拒绝,marklogic,Marklogic,使用MarkLogic java api客户端时,我执行boot-test.sh sh src/test/resources/boot-test.sh 我明白了 线程“main”中出现异常 org.apache.http.conn.HttpHostConnectException:连接到 拒绝 这仅仅是一个身份验证问题吗 我已在中更改了密码 java-client-api/src/main/resources/Example.properties 还有我认为有问题的密码 java-clie
sh src/test/resources/boot-test.sh
我明白了
线程“main”中出现异常
org.apache.http.conn.HttpHostConnectException:连接到
拒绝
这仅仅是一个身份验证问题吗
我已在中更改了密码
java-client-api/src/main/resources/Example.properties
还有我认为有问题的密码
java-client-api/src/test/java/com/marklogic/client/test/util/TestServerBootstrapper.java
虽然我还是被拒绝了。我已确认服务器的管理端口设置为8002
同样,在服务器上运行curl时无法连接到MarkLogic也存在相同的一般问题
curl--anyauth--user admin:xxxx-X PUT-d@./one.xml'-H“内容类型:application/xml”
curl:(7)无法连接到主机
我可以通过8001接口访问服务器,所以我假设这是一些配置错误,但还没有弄清楚。我基本上已经在三台digital ocean centos 6服务器上安装了MarkLogic,更改了管理员密码,建立了一个由三个节点组成的集群,并在每个节点上创建了一个数据库和三个林。否则我相信一切都是默认的
我在centos 6服务器上安装了以下软件
yum -y install glibc.i686 gdb.x86_64 redhat-lsb.x86_64
rpm -i /tmp/MarkLogic-RHEL6-8.0-5.x86_64.rpm
yum install java-1.7.0-openjdk-devel
yum install -y git
yum install -y httpd
service httpd start
yum install -y nano
yum install -y tree
yum install -y wget
wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo
yum install apache-maven
yum update
你知道我做错了什么吗
问候
Conteh以下是迄今为止安装工程的更新版本 引导程序代码执行正确 java客户端api]#sh src/test/resources/boot-test.sh 在8012端口上为java unittest数据库创建了java unittest服务器 用于在端口8012上进行单元测试的引导rest服务器 已安装引导扩展。响应是HTTP/1.1 204创建的[服务器:MarkLogic,内容长度:0,连接:保持活动,保持活动:超时=5] 调用引导扩展。响应为HTTP/1.1 200 OK[服务器:MarkLogic,内容类型:application/xml;字符集=UTF-8,内容长度:468,连接:保持活动,保持活动:超时=5] 谢谢你的帮助
#!/bin/bash
# MarkLogic 8.0-5 Digital Ocean Centos 6.7 64bit
# log everything to a file
exec &> $HOME/stackscript.log
# yum -y: assume yes, -q: quiet
yum -yq update
yum -yq install nano tree wget gcc gcc-c++ make zlib-devel pcre-devel openssl-devel java-1.7.0-openjdk-devel
wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo
yum -yq install apache-maven
yum -yq groupinstall 'Development Tools'
yum -yq install glibc glibc.i686 lsb
curl -o MarkLogic-RHEL6-8.0-5.x86_64.rpm "https://developer.marklogic.com/download/binaries/8.0/MarkLogic-RHEL6-8.0-5.x86_64.rpm?t=5bfgbebCkZ/1KkgggvKp30&email=xxx%40gmail.com"
rpm -iv MarkLogic-RHEL6-8.0-5.x86_64.rpm
#rm MarkLogic-RHEL6-8.0-5.x86_64.rpm
# Set Linux huge pages
echo "vm.nr_hugepages = 292" >> /etc/sysctl.conf
sysctl -p
# Flush all curren
t rules from iptables
iptables -F
#First, we start with blocking null packets
iptables -A INPUT -p tcp --tcp-flags ALL NONE -j DROP
#The next pattern to reject is a syn-flood attack.
iptables -A INPUT -p tcp ! --syn -m state --state NEW -j DROP
#XMAS packets, also a recon packet.
iptables -A INPUT -p tcp --tcp-flags ALL ALL -j DROP
# Set access for localhost
iptables -A INPUT -i lo -j ACCEPT
#Now we can allow web server traffic:
iptables -A INPUT -p tcp -m tcp --dport 80 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 443 -j ACCEPT
#Now, let's allow users use our SMTP servers:
iptables -A INPUT -p tcp -m tcp --dport 25 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 465 -j ACCEPT
# Allow SSH connections on tcp port 22
# This is essential when working on remote servers via SSH to prevent locking yourself out of the system
iptables -A INPUT -p tcp -m tcp --dport 22 -j ACCEPT
#allow us to use outgoing connections (ie. ping from VPS or run software updates);
iptables -I INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A FORWARD -m state --state ESTABLISHED,RELATED -j ACCEPT
# We will block everything else, and allow all outgoing connections.
iptables -P OUTPUT ACCEPT
iptables -P INPUT DROP
# Note eth0 interface
iptables -A INPUT -p tcp -m tcp --dport 7999 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8000 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8001 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8002 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8010 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8012 -j ACCEPT
service iptables save
mkdir -p src && cd src
nginxVersion="1.8.1"
wget http://nginx.org/download/nginx-$nginxVersion.tar.gz
tar -xzf nginx-$nginxVersion.tar.gz
ln -sf nginx-$nginxVersion nginx
cd nginx
./configure \
--user=nginx \
--group=nginx \
--prefix=/etc/nginx \
--sbin-path=/usr/sbin/nginx \
--conf-path=/etc/nginx/nginx.conf \
--pid-path=/var/run/nginx.pid \
--lock-path=/var/run/nginx.lock \
--error-log-path=/var/log/nginx/error.log \
--http-log-path=/var/log/nginx/access.log \
--with-http_gzip_static_module \
--with-http_stub_status_module \
--with-http_ssl_module \
--with-pcre \
--with-file-aio \
--with-http_realip_module \
--without-http_scgi_module \
--without-http_uwsgi_module \
--without-http_fastcgi_module
make
make install
useradd -r nginx
wget -O /etc/init.d/nginx "https://gist.github.com/sairam/5892520/raw/b8195a71e944d46271c8a49f2717f70bcd04bf1a/etc-init.d-nginx"
chmod +x /etc/init.d/nginx
chkconfig --add nginx
chkconfig --level 345 nginx on
#Manually Configure
#nano /etc/nginx/nginx.conf to set types_hash_bucket_size and server_names_hash_bucket_size which needs to be increased.
#http {
# include mime.types;
# default_type application/octet-stream;
# add the below 2 lines under http around line 20
# types_hash_bucket_size 64;
# server_names_hash_bucket_size 128;
#service MarkLogic start
#service nginx start
以下是迄今为止安装工程的更新版本 引导程序代码执行正确 java客户端api]#sh src/test/resources/boot-test.sh 在8012端口上为java unittest数据库创建了java unittest服务器 用于在端口8012上进行单元测试的引导rest服务器 已安装引导扩展。响应是HTTP/1.1 204创建的[服务器:MarkLogic,内容长度:0,连接:保持活动,保持活动:超时=5] 调用引导扩展。响应为HTTP/1.1 200 OK[服务器:MarkLogic,内容类型:application/xml;字符集=UTF-8,内容长度:468,连接:保持活动,保持活动:超时=5] 谢谢你的帮助
#!/bin/bash
# MarkLogic 8.0-5 Digital Ocean Centos 6.7 64bit
# log everything to a file
exec &> $HOME/stackscript.log
# yum -y: assume yes, -q: quiet
yum -yq update
yum -yq install nano tree wget gcc gcc-c++ make zlib-devel pcre-devel openssl-devel java-1.7.0-openjdk-devel
wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo
yum -yq install apache-maven
yum -yq groupinstall 'Development Tools'
yum -yq install glibc glibc.i686 lsb
curl -o MarkLogic-RHEL6-8.0-5.x86_64.rpm "https://developer.marklogic.com/download/binaries/8.0/MarkLogic-RHEL6-8.0-5.x86_64.rpm?t=5bfgbebCkZ/1KkgggvKp30&email=xxx%40gmail.com"
rpm -iv MarkLogic-RHEL6-8.0-5.x86_64.rpm
#rm MarkLogic-RHEL6-8.0-5.x86_64.rpm
# Set Linux huge pages
echo "vm.nr_hugepages = 292" >> /etc/sysctl.conf
sysctl -p
# Flush all curren
t rules from iptables
iptables -F
#First, we start with blocking null packets
iptables -A INPUT -p tcp --tcp-flags ALL NONE -j DROP
#The next pattern to reject is a syn-flood attack.
iptables -A INPUT -p tcp ! --syn -m state --state NEW -j DROP
#XMAS packets, also a recon packet.
iptables -A INPUT -p tcp --tcp-flags ALL ALL -j DROP
# Set access for localhost
iptables -A INPUT -i lo -j ACCEPT
#Now we can allow web server traffic:
iptables -A INPUT -p tcp -m tcp --dport 80 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 443 -j ACCEPT
#Now, let's allow users use our SMTP servers:
iptables -A INPUT -p tcp -m tcp --dport 25 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 465 -j ACCEPT
# Allow SSH connections on tcp port 22
# This is essential when working on remote servers via SSH to prevent locking yourself out of the system
iptables -A INPUT -p tcp -m tcp --dport 22 -j ACCEPT
#allow us to use outgoing connections (ie. ping from VPS or run software updates);
iptables -I INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A FORWARD -m state --state ESTABLISHED,RELATED -j ACCEPT
# We will block everything else, and allow all outgoing connections.
iptables -P OUTPUT ACCEPT
iptables -P INPUT DROP
# Note eth0 interface
iptables -A INPUT -p tcp -m tcp --dport 7999 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8000 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8001 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8002 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8010 -j ACCEPT
iptables -A INPUT -p tcp -m tcp --dport 8012 -j ACCEPT
service iptables save
mkdir -p src && cd src
nginxVersion="1.8.1"
wget http://nginx.org/download/nginx-$nginxVersion.tar.gz
tar -xzf nginx-$nginxVersion.tar.gz
ln -sf nginx-$nginxVersion nginx
cd nginx
./configure \
--user=nginx \
--group=nginx \
--prefix=/etc/nginx \
--sbin-path=/usr/sbin/nginx \
--conf-path=/etc/nginx/nginx.conf \
--pid-path=/var/run/nginx.pid \
--lock-path=/var/run/nginx.lock \
--error-log-path=/var/log/nginx/error.log \
--http-log-path=/var/log/nginx/access.log \
--with-http_gzip_static_module \
--with-http_stub_status_module \
--with-http_ssl_module \
--with-pcre \
--with-file-aio \
--with-http_realip_module \
--without-http_scgi_module \
--without-http_uwsgi_module \
--without-http_fastcgi_module
make
make install
useradd -r nginx
wget -O /etc/init.d/nginx "https://gist.github.com/sairam/5892520/raw/b8195a71e944d46271c8a49f2717f70bcd04bf1a/etc-init.d-nginx"
chmod +x /etc/init.d/nginx
chkconfig --add nginx
chkconfig --level 345 nginx on
#Manually Configure
#nano /etc/nginx/nginx.conf to set types_hash_bucket_size and server_names_hash_bucket_size which needs to be increased.
#http {
# include mime.types;
# default_type application/octet-stream;
# add the below 2 lines under http around line 20
# types_hash_bucket_size 64;
# server_names_hash_bucket_size 128;
#service MarkLogic start
#service nginx start
你说我基本上已经在三台digital ocean centos 6服务器上安装了MarkLogic。你确定你应该访问
localhost
,而不是其他地址吗?你使用的是什么版本的MarkLogic server?@grtjn我正在从安装了一个节点和java代码的服务器上执行curl。我还对域运行了代码,得到了相同的结果。我还从我的机器上本地运行了java,并且有相同的错误。我让java代码在本地机器上运行良好,并使用marklogic 8连接到本地docker容器。03@SamMeffod我正在运行8.05 MarkLogic-RHEL6-8.0-5.x86_64。rpm@SamMefford我还添加了一个安装步骤列表。可能是出了什么问题。你说我基本上已经在三台digital ocean centos 6服务器上安装了MarkLogic
。你确定你应该访问localhost
,而不是其他地址吗?你使用的是什么版本的MarkLogic server?@grtjn我正在从安装了一个节点和java代码的服务器上执行curl。我还对域运行了代码,得到了相同的结果。我还从我的机器上本地运行了java,并且有相同的错误。我让java代码在本地机器上运行良好,并使用marklogic 8连接到本地docker容器。03@SamMeffod我正在运行8.05 MarkLogic-RHEL6-8.0-5.x86_64。rpm@SamMefford我还添加了一个安装步骤列表。也许有什么地方不对劲。顺便说一句,我在java api客户机中运行“mvn测试”时结束的设置让测试运行:111,失败:5,错误:21,跳过:0@SamMefford如果对结果感兴趣,我已经将java客户端api测试的输出附加到以下google站点。我想可能会有兴趣。顺便说一句,我在java api客户端中运行“mvn测试”时完成了该设置,运行测试:111,失败:5,错误:21,跳过:0@SamMefford如果对结果感兴趣,我已经将java客户端api测试的输出附加到以下google站点。我想可能会有兴趣。