ELK Stack: view Kibana in remote machine - amazon-web-services

I configured ELK stack in ec2 Ubuntu,18.04 LTS instance-aws. I configured elasticsearch, logstash & finally kibana in Ubuntu instance and started those with no issues. My question is, once I started kibana, have to view the kibana dashboard in my desktop(windows 7 machine) browser. But, always getting "This site can’t be reached" message. Please find the below commands for detail.
Completed the installation & configuration of elasticsearch, logstash in Ubuntu,18.04 LTS instance-aws without errors.
Now for kibana I installed using,
sudo apt-get install kibana
removed the comments of below lines from "/etc/kibana/kibana.yml"
server.port: 5601
server.host: "localhost"
elasticsearch.url: "http://localhost:9200"
then started the service using,
sudo service kibana start
then hit the url the http://YOUR_ELASTIC_IP:5601 in my windows browser and given the 'aws ubuntu instance - IPv4 Public IP' for 'YOUR_ELASTIC_IP'.
Anyone can help me to view the kibana from my windows machine which is installed in ec2 ubuntu instance...

Might be a security group issue, make sure that port(5601) is open for your ip address

Related

Is there any way to get the DNS address of an instance of an aws ubuntu server if I do not have the login to the aws account, but the SSH key for it

I got a task to deploy a static website on an AWS Ubuntu Server, I was given the username and the SSH key for it. Using PuTTy I got access to the server, setup django, postgres nginx and gunicorn. However now I need to check the progress and whichever tutorial I looked up, I found them checking their deployment progress with a dns address, but since I have connected to the server remotely, I do not have that. So please help me check my deployment status. I am attaching some screenshots of the PuTTy terminal below
Image of the final Gunicorn command to finish the deployment

Unable to install anything on AWS ubuntu

I thought of migrating my php application from shared hosting to AWS. however i'm facing some difficult while installing packages, whenever i try to install a package it saying connecting to some xyz server and halts, the installation does not proceed. I followed below steps
1.) I created amazon AWS free tier account
2.) I created a security group policy
3.) I generated a elastic IP from the pool
4.) I created an AWS ec2 instance using Ubuntu x64 v16 (Did all the setup and was fine)
5.) Generated the .pem key and downloaded it, also connected via SSH using the key, i'm able to connect
6.) I then associated the Elastic IP to the instance and restarted the instance
whenever i try to connect to the public IP address it says server took too long to respond or is not accessible. I thought might be i need to install Apache
I'm trying to install Apache, also not only Apache even if i run sudo update && upgrade it just shows a message connecting to server and hangs up!
What my be the problem? Where did i go wrong?

Jenkins Error 503 on AWS EC2 Instance

I have created an AWS Ec2 instance using the following documentation:
https://d0.awsstatic.com/Projects/P5505030/aws-project_Jenkins-build-server.pdf
However, when I get to the stage where I connect from my web browser to Jenkins using http://:8080 I get HTTP Error: 503.
I originally taught it was down to my network settings/security group settings on my AWS EC2 instance but I have installed Apache and I can access the Apache test page from port 80. I have allowed traffic from HTTP, SSH and TCP and set the appropriate ports as per the guide.
I have tried curl http://localhost:8080 on the putty instance connected to my EC2 instance and I get the same error. Also, I have checked the /var/lib/jenkins folder and it is empty.
Any help or direction in the right path would be greatly appreciated,
Thank you.
If anyone runs into this problem in the future, the documentation installs the latest version of Jenkins.
I installed an older, stable Jenkins version and this worked perfectly using the "sudo yum install jenkins-2.47-1.1"
The problem is resolved by installing Java 8.
https://issues.jenkins-ci.org/browse/JENKINS-43609

How to setup an own Kibana client over aws ES service

I deployed an ES service 5.1 over AWS. The access policy is restricted to a unique IP. This public IP belongs to a EC2 instance (red hat).
At the EC2 instance, I installed kibana 5.1.2 using yum and I configured the kibana.yml as follows:
server.host: "ec2-x-x-x-x.us-west-2.compute.amazonaws.com"
server.name: "my-kibana"
elasticsearch.url: "http://my-es-domain-xxxxxxxxxxxx.us-west-2.es.amazonaws.com"
The rest config remains untouched.
With the EC2 instance I can do cURL requests over my ES with no problem (I had created an index, add some documents and search). But Kibana is giving me this error:
ui settings Elasticsearch plugin is red
plugin:kibana#5.1.2 Ready
plugin:elasticsearch#5.1.2 Request Timeout after 3000ms
plugin:console#5.1.2 Ready
plugin:timelion#5.1.2 Ready
So I can't use my Kibana client. Can you tell what's missing?
Thanks.
When you configure kibana with
elasticsearch.url: "http://my-es-domain-xxxxxxxxxxxx.us-west-2.es.amazonaws.com‌​"
it always look for es running on 9200 port by default.
If you are running es on 80 port then explicitly mention that in configuration
like this:
elasticsearch.url: "http://my-es-domain-xxxxxxxxxxxx.us-west-2.es.amazonaws.com‌​:80"
You can read more about this setting here
elasticsearch.url:
Default: "http://localhost:9200" The URL of the Elasticsearch instance
to use for all your queries.
I had this problem locally, too. Elasticsearch and Kibana on local Debian 8 system. Although telnet/curl for localhost:9200 worked, I had to enable it in iptables
iptables -A INPUT -p tcp --dport 9200 -j ACCEPT
Maybe this helps someone else, too.

How to run sonatype nexus on aws ec2?

I need to put sonatype nexus3 up on AWS. Following an old tutorial for nexus 2, I was led to try this on EC2. What I'm currently trying is an instance with a security group that allows inbound requests from anywhere on ports 80,8080,22,4000,443, and 8081. I'm using a Amazon Linux AMI 2016.09.0 (HVM), SSD Volume Type instance. I install docker using the instructions from here http://docs.aws.amazon.com/AmazonECS/latest/developerguide/docker-basics.html#install_docker. I then simply use the official docker image from here https://hub.docker.com/r/sonatype/nexus3/ with the following command.
docker run -d -p 8081:8081 --name nexus sonatype/nexus3
Using docker ps I can confirm that this seems to be running. When I try to connect to the provided public DNS url ending with amazonaws.com on port 8081, I simply get connection refused. Same thing on port 80 or any of the other ports and the same thing when I add /nexus to the end of the URL.
Attempting the quick test that documentation for this image suggests:
>curl -u admin:admin123 http://localhost:8081/service/metrics/ping
curl: (56) Recv failure: Connection reset by peer
Using the exact same docker command on my local machine (OS X) I am able to access nexus on localhost. Why can't I get this working?
The issue appears to have been with Sonatype's official image. This image which works the exact same way, works perfectly with the exact same process.