Support Questions
Find answers, ask questions, and share your expertise

Iot Demo View Not Working 404 Error

I have installed as per the documentation. Also i have done the port forwarding to 8081.

when i access the view from the URL http://sandbox.hortonworks.com:8081/storm-demo-web-app/ not able to see the html page

Response from chrome:-

GET http://sandbox.hortonworks.com:8081/storm-demo-web-app/ net::ERR_CONNECTION_RESET

Output of Curl

[root@sandbox storm-demo-webapp]# curl http://172.17.0.2:8081/storm-demo-app/index.html

<title>Error 404 </title>

HTTP ERROR: 404

Problem accessing /storm-demo-app/index.html. Reason:

    Not Found

Powered by Jetty:// 9.3.11.v20160721
[root@sandbox storm-demo-webapp]#

Kindly guide me to proceed further.

5 REPLIES 5

Super Mentor

@Subramaniyam KMV

Have you build the project and started it as following?


mvn clean package
mvn jetty:run -Djetty.port=8081

. Please verify if the port is opened for listening?

netstat -tnlpa | grep 8081

. Please make sure that you have unblocked port 8081 on your virtualbox as described in the following link: https://community.hortonworks.com/articles/65914/how-to-add-ports-to-the-hdp-25-virtualbox-sandbox.h...

.

I have build using the following

VERSION=`hdp-select status hadoop-client | sed 's/hadoop-client - \([0-9]\.[0-9]\).*/\1/'`
sudo git clone https://github.com/hortonworks-gallery/iotdemo-service.git   /var/lib/ambari-server/resources/stacks/HDP/$VERSION/services/IOTDEMO   

#(Optional) Zeppelin already comes installed on HDP 2.4 sandbox
#sudo git clone https://github.com/hortonworks-gallery/ambari-zeppelin-service.git   /var/lib/ambari-server/resources/stacks/HDP/$VERSION/services/ZEPPELIN   

#on sandbox
sudo service ambari restart

Port Forwarding --> 8091 is given

Port is working. please see the output

netstat -tnlpa | grep 8081 tcp 0 0 :::8081 :::* LISTEN 9289/java

[root@sandbox target]#

Super Mentor

@Subramaniyam KMV

Good that the port 8081 is actually opened. So now in order to access that port outside the VM (sandbox) you should add that port in the Virtual Machine N/W configuration as mentioned in the following image. (From previously shared link)

https://community.hortonworks.com/storage/attachments/9337-virtualbox-9.png

Port Forwarding for port 8081 need to be enabled.

Hi JaySenSharma,

Now i'am able to launch the IOT Demo UI, but i'm facing the Websocket error as attached.

Can you tell me what could be wrong ??

iot-demo-websocket-error.png

Regards

Subramaniyam.KMV

Super Mentor

@Subramaniyam KMV

Usually it is best practice to have one thread dedicated to one specific query so that the thread becomes more beneficial for the readers.

As your original issue is resolved by Port Forwarding ennoblement to 8081 hence i will suggest you to please mark this thread as Answered (Accepted) and open a new thread for the websocket issue.