Re: Issue with crashing Windows apps on Diego
Aaron Huber
It will totally depend on the app/buildpack. For example, the static file
buildpack and PHP buildpack just launch Nginx and then host the application inside it. As soon as the web server is up it will accept connections so they would work identically to IIS HWC with just a TCP healthcheck. For others the framework would still likely start up and accept connections before the app itself is ready, and again it would be very possible that the app itself would crash the first time you actually hit it but the healthcheck would still think the container is healthy. Again, I'm not arguing that any of that is "good", just that is how the platform is expected to work with a port check and it should work consistently. I also agree that the (annoying) 30-60 second app warmup on .NET makes this even uglier. Assuming you do eventually make the port healthcheck for Windows work by checking the port, it should be made to work. My understanding right now is you do the following (high level): * Spin up the "container" via the app lifecycle (create user, set quota, create FW rules, etc.) * Start up the HWC process * Start running the healthcheck which hits the root of the app and checks for 200-299 with a 1s timeout * Add it to the router once the healthcheck passes What if you did something like this: * Spin up the container * Start up the HWC process * Hit the app once via HTTP as part of the startup to get the app going * Put in a hard coded delay like 30 seconds to give the app time to start (.NET penalty) * Start the healthcheck after the delay * Add it to the router when passing Just brainstorming. :-) Aaron -- View this message in context: http://cf-dev.70369.x6.nabble.com/Issue-with-crashing-Windows-apps-on-Diego-tp3586p3695.html Sent from the CF Dev mailing list archive at Nabble.com. |
|
Re: Issue with crashing Windows apps on Diego
Steven Benario
My understanding is that because the app droplet itself typically includes
toggle quoted message
Show quoted text
the webserver (as opposed to Windows where the server is run by the host), it would be rare for the web server to be available before the app is up and running. On Windows, it would be the common case for the web server to start accepting TCP connections almost immediately, and you could wait a long time before the app is ready. Hence the discrepancy. Thanks for understanding and weighing in. Looking forward to hearing more about how disabling the checks works in your environment -- and of course keep an eye out here for the proposal and updated timeline on the more robust checks. Cheers, Steven On Mon, Feb 8, 2016 at 4:49 PM, aaron_huber <aaron.m.huber(a)intel.com> wrote:
I understand what you're trying to avoid, I just think that is actually the |
|
Re: Issue in deploying Docker images on Cloud Foundry via Diego
Nanduni Nimalsiri
Thank you.
In that case, I am running the 60 days trial version of Pivotal.io. So I have no administrator as I suppose. Can I set my account to get admin privileges or can I set me as an admin? |
|
Re: Issue with crashing Windows apps on Diego
Aaron Huber
I understand what you're trying to avoid, I just think that is actually the
normal case for the port healthchecks. Nothing on the Linux or Docker side ever touches the app so it's entirely possible it will be added to the router without it actually working and that is what I expect the platform to do. Hopefully the more generic HTTP check can be added quickly to all the right places so that we'll at least have more sensible options. Now we just have to decide if we hang onto Iron Foundry that just uses a port check until then, or try to explain to my users that most of their apps won't work unless they turn off the healthcheck. I'm expecting most of them won't RTFM and we'll get constant complaints about how our .NET support is broken because their apps won't start up. Aaron -- View this message in context: http://cf-dev.70369.x6.nabble.com/Issue-with-crashing-Windows-apps-on-Diego-tp3586p3690.html Sent from the CF Dev mailing list archive at Nabble.com. |
|
Re: Auto Mysql Database Creation
Steele, Raymond <raymond.steele@...>
Thanks! The documentation seems to imply that this can only be done if you have a spring application. Is this true?
"Cloud Foundry provides extensive support for connecting a Spring application to services such as MySQL, PostgreSQL, MongoDB, Redis, and RabbitMQ." http://docs.cloudfoundry.org/buildpacks/java/spring-service-bindings.html |
|
Re: Auto Mysql Database Creation
Steele, Raymond <raymond.steele@...>
Thanks! The documentation seems to imply that this can only be done if you have a spring application. Is this true?
"Cloud Foundry provides extensive support for connecting a Spring application to services such as MySQL, PostgreSQL, MongoDB, Redis, and RabbitMQ." http://docs.cloudfoundry.org/buildpacks/java/spring-service-bindings.html |
|
Re: Need help for diego deployment
Amit Kumar Gupta
Hi Kinjal,
toggle quoted message
Show quoted text
Sorry for the delayed response. Are you still hitting compilation timeouts? I cannot access the gist you linked to with the debug output of your failed BOSH task. Amit On Tue, Feb 2, 2016 at 10:50 AM, Kinjal Doshi <kindoshi(a)gmail.com> wrote:
Sorry, for the typo I meant 6868 |
|
Re: - CC configuration in deployment manifest
Amit Kumar Gupta
Hi Kinjal,
toggle quoted message
Show quoted text
You are mixing the minimal deployment instructions with the "standard" deployment instructions. When using the "standard" instructions (where you create a stub), both cf1 and cf2 networks are generally expected to be private, and separate from any subnets you create for BOSH itself. In the minimal setup, I think you create a public and private subnet, I'm not sure what would happen if using the public subnet as your second cf2 subnet? You could try it, but this isn't a combination we test, so I can't make any guarantees. If you do try it, I'd be interested to hear your results. Best, Amit On Tue, Feb 2, 2016 at 12:00 PM, Kinjal Doshi <kindoshi(a)gmail.com> wrote:
Thanks a lot Dieu, that answers my question. |
|
Re: Issue with crashing Windows apps on Diego
Steven Benario
Hi Aaron,
toggle quoted message
Show quoted text
You can track the progress of the story for DiegoWindows here on the public tracker [1]. As it stands, we don't yet have a solution that we could do within the DiegoWindows codebase that wouldn't break existing applications by allowing them to return "healthy" before the app has even started up. I absolutely agree that have an inconsistent pattern between Linux and Windows is something to avoid (and something that is mis-labeled is even worse), but I can totally see how this decision was made originally, and I don't yet have any ideas for something that could fix it in the short term. I think long term, we'd like to see a general healthcheck that looks like some combination or user-selection of: - Process monitoring - Port check - HTTP check (with configuration options previously discussed) ...with some "sane" settings selected by default. For the short term, until we have a strong proposal of what to do to significantly improve the state of the world without breaking existing applications, we will probably not make any changes. Thanks, Steven Benario PM for Windows Support [1] https://www.pivotaltracker.com/story/show/112914163 On Mon, Feb 8, 2016 at 1:21 PM, aaron_huber <aaron.m.huber(a)intel.com> wrote:
Based on this discussion, where are we on the priority of switching the |
|
Re: Issue with crashing Windows apps on Diego
Aaron Huber
Based on this discussion, where are we on the priority of switching the
current "port" check for the Windows lifecycle back to actually be a port check? I get the impression that the changes to support a new HTTP check in the CC, CLI, BBS, etc. will probably take a while so until then I'm hoping we can make the other change a bit quicker. Aaron -- View this message in context: http://cf-dev.70369.x6.nabble.com/Issue-with-crashing-Windows-apps-on-Diego-tp3586p3686.html Sent from the CF Dev mailing list archive at Nabble.com. |
|
CF CAB call for February is this Wednesday Feb. 10th, 2016 @ 8a PDT
Michael Maximilien
Quick reminder of the CAB call this Wednesday, February 10th @ 8a PDT. All info in link:
https://docs.google.com/document/d/1SCOlAquyUmNM-AQnekCOXiwhLs6gveTxAcduvDcW_xI/edit#heading=h.o44xhgvum2we Best, Chip, James, and Max |
|
Re: Issue in deploying Docker images on Cloud Foundry via Diego
Daniel Mikusa
On Mon, Feb 8, 2016 at 4:06 AM, Nanduni Nimalsiri <nandunibw(a)gmail.com>
wrote: I want to deploy a Docker image in cloud Foundry. So I proceeded as below.The administrator for the CF installation you're targeting has disabled docker support. Since you're not an administrator, you cannot turn on this feature. Talk to your administrator and ask him or her to enable it. Dan
|
|
Issue in deploying Docker images on Cloud Foundry via Diego
Nanduni Nimalsiri
I want to deploy a Docker image in cloud Foundry. So I proceeded as below. I am using cf version 6.14.1+dc6adf6-2015-12-22.
$ cf push myimage -o cloudfoundry/lattice-app --no-start Creating app myimage in org nanduni-org / space development as nanduni(a)wso2.com... OK Creating route myimage.cfapps.io... OK Binding myimage.cfapps.io to myimage... OK Then I enabled diego for the app as below. $ cf enable-diego myimage Setting myimage Diego support to true Ok Verifying myimage Diego support is set to true Ok Then I started the application which gave me the following error. $ cf start myimage Starting app myimage in org nanduni-org / space development as nanduni(a)wso2.com... FAILED Server error, status code: 400, error code: 320003, message: Docker support has not been enabled. So how can I resolve the above error. I saw a similar issue in another mail thread. It has been suggested to enable-feature-flag diego_docker. I did so. But it still gives me errors. $ cf enable-feature-flag diego_docker Setting status of diego_docker as nanduni(a)wso2.com... FAILED Server error, status code: 403, error code: 10003, message: You are not authorized to perform the requested action Please let me know some means to deploy docker images in Cloud Foundry. I tried with duglin/cf-docker buildpack as well. But it also gives me this error. 2016/02/08 08:24:28 Exec.out: 2016/02/08 08:24:28 Exec.err: Sending build context to Docker daemon 2016/02/08 08:24:28 Cannot connect to the Docker daemon. Is 'docker -d' running In that case, I have no idea as to what URLs that I should set for DOCKER_HOST and DOCKER_MONITOR. Please help me to solve these two scenarios. Thank you, Nanduni |
|
Re: How to use new "cf ssh" with Rails apps?
Dr Nic Williams <drnicwilliams@...>
Somehow I didn't get Eric's reply so my reply above probably seems odd. Sorry Eric!
On Sun, Feb 7, 2016 at 6:22 PM, Dr Nic Williams <drnicwilliams(a)gmail.com> wrote: Eventually I figured out a (nasty) workaround to manually load the |
|
Re: How to use new "cf ssh" with Rails apps?
Eric Malm <emalm@...>
Hi, Dr Nic,
This issue also came up in the #buildpacks channel in the CF Slack the other day. Until we solve this permanently, a cleaner and more complete workaround seems to be to run `/tmp/lifecycle/launcher "app" "$SHELL" ""` once you start your interactive session. Running the command through the launcher binary will set up HOME and TMPDIR as it does for the app's start command, inject per-instance values into VCAP_APPLICATION, and source the buildpack-provided setup files in /home/vcap/app/.profile.d/*.sh. This technique should also work for running non-interactive commands via cf ssh: instead of `cf ssh APP_NAME -c '<command>'`, try running `cf ssh APP_NAME -c '/tmp/lifecycle/launcher "app" "<command>" ""'`. As far as getting a permanent fix for this environmental setup issue in SSH commands, I've scheduled a new attempt at this in the Diego backlog at https://www.pivotaltracker.com/story/show/113237191, and we intend to get to it soon in a way that doesn't accidentally break Windows apps. Thanks, Eric On Sun, Feb 7, 2016 at 12:22 AM, Dr Nic Williams <drnicwilliams(a)gmail.com> wrote: Eventually I figured out a (nasty) workaround to manually load the |
|
Re: How to use new "cf ssh" with Rails apps?
Dr Nic Williams <drnicwilliams@...>
Eventually I figured out a (nasty) workaround to manually load the
environment: https://blog.starkandwayne.com/2016/02/07/run-one-off-tasks-and-database-migrations/ You need to run the following commands in order to correctly complete the environment to be like a normal container: cd app; HOME=$(pwd) source ~/app/.profile.d/*.sh On Mon, Jan 25, 2016 at 1:32 PM, Dr Nic Williams <drnicwilliams(a)gmail.com> wrote: I'm trying out the new "cf ssh"/Diego with a new Rails app. I'm unsure how -- Dr Nic Williams Stark & Wayne LLC - consultancy for Cloud Foundry users http://drnicwilliams.com http://starkandwayne.com cell +1 (415) 860-2185 twitter @drnic |
|
Re: Upgrading consul-release to consul 0.6.0
Amit Kumar Gupta
+ cf-bosh
toggle quoted message
Show quoted text
Looking for community feedback on bumping consul to 0.6.0 in the consul-release maintained by the core CF team: https://github.com/cloudfoundry-incubator/consul-release. Please see above thread. Thanks, Amit, CF Infrastructure team PM On Wed, Feb 3, 2016 at 8:26 PM, Amit Gupta <agupta(a)pivotal.io> wrote:
Hi Gwenn |
|
Re: ERR Failed to stage application: insufficient resources
Stanley Shen <meteorping@...>
Hello, all
I am running into this issue again. With change cell VM to c3.xlarge(7.5G memory), I have successfully pushed 2 applications to my cf/diego environment. app1 asked 2g memory and app2 asked 3g memory. But it failed to push app3 again for same reason, which asks 3g memory too. I had a look on my cell VM, I do see there are not enough memory for my app3. Tasks: 181 total, 1 running, 175 sleeping, 1 stopped, 4 zombie %Cpu(s): 0.5 us, 25.6 sy, 0.0 ni, 73.6 id, 0.3 wa, 0.0 hi, 0.0 si, 0.0 st KiB Mem: 7658564 total, 7440796 used, 217768 free, 100632 buffers KiB Swap: 7663000 total, 14464 used, 7648536 free. 2427600 cached Mem PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 18303 vcap 10 -10 0 0 0 Z 99.9 0.0 4517:57 ruby 28051 root 10 -10 18516 3516 2716 S 1.0 0.0 47:23.30 destroy.sh 18599 root 10 -10 18520 3496 2692 S 0.7 0.0 47:27.56 destroy.sh 9 root 20 0 0 0 0 S 0.3 0.0 1:39.41 rcuos/0 13306 vcap 10 -10 7560576 2.906g 23652 S 0.3 39.8 19:08.94 java 18552 root 10 -10 18516 3480 2680 S 0.3 0.0 9:28.66 stop.sh 24772 vcap 10 -10 564180 15964 6612 S 0.3 0.2 18:39.04 rep 1 root 20 0 33324 3600 2504 S 0.0 0.0 0:08.31 init 2 root 20 0 0 0 0 S 0.0 0.0 0:00.03 kthreadd 3 root 20 0 0 0 0 S 0.0 0.0 0:05.72 ksoftirqd/0 5 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kworker/0:0H 7 root 20 0 0 0 0 S 0.0 0.0 6:08.60 rcu_sched In my opinion the resource used in staging an application will be released soon after the stage process is done, but from my testing result, it seems it's not true. Can someone give some guide on how to solving this problem? |
|
Re: Richer health-checks for CF apps: request for use cases
Aaron Huber
Just as a reference you could look at some of the connection tests that Monit
allows: https://mmonit.com/monit/documentation/monit.html#CONNECTION-TESTING Obviously there are quite a few there so it might go well beyond what's reasonable for container health checking. I think to meet our use cases the addition of the HTTP check already mentioned would be sufficient but to add to it, I could imagine that it might be useful to be able to specify a regular expression to search for in the returned HTML instead of or in addition to the status code. Also, since you guys are expanding into offer TCP routing for containers, a generic TCP monitor that looked for a specific regular expression in the returned data might be useful, which might also require specifying data to send to trigger a response. Aaron -- View this message in context: http://cf-dev.70369.x6.nabble.com/cf-dev-Richer-health-checks-for-CF-apps-request-for-use-cases-tp3676p3677.html Sent from the CF Dev mailing list archive at Nabble.com. |
|
Richer health-checks for CF apps: request for use cases
Eric Malm <emalm@...>
Dear CF Community,
CF has long had a notion of health-checking app instances as they start up to determine whether they're in a functional state, on top of the process simply having started. On the DEAs, the health-check behavior is coupled to whether the app has routes mapped to it, and for apps targeting the Diego backend, this health-check specification is independent of the routing configuration on the app. On Diego cells, the health check is also run periodically[1] even after the app is started, to verify the health of the instance continually. With that independence, we now would have more flexibility to specify richer health checks for CF app instances. We on the CAPI and Diego teams would like to know what kinds of health checks you would find useful for your apps (either ones serving web traffic, or ones doing background work). The two types of health check currently available are 'port', which checks that a TCP connection can be made to the app instance on the port specified by the PORT env var, and 'none', which despite the name does continually verify that the process invoked in the container is still running. As a starting point, on a recent cf-dev thread[2], we identified that for an HTTP-based health check, it would be useful to specify an endpoint to hit, an acceptable response status code or codes, and a timeout to apply to the request. Sensible defaults could be "/", 200 OK, and 1 second, respectively. In any case, please comment here with your health-check use cases, and we intend to use them as input to a proposal soon. Thanks very much, Eric, CF Runtime Diego PM [1]: https://github.com/cloudfoundry-incubator/diego-design-notes/blob/master/migrating-to-diego.md#health-checks [2]: https://lists.cloudfoundry.org/archives/list/cf-dev(a)lists.cloudfoundry.org/thread/HT7W7UMHR3ZLHV3Q6VJN5URETQUJBVZW/ |
|