Google Kubernates: sphinxsearch not working











up vote
0
down vote

favorite












I'm trying to make a cluster with google Kubernetes.



I need to use sphinxsearch and create a dynamic solution to increase VMs by load usage.



My Docker file is:



FROM centos:latest

COPY sources/boot.sh /boot.sh
COPY sources/sphinx.conf /sphinx.conf
COPY sources/*******.json /******.json

RUN yum -y update && yum install -y wget mysql-devel &&
wget https://dl.google.com/cloudsql/cloud_sql_proxy.linux.amd64 -O /cloud_sql_proxy &&
chmod +x cloud_sql_proxy && chmod +x boot.sh

EXPOSE 9312
EXPOSE 9306

ENTRYPOINT ./boot.sh


My boot.sh is:



#!/usr/bin/env bash

ldconfig

nohup /cloud_sql_proxy -instances=my_istance_tcp:3306 -credential_file=/my_file.json &

wget http://sphinxsearch.com/files/sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
tar -zxvf sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
mv sphinx-3.0.3/bin/* /usr/bin/
mkdir -p /var/log/sphinxsearch
touch /var/log/sphinxsearch/searchd.log && touch /var/log/sphinxsearch/query.log
mkdir -p /var/lib/sphinxsearch/data
indexer --rotate --all --config sphinx.conf
searchd --config sphinx.conf --nodetach


On my pc with docker run I can connect to 127.0.0.1:9312/9306, but when I deploy it to my cluster I receive:



telnet 104.19.****** 9312
Trying 104.19.******...
telnet: connect to address 104.19.******: Connection refused
telnet: Unable to connect to remote host


YAML file:



apiVersion: v1
kind: Service
metadata:
creationTimestamp: 2018-11-08T16:28:45Z
labels:
app: nginx-1
name: nginx-1-service
namespace: default
resourceVersion: "722"
selfLink: /api/v1/namespaces/default/services/nginx-1-service
uid: 5d3e48b8-e373-11e8-9c04-42010a80030e
spec:
clusterIP: 10.51.*****
externalTrafficPolicy: Cluster
ports:
- name: 9312-to-9312-tcp
nodePort: 30249
port: 9312
protocol: TCP
targetPort: 9312
- name: 9306-to-9306-tcp
nodePort: 32527
port: 9306
protocol: TCP
targetPort: 9306
selector:
app: nginx-1
sessionAffinity: None
type: LoadBalancer
status:
loadBalancer:
ingress:
- ip: 104.19.**********


Can you help me?



Thank you!










share|improve this question
























  • Are your pods running? Is the healthcheck on the load balancer showing healthy? what's the output of kubectl get ep?
    – Rico
    Nov 9 at 2:19















up vote
0
down vote

favorite












I'm trying to make a cluster with google Kubernetes.



I need to use sphinxsearch and create a dynamic solution to increase VMs by load usage.



My Docker file is:



FROM centos:latest

COPY sources/boot.sh /boot.sh
COPY sources/sphinx.conf /sphinx.conf
COPY sources/*******.json /******.json

RUN yum -y update && yum install -y wget mysql-devel &&
wget https://dl.google.com/cloudsql/cloud_sql_proxy.linux.amd64 -O /cloud_sql_proxy &&
chmod +x cloud_sql_proxy && chmod +x boot.sh

EXPOSE 9312
EXPOSE 9306

ENTRYPOINT ./boot.sh


My boot.sh is:



#!/usr/bin/env bash

ldconfig

nohup /cloud_sql_proxy -instances=my_istance_tcp:3306 -credential_file=/my_file.json &

wget http://sphinxsearch.com/files/sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
tar -zxvf sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
mv sphinx-3.0.3/bin/* /usr/bin/
mkdir -p /var/log/sphinxsearch
touch /var/log/sphinxsearch/searchd.log && touch /var/log/sphinxsearch/query.log
mkdir -p /var/lib/sphinxsearch/data
indexer --rotate --all --config sphinx.conf
searchd --config sphinx.conf --nodetach


On my pc with docker run I can connect to 127.0.0.1:9312/9306, but when I deploy it to my cluster I receive:



telnet 104.19.****** 9312
Trying 104.19.******...
telnet: connect to address 104.19.******: Connection refused
telnet: Unable to connect to remote host


YAML file:



apiVersion: v1
kind: Service
metadata:
creationTimestamp: 2018-11-08T16:28:45Z
labels:
app: nginx-1
name: nginx-1-service
namespace: default
resourceVersion: "722"
selfLink: /api/v1/namespaces/default/services/nginx-1-service
uid: 5d3e48b8-e373-11e8-9c04-42010a80030e
spec:
clusterIP: 10.51.*****
externalTrafficPolicy: Cluster
ports:
- name: 9312-to-9312-tcp
nodePort: 30249
port: 9312
protocol: TCP
targetPort: 9312
- name: 9306-to-9306-tcp
nodePort: 32527
port: 9306
protocol: TCP
targetPort: 9306
selector:
app: nginx-1
sessionAffinity: None
type: LoadBalancer
status:
loadBalancer:
ingress:
- ip: 104.19.**********


Can you help me?



Thank you!










share|improve this question
























  • Are your pods running? Is the healthcheck on the load balancer showing healthy? what's the output of kubectl get ep?
    – Rico
    Nov 9 at 2:19













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I'm trying to make a cluster with google Kubernetes.



I need to use sphinxsearch and create a dynamic solution to increase VMs by load usage.



My Docker file is:



FROM centos:latest

COPY sources/boot.sh /boot.sh
COPY sources/sphinx.conf /sphinx.conf
COPY sources/*******.json /******.json

RUN yum -y update && yum install -y wget mysql-devel &&
wget https://dl.google.com/cloudsql/cloud_sql_proxy.linux.amd64 -O /cloud_sql_proxy &&
chmod +x cloud_sql_proxy && chmod +x boot.sh

EXPOSE 9312
EXPOSE 9306

ENTRYPOINT ./boot.sh


My boot.sh is:



#!/usr/bin/env bash

ldconfig

nohup /cloud_sql_proxy -instances=my_istance_tcp:3306 -credential_file=/my_file.json &

wget http://sphinxsearch.com/files/sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
tar -zxvf sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
mv sphinx-3.0.3/bin/* /usr/bin/
mkdir -p /var/log/sphinxsearch
touch /var/log/sphinxsearch/searchd.log && touch /var/log/sphinxsearch/query.log
mkdir -p /var/lib/sphinxsearch/data
indexer --rotate --all --config sphinx.conf
searchd --config sphinx.conf --nodetach


On my pc with docker run I can connect to 127.0.0.1:9312/9306, but when I deploy it to my cluster I receive:



telnet 104.19.****** 9312
Trying 104.19.******...
telnet: connect to address 104.19.******: Connection refused
telnet: Unable to connect to remote host


YAML file:



apiVersion: v1
kind: Service
metadata:
creationTimestamp: 2018-11-08T16:28:45Z
labels:
app: nginx-1
name: nginx-1-service
namespace: default
resourceVersion: "722"
selfLink: /api/v1/namespaces/default/services/nginx-1-service
uid: 5d3e48b8-e373-11e8-9c04-42010a80030e
spec:
clusterIP: 10.51.*****
externalTrafficPolicy: Cluster
ports:
- name: 9312-to-9312-tcp
nodePort: 30249
port: 9312
protocol: TCP
targetPort: 9312
- name: 9306-to-9306-tcp
nodePort: 32527
port: 9306
protocol: TCP
targetPort: 9306
selector:
app: nginx-1
sessionAffinity: None
type: LoadBalancer
status:
loadBalancer:
ingress:
- ip: 104.19.**********


Can you help me?



Thank you!










share|improve this question















I'm trying to make a cluster with google Kubernetes.



I need to use sphinxsearch and create a dynamic solution to increase VMs by load usage.



My Docker file is:



FROM centos:latest

COPY sources/boot.sh /boot.sh
COPY sources/sphinx.conf /sphinx.conf
COPY sources/*******.json /******.json

RUN yum -y update && yum install -y wget mysql-devel &&
wget https://dl.google.com/cloudsql/cloud_sql_proxy.linux.amd64 -O /cloud_sql_proxy &&
chmod +x cloud_sql_proxy && chmod +x boot.sh

EXPOSE 9312
EXPOSE 9306

ENTRYPOINT ./boot.sh


My boot.sh is:



#!/usr/bin/env bash

ldconfig

nohup /cloud_sql_proxy -instances=my_istance_tcp:3306 -credential_file=/my_file.json &

wget http://sphinxsearch.com/files/sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
tar -zxvf sphinx-3.0.3-facc3fb-linux-amd64-glibc2.12.tar.gz
mv sphinx-3.0.3/bin/* /usr/bin/
mkdir -p /var/log/sphinxsearch
touch /var/log/sphinxsearch/searchd.log && touch /var/log/sphinxsearch/query.log
mkdir -p /var/lib/sphinxsearch/data
indexer --rotate --all --config sphinx.conf
searchd --config sphinx.conf --nodetach


On my pc with docker run I can connect to 127.0.0.1:9312/9306, but when I deploy it to my cluster I receive:



telnet 104.19.****** 9312
Trying 104.19.******...
telnet: connect to address 104.19.******: Connection refused
telnet: Unable to connect to remote host


YAML file:



apiVersion: v1
kind: Service
metadata:
creationTimestamp: 2018-11-08T16:28:45Z
labels:
app: nginx-1
name: nginx-1-service
namespace: default
resourceVersion: "722"
selfLink: /api/v1/namespaces/default/services/nginx-1-service
uid: 5d3e48b8-e373-11e8-9c04-42010a80030e
spec:
clusterIP: 10.51.*****
externalTrafficPolicy: Cluster
ports:
- name: 9312-to-9312-tcp
nodePort: 30249
port: 9312
protocol: TCP
targetPort: 9312
- name: 9306-to-9306-tcp
nodePort: 32527
port: 9306
protocol: TCP
targetPort: 9306
selector:
app: nginx-1
sessionAffinity: None
type: LoadBalancer
status:
loadBalancer:
ingress:
- ip: 104.19.**********


Can you help me?



Thank you!







kubernetes google-cloud-platform cluster-computing sphinx






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 9 at 2:11









Rico

23.7k94864




23.7k94864










asked Nov 8 at 16:52









Fabio

132




132












  • Are your pods running? Is the healthcheck on the load balancer showing healthy? what's the output of kubectl get ep?
    – Rico
    Nov 9 at 2:19


















  • Are your pods running? Is the healthcheck on the load balancer showing healthy? what's the output of kubectl get ep?
    – Rico
    Nov 9 at 2:19
















Are your pods running? Is the healthcheck on the load balancer showing healthy? what's the output of kubectl get ep?
– Rico
Nov 9 at 2:19




Are your pods running? Is the healthcheck on the load balancer showing healthy? what's the output of kubectl get ep?
– Rico
Nov 9 at 2:19

















active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53212505%2fgoogle-kubernates-sphinxsearch-not-working%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes
















 

draft saved


draft discarded



















































 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53212505%2fgoogle-kubernates-sphinxsearch-not-working%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

How to pass form data using jquery Ajax to insert data in database?

National Museum of Racing and Hall of Fame

Guess what letter conforming each word