Documentation survey

SUSE Manager 서버를 컨테이너화된 환경으로 마이그레이션

1. 요구 사항 및 고려 사항

1.1. 일반

  • SUSE Manager 4.3 서버를 컨테이너로 마이그레이션하려면 SLE Micro 5.5 또는 SUSE Linux Enterprise Server 15 SP6 및 mgradm이 설치된 새 시스템이 필요합니다.

  • 선택한 호스트 운영 체제가 SLE Micro 5.5 또는 SUSE Linux Enterprise Server 15 SP6인지와 상관없이 SUSE Manager 4.3에서 5.0(으)로의 인플레이스 마이그레이션은 지원되지 않습니다.

  • SUSE Manager 4.3에서 5.0(으)로 마이그레이션하기 전에 기존 프록시를 포함한 기존의 모든 기존 클라이언트를 Salt로 마이그레이션해야 합니다.

  • 기존 연락 프로토콜은 SUSE Manager 5.0 이상에서 더 이상 지원되지 않습니다.

이 가이드에서는 SUSE Manager 4.3에서 5.0(으)로의 마이그레이션에 대해서만 다룹니다. 호스트 운영 체제를 SLE Micro 5.5에서 SUSE Linux Enterprise Server 15 SP6(으)로 또는 그 반대로 전환하는 동안 기존 SUSE Manager 5.0 인스턴스를 동일한 버전으로 마이그레이션하는 기능은 mgradm migrate 명령으로 취급되지 않습니다.

1.2. GPG Keys

  • Self trusted GPG keys are not migrated.

  • GPG keys that are trusted in the RPM database only are not migrated. Thus synchronizing channels with spacewalk-repo-sync can fail.

  • 관리자는 실제 서버 마이그레이션을 수행한 후 이러한 키를 4.3 설치에서 컨테이너 호스트로 수동으로 마이그레이션해야 합니다.

    Procedure: Manual Migration of the 4.3 GPG Keys to New Server
    1. 4.3 서버의 키를 새 서버의 컨테이너 호스트로 복사합니다.

    2. 그 후, mgradm gpg add <PATH_TO_KEY_FILE> 명령을 사용하여 마이그레이션된 서버에 각 키를 추가합니다.

2. 마이그레이션

2.1. Prepare SUSE Manager 5.0 Server Host

