Steps to help with downloading a copy of a deployed application droplet hosted Cloud Foundry and using it to update the CF stack from cflinuxfs3 to cflinuxfs4.
This guide provides step by step instructions how to:
These steps are helpful if the original application source code is no longer available to make an application update and the application stack needs to be updated. E.g., cflinuxfs3 to cflinuxfs4.
The following example will show how to update your application stack from the deprecated Cloud Foundry stack cflinuxfs3 to cflinuxfs4 without the original source code.
cf app <APP_NAME>
and you will see similar output:C:\> cf app <APP_NAME>
Showing health and status for app <APP_NAME> in org <ORG_NAME> / space <SPACE_NAME> as user@company.com...
name: <APP_NAME>
requested state: started
routes: appname.apps.eu1.mindsphere.io
last uploaded: Tue 12 Oct 09:16:25 PDT 2021
stack: cflinuxfs3
buildpacks:
name version detect output buildpack name
php_buildpack 4.4.41 php php
type: web
sidecars:
instances: 1/1
memory usage: 128M
state since cpu memory disk details
#0 running 2024-04-29T16:37:12Z 0.5% 28.2M of 128M 234.6M of 512M
cf create-app-manifest <APP_NAME>
and you will see similar output:C:\> cf create-app-manifest <APP_NAME>
Creating an app manifest from current settings of app <APP_NAME> in org <ORG_NAME> / space <SPACE_NAME> as user@company.com...
Manifest file created successfully at C:\<APP_NAME>_manifest.yml
OK
<APP_NAME>_manifest.yml
cf download-droplet <APP_NAME>
and you will see similar output:C:\> cf download-droplet <APP_NAME>
Downloading current droplet for app <APP_NAME> in org <ORG_NAME> / space <SPACE_NAME> as user@scompany.com...
Droplet downloaded successfully at C:\droplet_5569e13d-3e2d-4e73-a409-ae0c0000e621.tgz
OK
droplet_5569e13d-3e2d-4e73-a409-ae0c0000e621.tgz
droplet_5569e13d-3e2d-4e73-a409-ae0c0000e621.tar
cf push <APP_NAME> --droplet <DROPLET_NAME> -s cflinuxfs4
and the output will be similar:C:\> cf push <APP_NAME> --droplet droplet_5569e13d-3e2d-4e73-a409-ae0c0000e621.tgz -s cflinuxfs4
Pushing app <APP_NAME> to org <ORG_NAME> / space <SPACE_NAME> as user@company.com...
Uploading droplet bits...
89.36 MiB / 89.36 MiB [===================================================================================] 100.00% 1m16s
Waiting for API to complete processing files...
Waiting for app <APP_NAME> to start...
Instances starting...
Instances starting...
name: <APP_NAME>
requested state: started
routes: appname.apps.eu1.mindsphere.io
last uploaded: Mon 29 Apr 11:51:33 PDT 2024
stack: cflinuxfs4
buildpacks:
name version detect output buildpack name
php_buildpack 4.6.17 php php
type: web
sidecars:
instances: 1/1
memory usage: 32M
state since cpu memory disk details
#0 running 2024-04-29T18:52:13Z 0.6% 19.2M of 32M 482.4M of 600M
cf app <APP_NAME>
to check as well.
Q: If your app fails to start after updating from cfliunxfs3 to cflinuxfs4. Example:
name: <APP_NAME>
requested state: started
routes: appname.apps.eu1.mindsphere.io
last uploaded: Mon 29 Apr 11:46:48 PDT 2024
stack:
buildpacks:
type: web
sidecars:
instances: 0/1
memory usage: 32M
state since cpu memory disk details
#0 crashed 2024-04-29T18:49:46Z 0.0% 6.9M of 32M 282.7M of 1G
Start unsuccessful
TIP: use 'cf.exe logs <APP_NAME> --recent' for more information
FAILED
A: Check the application logs with the command cf logs <APP_NAME> --recent
for clues to why the application is not starting. Here are some suggestions that may be helpful:
cf restage <APP_NAME>
to rebuild your application with the latest configuration and buildpack.
cf scale <APP_NAME> -k <MEMORY_SIZE>M or <MEMORY_SIZE>G
cf scale <APP_NAME> -m <DISK_SPACE>M or
<DISK_SPACE>G
See Scaling vertically section of Cloud Foundry documentation.
cf push <APP_NAME> --droplet <DROPLET_NAME> -s cflinuxfs3
to push an old version to Cloud Foundry.
cf cancel-deployment <APP_NAME>
to cancel an existing deployment.
Sign in to your CF organization Retrieve list of users and their roles for the space Switch org and space Switch space See all applications in a space See health, status, stacks details of an application Retrieve the most recent application logs See all application droplets and there guids Cancel an in-progress deployment Set the amount of disk space of an existing application Set the amount of memory allocated to an application Push a droplet to CF and use the CF stack cflinuxfs4 Rebuild an app with current configuration and buildpack | cf login -a https://api.cf.eu1.mindsphere.io --sso cf space-users <ORG_NAME> <SPACE_NAME> cf target -o <ORG_NAME> -s <SPACE_NAME> cf apps cf app <APP_NAME> cf droplets <APP_NAME> cf cancel-deployment <APP_NAME> cf scale <APP_NAME> -k 1G cf scale <APP_NAME> -m 512M cf push <APP_NAME> --droplet <DROPLET_NAME> -s cflinuxfs4 cf restage <APP_NAME> |