마이그레이션 계획 만들기: Kf CLI입니다.
설치 안내는 Kf CLI 설치를 참조하세요.
마이그레이션 계획 적용: Kf가 실행되는 GKE 클러스터입니다.
설치 안내는 Kf 설치를 참조하세요.
Cloud Foundry가 설치된 클러스터에 대한 액세스 권한
CF Foundation(기반)을 타겟팅한 CF CLI
위에서 다룬, 원하는 마이그레이션 범위에 필요한 CF Foundation(기반)에 대한 권한
마이그레이션 계획 만들기
kf migrate plan 명령어를 사용하여 마이그레이션 계획을 만듭니다.
기본적으로 이 명령어는 마이그레이션 계획을 표준 출력에 씁니다. 일반적으로 yaml 파일로 출력을 리디렉션하여 적용 전에 계획을 맞춤설정할 수 있습니다.
예를 들어 다음 명령어는 출력을 표준 출력에 씁니다.
kf migrate plan
출력을 yaml 파일로 리디렉션합니다.
kf migrate plan > plan.yaml
kf migrate plan 명령어를 실행하면 아래 양식의 명령어 창에 명령어로 수행된 단계와 경고 또는 마이그레이션 문제가 나열된 출력이 표시됩니다.
kf migrate plan > plan.yaml
Checking CF CLI is available
Checking CF CLI is authenticated
...
WARNING: plan has issues
Issues with domain "apps.internal" in space "kf-team-acceptance":
E04 - internal domains are not supported
Issues with application "spring-music" in space "kf-team-app":
E14 - app manifest must have a single process
Issues with service instance "logspinner-1" in space "kf-team-app":
E10 - syslog drain configuration is not supported
...
마이그레이션 계획 생성
CF CLI를 사용하여 CF Foundation(기반)에 로그인했는지 확인합니다.
원하는 마이그레이션 범위를 기준으로 마이그레이션을 수행합니다. 각 항목의 의미는 다음과 같습니다.
MY_ORG는 Organization(조직)의 이름을 지정합니다.
MY_SPACE는 Space(공간)의 이름을 지정합니다.
MY_APP은 App(앱) 이름을 지정합니다.
전체 CF Foundation(기반)의 마이그레이션 계획을 생성합니다.
kf migrate plan > plan.yaml
Organization(조직)의 마이그레이션 계획을 생성합니다.
kf migrate plan --cf-org MY_ORG > plan.yaml
Space(공간)의 마이그레이션 계획을 생성합니다.
kf migrate plan --cf-org MY_ORG --cf-space MY_SPACE > plan.yaml
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-09-04(UTC)"],[],[],null,["# Assess and migrate Cloud Foundry\n\nThis document describes how to perform an assessment of your existing\nCloud Foundry (CF) Foundation, and how to migrate the CF Foundation,\nOrganization, Space, or App to Kf.\n\nMigration fit assessment\n------------------------\n\nUse the [`kf migrate scan-cf-cluster`](/migrate/kf/docs/2.9/cli/kf-migrate-scan-cf-cluster) command\nto generate a report containing an assessment of the migration readiness of a CF Foundation.\nYou can format the report as a spreadsheet (recommended) or text file.\n| **Note:** The report does not contain all the information retrieved from the CF API. Instead, it targets specific pieces of data that can be used to estimate portability to Kubernetes.\n\n### Prerequisites\n\n- The Kf CLI. See [Install Kf CLI](/migrate/kf/docs/2.9/install-cli) for the installation instructions.\n- The [`cf` CLI](https://docs.cloudfoundry.org/cf-cli/install-go-cli.html) intalled as `cf`.\n- The `cf` CLI must be on your path.\n- The `cf` CLI must be authenticated with [admin read-only privileges](https://docs.cloudfoundry.org/uaa/uaa-user-management.html#admin-read-only) or higher on the CF Foundation.\n\n### Perform an assessment\n\n1. Validate the Foundation to be targeted.\n\n ```\n cf curl /v2/info\n ```\n2. Run the command to generate a spreadsheet containing the assessment report.\n\n **Note:** The assessment is run locally on your workstation using the Kf CLI, and no data is sent to Google. \n\n ```\n kf migrate scan-cf-cluster report.xlsx\n ```\n3. Review the assessment.\n\n If you plan to share the assessment, you can redact any\n information that you do not want to share.\n\nMigration\n---------\n\nPerform the following steps to migrate entities from CF:\n\n1. **Create migration plan** that describes the migration.\n\n2. **Edit the migration plan** to customize your migration.\n\n3. **Apply the migration plan** to perform the migration.\n\nThe following sections describe these steps in more detail.\n\n### Migration scopes\n\nYour first decision when performing a migration is to decide on the migration *scope*.\nThe scope determines the CF entity you want to migrate and the privileges you\nneed to perform the migration:\n\n- **Entire Foundation or Organization** : You must have [admin read-only privileges](https://docs.cloudfoundry.org/uaa/uaa-user-management.html#admin-read-only) or higher on the CF Foundation.\n\n- **Single Space or App** : You must have [Space Developer privileges](https://docs.cloudfoundry.org/concepts/roles.html#roles) or higher.\n\n | **Note:** If you have `scim.read` and `cloud_controller.admin_read_only` scopes, you can also query all Apps across all Spaces in an Organization.\n\n### Prerequisites\n\nTo perform a migration, you require:\n\n- **To create the migration plan** : The Kf CLI. See [Install Kf CLI](/migrate/kf/docs/2.9/install-cli) for the installation instructions.\n- **To apply the migration plan** : A GKE cluster running Kf. See [Install Kf](/migrate/kf/docs/2.9/install) for the installation instructions.\n- Access to a cluster with a Cloud Foundry installation.\n- CF CLI that has targeted the CF Foundation.\n- The privileges on the CF Foundation required by your desired migration scope, as shown above.\n\n### Create a migration plan\n\nUse the `kf migrate plan` command to create the migration plan.\n\nBy default, the command writes the migration plan to standard out. You typically redirect\nthe output to a yaml file so that you can customize the plan before applying it.\nFor example, the following command writes the output to standard out: \n\n```\nkf migrate plan\n```\n\nRedirect the output to a yaml file: \n\n```\nkf migrate plan \u003e plan.yaml\n```\n\nWhen you run the `kf migrate plan` command, you should see output in the command window\nin the form below listing the steps performed by the command and any warning or migration issues: \n\n```\nkf migrate plan \u003e plan.yaml\n\n Checking CF CLI is available\n Checking CF CLI is authenticated\n ...\n\n WARNING: plan has issues\n Issues with domain \"apps.internal\" in space \"kf-team-acceptance\":\n E04 - internal domains are not supported\n\n Issues with application \"spring-music\" in space \"kf-team-app\":\n E14 - app manifest must have a single process\n\n Issues with service instance \"logspinner-1\" in space \"kf-team-app\":\n E10 - syslog drain configuration is not supported\n ...\n```\n\n#### Generate a migration plan\n\n1. Ensure that you have logged in to your CF Foundation by using the CF CLI.\n\n2. Perform the migration based on your desired migration scope, where:\n\n - \u003cvar translate=\"no\"\u003eMY_ORG\u003c/var\u003e specifies the name of the Organization.\n - \u003cvar translate=\"no\"\u003eMY_SPACE\u003c/var\u003e specifies the name of the Space.\n - \u003cvar translate=\"no\"\u003eMY_APP\u003c/var\u003e specifies the name of the App.\n\n 1. Generate a migration plan for an entire CF Foundation.\n\n ```\n kf migrate plan \u003e plan.yaml\n ```\n 2. Generate a migration plan for an Org.\n\n ```\n kf migrate plan --cf-org MY_ORG \u003e plan.yaml\n ```\n 3. Generate a migration plan for a Space\n\n ```\n kf migrate plan --cf-org MY_ORG --cf-space MY_SPACE \u003e plan.yaml\n ```\n 4. Generate a migration plan for an App.\n\n ```\n kf migrate plan --cf-org MY_ORG --cf-space MY_SPACE --cf-app MY_APP \u003e plan.yaml\n ```\n\nIf you see the following error after running any of these commands: \n\n You are not authorized to perform the requested action CF-NotAuthorized 10003\n\nYou do not have required privileges to read the necessary CAPI endpoints.\n\n### Edit the migration plan\n\nReview and optionally modify the generated migration plan to resolve any errors.\n\n### Apply the migration plan\n\nUse the `kf migrate apply` command to apply the migration plan and migrate the\nCF entity:\n\n1. Ensure that you have set `.kubeconfig` to target your Kf cluster.\n\n2. Ensure that you have access to a GKE cluster running a full\n Kf installation. That means you have run the following\n command to connect to the cluster:\n\n ```\n gcloud container clusters get-credentials CLUSTER_NAME \\\n --project=CLUSTER_PROJECT_ID \\\n --zone=CLUSTER_LOCATION\n ```\n3. Ensure that there are no existing Space names on your Kf cluster\n that will collide with a Space referenced in the migration plan.\n\n Space names are of the form \u003cvar translate=\"no\"\u003ecf-org\u003c/var\u003e-\u003cvar translate=\"no\"\u003ecf-space\u003c/var\u003e. For example,\n if the Org name is `myorg` and the Space name is `myspace`, then the\n Kf space will be `myorg-myspace`.\n4. Apply the migration plan.\n\n ```\n kf migrate apply -v --plan plan.yaml\n ```\n\n The verbose flag `-v` is recommended but not required. This flag causes the command\n to output the Kf commands used to perform the migration.\n | **Note:** You might see errors from the apply step. For example, `E04 - internal domains are not supported`. In some situations, you can ignore these errors by specifying the `--allow-issues` flag. Alternatively, you can edit the migration plan to address the error."]]