Intel® Distribution for Python*
Engage in discussions with community peers related to Python* applications and core computational packages.
431 Discussions

Unable to submit a job using Terminal

penguined
Beginner
2,588 Views

I have followed the basic job submission tutorial and created a file named myjob.txt in the server. Then added these two lines in myjob.txt file using a text editor.

 

cd $PBS_O_WORKDIR python final.py

Then I executed the command "qsub myjob.txt" and a job id returned. After that, I executed the command "qstat" and it returned with the job id of the jupyterhub. Also two new blank files also created in the directory - myjob.txt.o4489 and myjob.txt.e4489. What am I doing wrong here?

 

 

64b0379660d5cba5b10d6752b4f6ed1f.png

0 Kudos
4 Replies
Ratheesh_A_Intel
Employee
1,185 Views

Hi Toqi,

 

Thanks for reaching out to us. 

Please follow the steps mentioned below to submit the job

 

1. Create a file named as myjob

vi myjob

2. Open the file and add the following commands

  #If you want to run the job for 24hrs add the command mentioned below (include #)

#PBS -l walltime=24:00:00        

#PBS -l nodes=1

cd $PBS_O_WORKDIR

#Activate your environment using the command below

source activate <ENV_NAME>

#Redirect to the working directory

cd <DIRECTORY PATH>

python <YOUR PYTHON NAME>.py

 

 

Please find the attached sample file. It would be great if you can share the observation once you are done.

 

 

 

Since you are getting both the object file and error file as blank, Please try to execute the code directly in a compute node (not as a job) and share the observation.

 

1. Get a compute node

qsub -I

2. Redirect to the working directory

cd <DIRECTORY PATH>

3. Execute the code as

python final.py

 

 

 

0 Kudos
Ratheesh_A_Intel
Employee
1,185 Views
Hi Toqi, Thanks for reaching out to us. Please follow the steps mentioned below to submit the job 1. Create a file named as myjob vi myjob 2. Open the file and add the following commands #If you want to run the job for 24hrs add the command mentioned below (include #) #PBS -l walltime=24:00:00 #PBS -l nodes=1 cd $PBS_O_WORKDIR #Activate your environment using the command below source activate <ENV_NAME> #Redirect to the working directory cd <DIRECTORY PATH> python <YOUR PYTHON NAME>.py Please find the attached sample file. It would be great if you can share the observation once you are done. Since you are getting both the object file and error file as blank, Please try to execute the code directly in a compute node (not as a job) and share the observation. 1. Get a compute node qsub -I 2. Redirect to the working directory cd <DIRECTORY PATH> 3. Execute the code as python final.py Thanks & Regards Ratheesh A
0 Kudos
Ratheesh_A_Intel
Employee
1,185 Views
Hi, Could you please confirm whether the solution provided worked for you or not. Thanks Ratheesh A
0 Kudos
Ratheesh_A_Intel
Employee
1,185 Views
Hi, Hope the solution provided worked for you. Feel free to raise new thread for any further issues. Thanks Ratheesh A
0 Kudos
Reply