Windows- PBS not exporting all the system variables

The job which runs on the execution nodes does not seem to be loading all of the system variables in windows. There are some variables like “NUMBER_OF_PROCESSORS”, “PROCESSOR_ARCHITECTURE”, etc which I want to use in the application which I want to run on the client but I see that only PATH is set properly.
I explored qsub -V but it is exporting system variables of the windows host running pbs_server instead of loading the variables on the system running pbs_mom. What should I do to instruct pbs environment on the mom-machine to sync with its every system variables?

   -V      Declares  that  all  environment  variables and shell functions in the user’s login environment where qsub is run are to be exported to the job.  The job’s Variable_List attribute is appended with all of these environment variables and their values.

Other ways are

  • Have these environment variable set in your job submission script and do a qsub script.bat
  • Manually you can set specific variables , for example qsub -v VAR1=test1,VAR2=test2 – pbs_sleep 100