none
environment variable overwrite RRS feed

  • Question

  • Hi,

    just puzzling around with passing environment variables.

    According to HPC MSDN, understanding job and task properties, job variables overwrite system variables.

    Well, no really as I found out: System (workstation node / client) has "Path" being configured.
    Once you add "Path" to xml structure for submission, it'll be changed to "PATH" (after export again)
    and doing a test via "cmd /c set" as task exe, you'll notice both variables next to each other
    and "Path" is being in use.

    Am I doing an error here, or is it a bug from OS or HPC Pack 2016U3?

    BR ha2ver

    Wednesday, January 22, 2020 1:41 PM

All replies

  • Hi ha2ver,

    We noticed the same problem. It is because HPC Pack converts the job env name to upper case by default.

    We will check if we can fix this in the upcoming 2016U3 QFE.

    Cheers,

    Yutong Sun

    Friday, January 31, 2020 5:40 PM
  • That sounds good!

    Additionally, I did some tests on Linux clients: seems like environment vars from jobs are not at all being set.

    We used Ubuntu 14 as clients.

    BR ha2ver

    Tuesday, February 11, 2020 1:10 PM
  • Hi BR ha2ver,

    I just deployed a HPC Pack 2016 U3 cluster with ubuntu1404 compute nodes by ARM Template, but can't repro it.

    The environment variable could be set successfully.

    C:\Users\chenling>job submit /jobenv:a=a env
    Job has been submitted. ID: 6.
    
    C:\Users\chenling>task view !!.1
    Task Id                         : 6.1
    State                           : Finished
    Task Name                       :
    Command Line                    : env
    Resource Request                : 1-1 cores
    Task Type                       : Basic Task
    Submit Time                     : 2/28/2020 2:10:24 PM
    Start Time                      : 2/28/2020 2:10:24 PM
    End Time                        : 2/28/2020 2:10:25 PM
    Elapsed Time                    : 00:00:00:00
    Total Kernel Time               : 00:00:00:00:000 d:h:m:s:ms
    Total User Time                 : 00:00:00:00:000 d:h:m:s:ms
    Working Set                     : 1 MB
    Processes                       :
    Required Nodes                  :
    Allocated Nodes                 : IAASLNXCN000
    Pending Reason                  :
    Exit Code                       : 0
    Error Message                   :
    Output                          :
    STDOUT: A=a
    CCP_NUMCPUS=1
    CCP_OWNER_SID=S-1-5-18
    CCP_ISADMIN=1
    TERM=unknown
    CCP_NODES_CORES=1 IAASLNXCN000 1
    CCP_MAP_ADMIN_USER=1
    CCP_RUNTIME=2147483647
    CCP_TASKINSTANCEID=0
    CCP_NODES=1 IAASLNXCN000 1
    USER=root
    HPC_RUNTIMESHARE=\\hpc6450\Runtime$
    SUDO_USER=root
    SUDO_UID=0
    CCP_RERUNNABLE=False
    USERNAME=root
    CCP_SERVICEREGISTRATION_PATH=CCP_REGISTRATION_STORE;\\hpc6450\HpcServiceRegistration
    CCP_JOBID=6
    CCP_MPI_NETMASK=10.0.0.0/255.255.252.0
    PATH=/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/sbin:/sbin:/bin
    CCP_TASKSYSTEMID=5
    _=/usr/bin/env
    PWD=/root
    CCP_CLUSTER_NAME=hpc6450
    CCP_MPI_HOSTFILE=/tmp/nodemanager_task_5_0.FvXaL0/mpi_hostfile
    CCP_JOBNAME=
    CCP_TASKID=1
    SHLVL=3
    HOME=/root
    SUDO_COMMAND=/usr/bin/env PATH=/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/sbin:/sbin:/bin /bin/bash /tmp/nodemanager_task_5_0.FvXaL0/run_dir_in_out.sh
    CCP_EXCLUSIVE=False
    CCP_JOBTYPE=Batch
    LOGNAME=root
    CCP_RETRY_COUNT=0
    CCP_REQUIREDNODES=
    CCP_COREIDS=0
    SUDO_GID=0
    
    STDERR:
    

    Could you submit a job like this and show the output?

    Chenling




    Friday, February 28, 2020 2:09 PM