준비된 SLE Micro 5.5 또는 SUSE Linux Enterprise Server 15 SP6 시스템에 SUSE Manager을 사전 설치하지 마십시오. 마이그레이션 프로세스는 서버 설치를 자동으로 수행하도록 설계되었습니다. mgradm install`을 실행한 후 [command]mgradm migrate`` 명령을 실행하는 기능은 지원되지 않으며, 지원되지 않는 시스템 상태가 됩니다.

다음 단계에서는 호스트 시스템만 준비하며 실제 SUSE Manager 5.0 서버는 설치하지 않습니다.

2.1.1. SLE Micro 5.5 호스트 준비

2.1.1.1. 설치 미디어 다운로드
절차: 설치 미디어 다운로드
  1. https://www.suse.com/download/sle-micro/에서 SLE Micro 5.5 설치 미디어를 찾습니다.

  2. SLE-Micro-5.5-DVD-x86_64-GM-Media1.iso를 다운로드합니다.

  3. 설치하기 위해 다운로드한 .iso 이미지가 들어 있는 DVD 또는 USB 플래시 드라이브를 준비합니다.

2.1.1.2. SLE Micro 5.5 설치

시스템(가상 또는 물리) 준비에 대한 자세한 내용은 SLE Micro 5.5 배포 가이드를 참조하십시오.

절차: SLE Micro 5.5 설치
  1. SLE Micro 5.5의 설치 이미지가 들어 있는 DVD 또는 USB 플래시 드라이브(USB 디스크 또는 키)를 삽입합니다.

  2. 시스템을 부팅하거나 재부팅합니다.

  3. 화살표 키를 사용하여 설치를 선택합니다.

  4. 키보드 및 언어를 조정합니다.

  5. 확인란을 클릭하여 라이선스 계약에 동의합니다.

  6. 다음을 클릭하여 계속합니다.

  7. 등록 방법을 선택합니다. 이 예제에서는 SUSE Customer Center을(를) 사용하여 서버를 등록합니다.

    SUSE Manager 5.0 컨테이너는 확장 프로그램으로 설치됩니다. 아래 목록에서 필요로 하는 특정 확장 프로그램에 따라, 각각에 대해 SUSE Customer Center 등록 코드가 추가로 필요합니다.

    • SUSE Manager 5.0 서버

    • SUSE Manager 5.0 프록시

    • SUSE Manager 5.0 리테일 브랜치 서버

    SLE Micro 5.5 권한은 SUSE Manager 권한에 포함되어 있으므로 별도의 등록 코드가 필요하지 않습니다.

  8. SUSE Customer Center 이메일 주소를 입력합니다.

  9. SLE Micro 5.5 등록 코드를 입력합니다.

  10. 다음을 클릭하여 계속합니다.

  11. 프록시를 설치하려면 SUSE Manager 5.0 프록시 확장 프로그램을 선택하고, 서버를 설치하려면 SUSE Manager 5.0 서버 확장 프로그램의 확인란을 선택합니다.

  12. 다음을 클릭하여 계속합니다.

  13. SUSE Manager 5.0 프록시 확장 등록 코드를 입력합니다.

  14. 다음을 클릭하여 계속합니다.

  15. NTP 구성 페이지에서 다음을 클릭합니다.

  16. 시스템 인증 페이지에서 루트 사용자의 비밀번호를 입력합니다. 다음을 클릭합니다.

  17. 설치 설정 페이지에서 설치를 클릭합니다.

이를 통해 SLE Micro 5.5 및 SUSE Manager 5.0의 확장으로 설치가 완료됩니다.

2.1.1.3. 선택 사항: 명령줄에서 등록

SLE Micro 5.5 설치 중에 SUSE Manager 5.0을(를) 확장자로 추가한 경우 이 절차를 건너뛸 수 있습니다. 그러나 선택적으로 등록 건너뛰기 버튼을 선택하여 SLE Micro 5.5 설치 중에 등록을 건너뛸 수 있습니다. 이 섹션에서는 SLE Micro 5.5 설치 후 제품 등록에 대한 단계를 제공합니다.

다음 단계에서는 x86-64 아키텍처로 SUSE Manager 5.0 확장을 등록하므로 x86-64 아키텍처에 대한 등록 코드가 필요합니다. ARM 또는 s390x 아키텍처를 등록하려면 올바른 등록 코드를 사용하십시오.

절차: 명령줄에서 등록
  1. 다음 명령을 실행하여 사용 가능한 확장을 나열합니다.

    transactional-update --quiet register --list-extensions
  2. 사용 가능한 확장 목록에서 설치할 확장을 선택합니다.

    1. 서버를 설치하는 경우, SUSE Manager 서버 확장 5.0 x86_64 등록 코드를 다음 명령과 함께 사용합니다.

      transactional-update register -p SUSE-Manager-Server/5.0/x86_64 -r <reg_code>
    2. 프록시를 설치하는 경우, SUSE Manager 프록시 확장 5.0 x86_64 등록 코드를 다음 명령과 함께 사용합니다.

      transactional-update register -p SUSE-Manager-Proxy/5.0/x86_64 -r <reg_code>
  3. 재부팅합니다.

2.1.1.4. 시스템 업데이트
절차: 시스템 업데이트
  1. root로 로그인합니다.

  2. transactional-update 실행:

    transactional-update
  3. 재부팅합니다.

SLE Micro는 기본적으로 자동으로 업데이트되도록 설계되어 있으며, 업데이트를 적용한 이후에는 재부팅됩니다. 그러나 SUSE Manager 환경에서 이는 올바른 동작이 아닙니다. SUSE Manager은(는) 서버에서 자동 업데이트를 방지하기 위해 부트스트랩 프로세스 중에 트랜잭션 업데이트 타이머를 비활성화합니다.

SLE Micro 기본 동작을 사용하려면 다음 명령을 실행하여 타이머를 활성화합니다.

systemctl enable --now transactional-update.timer

2.1.2. SUSE Linux Enterprise Server 15 SP6 호스트 준비

또는 SUSE Linux Enterprise Server 15 SP6에 SUSE Manager을(를) 배포할 수도 있습니다.

다음 절차에서는 설치 과정의 주요 단계를 설명합니다.

절차: SUSE Linux Enterprise Server 15 SP6에 SUSE Manager 확장 설치
  1. https://www.suse.com/download/sles/에서 SUSE Linux Enterprise Server 15 SP6 .iso를 찾아 다운로드합니다.

  2. 호스트 운영 체제(SUSE Linux Enterprise Server 15 SP6) 및 확장 프로그램 모두에 대해 등록 코드가 있어야 합니다.

  3. SUSE Linux Enterprise Server 15 SP6 설치를 시작합니다.

    1. Language, keyboard and product selection에서 설치할 제품을 선택합니다.

    2. 라이선스 계약에서 계약서를 읽고 라이선스 약관에 동의합니다에 체크 표시합니다.

  4. 등록 방법을 선택합니다. 이 예제에서는 SUSE Customer Center를 사용하여 서버를 등록합니다.

  5. SUSE Customer Center 이메일 주소를 입력합니다.

  6. SLE Micro 5.5 등록 코드를 입력합니다.

  7. 다음을 클릭하여 계속합니다.

    SUSE Linux Enterprise Server 15 SP6의 경우 유효한 SUSE Linux Enterprise Server 구독과 해당 등록 코드가 있어야 하며, 이 화면에서 해당 정보를 제공해야 합니다. 아래에 SUSE Manager 확장 프로그램 등록 코드를 입력해야 합니다.

  8. Extensions and Modules Selection 화면에서 다음을 확인합니다.

    1. 서버를 설치하려면 SUSE Manager 서버 확장 프로그램을 선택하고, 프록시를 설치하려면 SUSE Manager 프록시 확장 프로그램을 선택합니다.

    2. Basesystem 모듈

    3. 컨테이너 모듈

  9. 다음을 클릭하여 계속합니다.

  10. SUSE Manager 5.0 프록시 확장 등록 코드를 입력합니다.

  11. 다음을 클릭하여 계속합니다.

  12. 설치를 완료합니다.

  13. 설치가 완료되면 새로 설치된 서버에 루트 권한으로 로그인합니다.

  14. 시스템 업데이트(선택 사항, 설치 중에 시스템이 업데이트를 다운로드하도록 설정되지 않은 경우):

zypper up
  1. 재부팅합니다.

  2. Log in as root and install podman and product related packages:

    • For the server, also mgradm and mgradm-bash-completion (if not already automatically installed):

zypper install podman mgradm mgradm-bash-completion
  • For the proxy, also mgrpxy and mgrpxy-bash-completion (if not already automatically installed):

zypper install podman mgrpxy mgrpxy-bash-completion
  1. 시스템을 재부팅하거나 다음 명령을 실행하여 podman 서비스 시작:

systemctl enable --now podman.service

2.2. SSH Connection Preparation

이 단계에서는 비밀번호를 요구하지 않고 SSH를 통해 기존 4.3 서버에 연결할 수 있도록 새 SUSE Manager 5.0 서버를 설정합니다. 여기에는 SSH 키를 생성 및 구성하고, SSH 에이전트를 설정하며, 공개 키를 이전 서버에 복사하는 작업이 포함됩니다.

마이그레이션 프로세스를 수동 개입 없이 실행하려면 이 설정이 필요합니다.

Procedure: Preparing the SSH Connection
  1. 새 5.0 서버에 root에 대한 SSH 키가 있는지 확인합니다. 키가 없는 경우 다음을 사용하여 키를 만듭니다.

    ssh-keygen -t rsa
  2. The SSH configuration and agent should be ready on the new server for a connection to the 4.3 server that does not prompt for a password.

    eval $(ssh-agent); ssh-add

    To establish a connection that does not prompt for a password, the migration script relies on an SSH agent running on the new server. If the agent is not active yet, initiate it by running eval $(ssh-agent). Then add the SSH key to the running agent with ssh-add followed by the path to the private key. You will be prompted to enter the password for the private key during this process.

  3. ssh-copy-id를 사용하여 SUSE Manager 4.3 서버(<oldserver.fqdn>)에 공개 SSH 키를 복사합니다. <oldserver.fqdn>을 4.3 서버의 FQDN으로 바꿉니다.

    ssh-copy-id <old server.fqdn>

    The SSH key will be copied into the old server’s ~/.ssh/authorized_keys file. For more information, see the ssh-copy-id manpage.

  4. 새 서버에서 기존 SUSE Manager 서버로 SSH 연결을 설정하여 비밀번호가 필요하지 않은지 확인합니다. 호스트 지문에도 문제가 없어야 합니다. 문제가 있는 경우 ~/.ssh/known_hosts 파일에서 기존 지문을 제거합니다. 그런 다음 다시 시도합니다. 지문은 로컬 ~/.ssh/known_hosts 파일에 저장됩니다.

2.3. 마이그레이션 수행

When planning your migration from SUSE Manager 4.3 to SUSE Manager 5.0, ensure that your target instance meets or exceeds the specifications of the old setup.

This includes, but is not limited to, memory (RAM), CPU Cores, Storage, and Network Bandwidth.

절차: 마이그레이션 수행
  1. This step is optional. If custom persistent storage is required for your infrastructure, use the mgr-storage-server tool. For more information about mgr-storage-server, see installation-and-upgrade:hardware-requirements.adoc#install-hardware-requirements-storage.

  2. 새 SUSE Manager 서버를 설치하려면 다음 명령을 실행합니다. <oldserver.fqdn>은 4.3 서버의 FQDN으로 대체합니다.

    4.3 서버를 업그레이드하고 사용 가능한 모든 업데이트를 적용한 후 마이그레이션 프로세스를 시작하십시오. 또한 불필요한 채널을 모두 제거하여 전체 마이그레이션 시간을 단축하십시오.

    The migration can take a very long time depending on the amount of data that needs to be replicated. To reduce downtime it is possible to run the migration multiple times in a process of initial replication, re-replication, or final replication and switch over while all the services on the old server can stay up and running.

    Only during the final migration the processes on the old server need to be stopped.

    For all non-final replications add the parameter --prepare to prevent the automatic stopping the services on the old server. For example on SUSE Manager server:

    mgradm migrate podman <oldserver.fqdn> --prepare
Procedure: Final Migration
  1. Stop the SUSE Manager services on 4.3 Server:

    spacewalk-service stop
  2. Stop the PostgreSQL service on 4.3 Server:

    systemctl stop postgresql
  3. Perform the migration on SUSE Manager server

    mgradm migrate podman <oldserver.fqdn>
  4. 신뢰할 수 있는 SSL CA 인증서를 마이그레이션합니다.

2.3.1. Migration of the Certificates

Trusted SSL CA certificates that were installed as part of an RPM and stored on SUSE Manager 4.3 in the /usr/share/pki/trust/anchors/ directory will not be migrated. Because SUSE does not install RPM packages in the container, the administrator must migrate these certificate files manually from the 4.3 installation after the migration.

Procedure: Migrating the Certificates
  1. Copy the file from the 4.3 server to the new server. For example, as /local/ca.file.

  2. 다음을 사용하여 파일을 컨테이너에 복사합니다.

    mgrctl cp /local/ca.file server:/etc/pki/trust/anchors/

mgradm migrate 명령을 성공적으로 실행한 후에도 모든 클라이언트의 Salt 설정은 계속해서 기존 4.3 서버를 가리킵니다.

To redirect them to the 5.0 server, it is required to rename the new server at the infrastructure level (DHCP and DNS) to use the same FQDN and IP address as 4.3 server.