Delphix Toolkits (dxToolkit and dxmToolkit)

 View Only
  • 1.  running delphix toolkit commands from ansible server

    Posted 09-15-2022 09:03:00 AM

    Hi Team,

    Does anyone have any experience of running toolkit commands using ansible?

    We need to run a toolkit command from within a function in a shared generic script used for many servers.

    function start_vdbs {
    
    for CHRR in SWPF SWPD SRS ; do
    
    echo ${engine_nm}
    echo ${category}
    echo ${CHRR}
    echo ${number}
    echo ${TOOLKIT}
    
    . pickora ${category}${CHRR}${number}
    
    #${TOOLKIT}/dx_ctl_db -d ${engine_nm} -configfile ${CONFIG_AREA}/dx_${engine_nm}.conf -action start -name ${category}${CHRR}${number}
    
    ~.profile
    
    bash /nfs/oradump_dba/delphix/dxtoolkit/Linux/2.4.15.1/dxtoolkit2/dx_ctl_db -d dxswpd04 -configfile /u01/app/oracle/global/delphix/dxtoolkit/config/dx_dxswpd04.conf -action start -name ${category}${CHRR}${number} > /tmp/dx_ctl_db_${category}${CHRR}${number}.out
    
    bash /nfs/oradump_dba/delphix/dxtoolkit/Linux/2.4.15.1/dxtoolkit2/dx_ctl_db -d dxswpd04 -configfile /u01/app/oracle/global/delphix/dxtoolkit/config/dx_dxswpd04.conf -action start -name ${category}${CHRR}${number} > /tmp/dx_ctl_db_${category}${CHRR}${number}.out
    
    bash /nfs/oradump_dba/delphix/dxtoolkit/Linux/2.4.15.1/dxtoolkit2/dx_ctl_db -d dxswpd04 -configfile /u01/app/oracle/global/delphix/dxtoolkit/config/dx_dxswpd04.conf -action start -name ${category}${CHRR}${number} > /tmp/dx_ctl_db_${category}${CHRR}${number}.out
    
    done
    
    }​


    This function works fine on the local machine but not atm, when run via ansible. There is no output and I think it could be related to symlinks.

    Checking this toolkit command, seems all toolkit commands are symlinks to 'runner'.

    ls -lrt $TOOLKIT

    -rwxr-xr-x 1 oracle oinstall 13560437 May 5 15:41 runner
    -rwxr-xr-x 1 oracle oinstall 1501 May 5 15:41 install.sh
    lrwxrwxrwx 1 oracle oinstall 6 May 11 13:31 dx_config -> runner
    lrwxrwxrwx 1 oracle oinstall 6 May 11 13:31 dx_connection_check -> runner
    lrwxrwxrwx 1 oracle oinstall 6 May 11 13:31 dx_create_env -> runner
    lrwxrwxrwx 1 oracle oinstall 6 May 11 13:31 dx_ctl_analytics -> runner

    ...

    Do you know if its possible to call TOOLKIT commands directly without using a link or if there is any experience of using ansible with delphix toolkit and symlinks etc?

    Many thanks in advance for any assistance.

    Best regards,

    John



    ------------------------------
    JOHN DICKINSON
    Mr
    London Stock Exchange Group
    ------------------------------


  • 2.  RE: running delphix toolkit commands from ansible server

    Posted 09-16-2022 07:25:00 AM
    Hi John,

    Dxtoolkit is working fine with Ansible scripts using symlinks - no problem with that at all.
    If there is no output from execution, I would put my money on /tmp system mounted with noexec
    and dxtoolkit is extracting scripts by default there and then execute it.

    regards,
    Marcin

    ------------------------------
    Marcin Przepiorowski
    Director, Technical Services
    Delphix
    ------------------------------



  • 3.  RE: running delphix toolkit commands from ansible server

    Posted 09-16-2022 07:41:00 AM
    Thank you very much Marcin.

    Is it possible to specify a different directory instead of /tmp?

    ------------------------------
    JOHN DICKINSON
    Mr
    London Stock Exchange Group
    ------------------------------



  • 4.  RE: running delphix toolkit commands from ansible server

    Posted 09-16-2022 11:30:00 AM
    HI,

    you need to set TEMP and TMP environment variable to another directory and it will work fine.

    regards,
    Marcin

    ------------------------------
    Marcin Przepiorowski
    Director, Technical Services
    Delphix
    ------------------------------



  • 5.  RE: running delphix toolkit commands from ansible server

    Posted 09-16-2022 01:04:00 PM

    Thank you Marcin, we'll try that.

     

    Best regards and thanks,

     

    John

     






  • 6.  RE: running delphix toolkit commands from ansible server

    Posted 09-16-2022 09:13:00 AM

    Hi Marcin,

    We have one test server where /tmp is already executable.

    Also, our script works fine locally with  the TOOLKIT script being called and running fine.

    This would suggest /tmp is executanle.

    The problem is running the script from a remote ansible server.

    In this case the TOOLKIT script does not get run.

    Any ideas?



    ------------------------------
    JOHN DICKINSON
    Mr
    London Stock Exchange Group
    ------------------------------