Comments (19)
from openwhisk.
suspect the router failed in your vagrant machine.
$ docker ps | grep nginx
if that returns nothing
$ ls -l /tmp | grep nginx
if that shows that nginx is owned by root, remove it.
$ sudo rm -rf /tmp/nginx/
then ant clean build deploy
and try again - the deploy step when it installs the standard assets in the final step (installCatalog
), should report no errors ([exec] open catalog ERRORS = 0
).
# this should now show a running container
$ docker ps | grep nginx
from openwhisk.
docker ps | grep nginx
returned nothing
ls -l /tmp | grep nginx
also returned nothing. I confirmed that no nginx files were in /tmp or a subfolder
docker images
lists several images.
I have logged out of the VM and executed vagrant reload
.
Anything else before I ant clean build deploy
?
from openwhisk.
I completely tore down the Vagrant box (vagrant destroy
+ vagrant box remove ubuntu/trusty64-2
) and then reinstalled from scratch following the steps in the Build and deploy OpenWhisk
section.
I can successfully create a new subject usingwskadmin
and can set the apihost
property on the command line with no errors.
However, when I attempt to run the sample action, I am still getting connection refused:
wsk --verbose action invoke /whisk.system/samples/echo -p message hello --blocking --result
{'apihost': '192.168.33.13:443', 'namespace': '_', 'clibuild': '2016-02-28T19:03:52-05:00', 'apiversion': 'v1'}
========
REQUEST:
POST https://192.168.33.13:443/api/v1/namespaces/whisk.system/actions/samples/echo?blocking=true
Headers sent:
{
"Authorization": "Basic ...",
"Content-Type": "application/json"
}
Body sent:
{"message": "hello"}
error: [Errno 111] Connection refused
docker ps
shows no results at all. No running containers.
ls -lah /tmp
does not show any nginx folders at all.
Not sure how to proceed.
Thanks for looking.
from openwhisk.
Could you run 'ant clean build deploy >& /tmp/x' and attach /tmp/x here?
from openwhisk.
note: scrub the file for any cloudant passwords.
from openwhisk.
Will do. Back in an hour.
from openwhisk.
If it helps - this is the output of docker ps
inside a clean vagrant machine I just created. So there was a failure in your case to either build or deploy. The logs will helps us diagnose what went wrong and improve the process. Thanks for your help and patience.
$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
87a6405b714e whisk/dispatcher:latest "/startDispatcher.sh " 4 minutes ago Up 4 minutes 0.0.0.0:12001->8080/tcp invoker0
cf1f1d0ed79a whisk/loadbalancer:latest "/startLoadBalancer.s" 4 minutes ago Up 4 minutes 0.0.0.0:10003->8080/tcp loadbalancer
cfd15f5e26e3 whisk/dispatcher:latest "/startDispatcher.sh " 4 minutes ago Up 4 minutes 0.0.0.0:12000->8080/tcp activator
c5e96cc52cb1 whisk/controller:latest "/startController.sh" 4 minutes ago Up 4 minutes 0.0.0.0:10001->8080/tcp controller
e7d9ad87eeae gliderlabs/registrator "/bin/registrator -ip" 4 minutes ago Up 4 minutes registrator
f85bf6923075 whisk/consul:latest "/startconsulserver.s" 4 minutes ago Up 4 minutes 8000/tcp, 53/udp, 8080/tcp, 8301-8302/tcp, 8301-8302/udp, 8400/tcp, 0.0.0.0:8500->8500/tcp, 0.0.0.0:8600->53/tcp consulserver
6298c63f8a03 whisk/kafka:latest "/start.sh" 5 minutes ago Up 5 minutes 7203/tcp, 0.0.0.0:9092->9092/tcp, 0.0.0.0:9093->8080/tcp kafka
5ef6a2fcff67 whisk/zookeeper:latest "/opt/zookeeper/bin/z" 5 minutes ago Up 5 minutes 2888/tcp, 3888/tcp, 8080/tcp, 0.0.0.0:2181->2181/tcp zookeeper
212271a5a939 nginx "nginx -g 'daemon off" 5 minutes ago Up 5 minutes 0.0.0.0:80->80/tcp, 0.0.0.0:443->443/tcp, 0.0.0.0:8443->8443/tcp
from openwhisk.
Attached.
Running the sample action now produces a different result:
wsk -v action invoke /whisk.system/samples/echo -p message hello --blocking --result
{'apihost': '192.168.33.13:443', 'namespace': '_', 'clibuild': '2016-02-28T20:51:47-05:00', 'apiversion': 'v1'}
========
REQUEST:
POST https://192.168.33.13:443/api/v1/namespaces/whisk.system/actions/samples/echo?blocking=true
Headers sent:
{
"Authorization": "Basic ...",
"Content-Type": "application/json"
}
Body sent:
{"message": "hello"}
--------
RESPONSE:
Got response with code 502
Body received:
<html>
<head><title>502 Bad Gateway</title></head>
<body bgcolor="white">
<center><h1>502 Bad Gateway</h1></center>
<hr><center>nginx/1.9.11</center>
</body>
</html>
========
error: connection failed or timed out
Results of docker ps
docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
dc4bac9de51f 19cb05bc7dbd "/startDispatcher.sh " 58 minutes ago Up 58 minutes 0.0.0.0:12001->8080/tcp invoker0
38dfbc98c30e aa18164df72d "/startLoadBalancer.s" 58 minutes ago Up 58 minutes 0.0.0.0:10003->8080/tcp loadbalancer
2f399fef8a52 19cb05bc7dbd "/startDispatcher.sh " 58 minutes ago Up 58 minutes 0.0.0.0:12000->8080/tcp activator
d3a59e3788bc cdc281a58aa6 "/startController.sh" 58 minutes ago Up 58 minutes 0.0.0.0:10001->8080/tcp controller
af9ec87c23e0 gliderlabs/registrator "/bin/registrator -ip" 58 minutes ago Up 58 minutes registrator
8d85b47cbcf4 whisk/consul:latest "/startconsulserver.s" 58 minutes ago Up 58 minutes 8000/tcp, 8080/tcp, 53/udp, 8301-8302/tcp, 8301-8302/udp, 8400/tcp, 0.0.0.0:8500->8500/tcp, 0.0.0.0:8600->53/tcp consulserver
f21efa06ec14 whisk/kafka:latest "/start.sh" 59 minutes ago Up 59 minutes 7203/tcp, 0.0.0.0:9092->9092/tcp, 0.0.0.0:9093->8080/tcp kafka
3e1156e8b626 whisk/zookeeper:latest "/opt/zookeeper/bin/z" 59 minutes ago Up 59 minutes 2888/tcp, 3888/tcp, 0.0.0.0:2181->2181/tcp, 8080/tcp zookeeper
e3d3fc9c9be1 nginx "nginx -g 'daemon off" 59 minutes ago Up 59 minutes 0.0.0.0:80->80/tcp, 0.0.0.0:443->443/tcp, 0.0.0.0:8443->8443/tcp nginx
from openwhisk.
The log you attached shows the controller failed to start up: "controller is not responding." And this would explain the bad gateway failure.
How much RAM does your Mac have?
from openwhisk.
8Gb. Approx 1.5Gb free. The vagrant VM is using 3.75Gb
from openwhisk.
try manually restarting the controller only:
docker rm -f controller
ant -f openwhisk/core/controller/build.xml startController
then run wsk list
it should respond with
$ wsk list
entities in namespace: default
packages
actions
triggers
rules
from openwhisk.
If the previous works, I suggest this ant clean build deploy -Dbuildthreads=1
.
from openwhisk.
That worked.
@rabbah is the suggestion to specify the number of buildThreads something that I need to do now or just if I have to rebuild again in the future?
from openwhisk.
I'm suspecting that the parallel builds and deploys are stressing the vm and the containers are slow to come up and respond. If with 1 build thread you're able to reliably bring up and deploy the system, you can create a custom config file that overrides the parameter so you don't have to type it regularly. I will post instructions here once you confirm that improves your build/deploy cycle.
from openwhisk.
OK, I'll kick that off shortly and capture the output.
from openwhisk.
With the single thread option specified (e.g. ant clean build deploy -Dbuildthreads=1
) , the entire build process completed successfully and correctly deployed the sample actions.
For reference, I was using a mid-2012 Macbook Air with 8Gb RAM and a 500Gb SSD drive.
The failure to deploy the proxy (nginx container) caused the authentication error shown in the subject line.
from openwhisk.
I'll address the nginx build/deploy robustness in issue #32.
from openwhisk.
I get a connection refused error.
However, the containers are all there. Comparing to a properly running version, only a couchdb container is missing for me, but I'm using Cloudant, so that's the reason it's missing.
from openwhisk.
Related Issues (20)
- failure to deploy rules even if trigger is fired. whiskdeploy issue
- Some questions about Invoker. HOT 1
- [Problem] XXX_THE_END_OF_A_WHISK_ACTIVATION_XXX HOT 3
- Discussion about memory overflow of openwhisk function HOT 1
- Questions about the duration of function calls limited by the nginx gateway HOT 18
- Action failure when the function takes a long time to execute
- Memory leak in `akka.actor.LocalActorRef` HOT 14
- Multi-runtime tests keep failing HOT 5
- waht' is the rule of autoscaler HOT 1
- Error while trying to run `ansible-playbook -i environments/$ENVIRONMENT routemgmt.yml` HOT 2
- use Apache Pekko instead of Akka HOT 2
- Missed config keys on Scala 2.13.x
- Invocation-level fault tolerance guarantees HOT 6
- GPU support for OpenWhisk Actions HOT 1
- OpenWhisk Releases HOT 3
- AkkaContainerClient breaks the ConcurrentTests of nodejs runtime HOT 2
- Deployment Components HOT 5
- The openwhisk is incompatible with java version higher than 16
- Web function 400 Bad Request HOT 1
- Package-installer-pod not-completed on Minikube
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openwhisk.