ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • IBM AIX에 Python 설치하는 방법
    System of Infra/Unix System 2021. 1. 20. 00:30
    반응형

    AIX로고이미지

    IBM AIX에 Python 설치하는 방법

    [root@test_svr1:/tmp/python_install]# ls -al | grep -i python
    -rw-r--r--    1 root     system     15140204 Jan 19 23:34 python-2.7.5-1.aix6.1.ppc.rpm
    -rw-r--r--    1 root     system       222491 Jan 19 23:34 python-devel-2.7.5-1.aix6.1.ppc.rpm
    -rw-r--r--    1 root     system      4101564 Jan 19 23:34 python-libs-2.7.5-1.aix6.1.ppc.rpm
    -rw-r--r--    1 root     system     12077202 Jan 19 23:34 python-test-2.7.5-1.aix6.1.ppc.rpm
    -rw-r--r--    1 root     system         9137 Jan 19 23:34 python-tools-2.7.5-1.aix6.1.ppc.rpm
    

    -> 이번 테스트에서는 python 2.7.5.1을 설치해보도록 하겠습니다. 파이썬은 오픈소스 이기 때문에 홈페이지 또는. org에서 파일셋을 구하도록 합니다. 파일셋은 www.perzl.org/aix/index.php?n=Main.ListOfPackages 해당 URL에서 AIX를 검색후 파일셋을 다운로드합니다. 

    [root@test_svr1:/tmp/python_install]# rpm -ivh python-libs-2.7.5-1.aix6.1.ppc.rpm
    python-libs                 ##################################################
    [root@test_svr1:/tmp/python_install]# rpm --nodeps -Uvh python-devel-2.7.5-1.aix6.1.ppc.rpm
    python-devel                ##################################################
    [root@test_svr1:/tmp/python_install]# rpm --nodeps -Uvh python-tools-2.7.5-1.aix6.1.ppc.rpm
    python-tools                ##################################################
    [root@test_svr1:/tmp/python_install]# rpm --nodeps -Uvh python-test-2.7.5-1.aix6.1.ppc.rpm
    python-test                 ##################################################
    [root@test_svr1:/tmp/python_install]# rpm --nodeps -Uvh python-2.7.5-1.aix6.1.ppc.rpm
    python                      ##################################################
    

    -> 해당 파일셋을 rpm명령어로 설치를 해주도록 합니다. 첫 번째 python-libs의 경우는 그대로 설치가 되지만 나머지 항목들은 dependency가 걸려 있기 때문에 의존성을 무시하고 설치하도록 합니다.

    [root@test_svr1:/tmp/python_install]# python --version
    Python 2.7.5

    -> 설치가 완료되면 해당 명령어를 통해 설치한 버전이 맞는지 확인을 합니다. Python 2.7.5가 제대로 설치된것을 확인할 수 있습니다.

    [root@test_svr1:/tmp/python_install]# python
    Python 2.7.5 (default, Aug  2 2013, 23:28:11) [C] on aix6
    Type "help", "copyright", "credits" or "license" for more information.
    >>>
    >>> import platform
    >>> print platform.system()
    AIX
    >>>quit()
    

    -> 파이썬이 설치된 운영체제가 어떤것인지 확인하기 위한 과정입니다. AIX에 설치했기 때문에 현재 자신의 라이브러리는 AIX 운영체제에서 사용되고 있다는 것을 보여줍니다.

    [root@test_svr1:/tmp/python_install]# python
    Python 2.7.5 (default, Aug  2 2013, 23:28:11) [C] on aix6
    Type "help", "copyright", "credits" or "license" for more information.
    >>>  hello="Hello pinetree"
    >>> print(pinetree)
    Hello pinetree
    >>>quit()

    -> 간단한 문법을 통해서 함수가 호출되어 출력되는지 확인을 합니다.

     

    PS. 포스팅의 내용은 제 기준으로 작성한 것이기 때문에 참고해서 보시면 감사하겠습니다.

    포스팅 과정의 오류 및 오타 그리고 궁금한 점에 대해서는 댓글 남겨주세요.

    반응형

    댓글

Designed by Tistory.