08-18-2010
Send an email once a job is completed
Hi,
The HPCs I used earlier used PBS (Portable Batch System) to schedule when I was running various jobs and it had an option to send me an email once a job is completed.
I'm wondering whether this is possible for any other process (without the use of PBS). For example, I'm running some codes on my computer from the terminal and it takes about a day or two to run, but I want to receive an email when the job is completed.
Thanks.
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
Hi
A) I am able to send eMail using mailx from a UNIX ( solaris 8 ) host to my Outlook-email-ID : FName.Surname@Citigroup.com ( This is NOT my actual -eMail-ID). But in Outlook the "From :" eMail address is displayed as
" usr1@unix-host1.unregistered.email.citicorp.com " .i.e the words... (2 Replies)
Discussion started by: Vetrivela
2 Replies
2. Solaris
Hi,
Thanks in advance.
i need to kill a unix background running job after that job process completes.
i can kill a job by giving the following unix command
kill -9 processid
how to kill the job after the current process run gets completed ?
Appreciate your valuable help.
Thanks... (7 Replies)
Discussion started by: dtazv
7 Replies
3. UNIX for Advanced & Expert Users
Hello - I submitted one background job last night and it completed today morning.I want to know exact time the job completed.
I submitted backgroung job like this
nohup cp -Rp /opt/apps/prod/proddb/proddata . &
I want to know when above job completed on UNIX server.Above command... (9 Replies)
Discussion started by: Mansoor8810
9 Replies
4. Shell Programming and Scripting
Hi Experts,
I need a script advice to schedule 12 jobs ( SAS Codes execute back ground ).
Algorithem:
1. Script checks first job.
2. Finds first job is done; invoke second job.
3. finds second job is done; invoke third job.
..
Request you to please assist. (3 Replies)
Discussion started by: Jerald Nathan
3 Replies
5. Shell Programming and Scripting
Hello ,
I am trying to write a unix shell script to compare folder permission to say drwxr-x-wx and then send an email to my id in case the folders don't have the drwxr-x-wx permissions set for them .
I have been trying to come up with a script for few days now , pls help me:( (2 Replies)
Discussion started by: nairshar
2 Replies
6. UNIX for Dummies Questions & Answers
hi, i'm running openldap on ubuntu 10.04, creating new items with apache directory studio (windows version).
i use the ldap just as an address book to our small office (email clients are windows live mail 2009, 2011, microsoft outlook 2007 and 2010).
a. i cant see a list of the contacts,... (0 Replies)
Discussion started by: V4705
0 Replies
7. Shell Programming and Scripting
I'm running diff at the command prompt against two very large text files (>1GB) and system kills the process and replys back "Terminated" after 15 seconds.
I believe a system parameter needs to be adjusted but can't figure it out.
I'm running Red Hat 4.1.2-46, 2.6.18-028stab089.1
Thanks... (4 Replies)
Discussion started by: azpetef
4 Replies
8. Shell Programming and Scripting
Hi i created a cron job which invoke a shell script and output some content via email.
Some times these output are sent to the junk email folder. i want these mails to be sent to inbox with some specific font. what i have to do? (4 Replies)
Discussion started by: vidhyaS
4 Replies
9. Shell Programming and Scripting
I am using centos 6.4.
I have a few cron jobs setup and they all work fine.
However, I would like to enhance one of the crons.
This is what I have at the moment:
nice rsync -au /home/samba/wsaler/* /home/samba/wsaler.backup/wsaler.backup18pm
date | /bin/mail -s "wsaler 3:00pm backup... (8 Replies)
Discussion started by: countrydj
8 Replies
10. Shell Programming and Scripting
Team,
Would like to know what is the best script that will send you an email if cronjob did not run.
Thanks (4 Replies)
Discussion started by: kenshinhimura
4 Replies
pbs(1B) PBS pbs(1B)
NAME
pbs - general information on pbs
DESCRIPTION
PBS stands for Portable Batch System. It is a networked subsystem for submitting, monitoring, and controlling a work load of batch jobs on
one or more systems. More information about PBS is available in the PBS Users Guide.
Batch means that the job will be scheduled for execution at a time chosen by the subsystem according to a defined policy and the availabil-
ity of resources. For a normal batch job, the standard output and standard error of the job will be returned to files available to the
user when the job is complete. This differs from an interactive session where commands are executed when entered via the terminal and
output is returned directly to the terminal. PBS also supports an interactive batch mode where the input and output is connected to the
user's terminal, but the scheduling of the job is still under control of the batch system.
A job is typically a shell script and a set of attributes which provide resource and control information about the job. A job does not
have to be submitted on the system where it will run, tt can be submitted on any system with the PBS commands and access to the execution
system, see qsub(1B). Output will be returned to the system from which the job was submitted unless directed otherwise.
Attributes offer control over when a job is eligible to be run, what happens to the output when it is completed and how the user is noti-
fied when it completes. The attributes of the job may be specified on the command line or in the job script when the job is submitted.
For information about job attributes, see qsub(1B) and pbs_job_attributes(7B).
One important attribute is the resource list. The list specifies the amount and type of resources needed by the job in order to execute.
The list also implies a hard upper limit on usage of those resources. When the limit is reached, the job is terminated. The types of
resources available to a job vary with the system architecture. For a list of resources supported on the default system, see
pbs_resources(7B). There are man pages for other systems types as well, see pbs_resources_aix4(7B), pbs_resources_fujitsu(7B),
pbs_resources_irix5(7B), pbs_resources_solaris5(7B), pbs_resources_sp2(7B), pbs_resources_sunos4(7B), or pbs_resources_unicos8(7B).
Once a job has been submitted, it may be monitored by use of the qstat(1B) command. Two forms of output are available with the qstat com-
mand. The default form is the short display. Information about a job is limited to a single line. Complete information about the job
or jobs is available through qstat with the -f option. Information will be given about all jobs in the system, all jobs in specified
queues, or only specified jobs.
When displaying status of jobs, you will see in which queue the job resides. In PBS a queue is just a collection point for jobs, it does
not imply any execution ordering. That ordering is determined by a scheduling policy implemented by the system administration.
Other commands of interest which have man pages of their own are:
qalter Alter a job's attributes.
qdel Delete a job.
qhold Place a hold on a job to keep it from being scheduled for running.
qmove Move a job to a different queue or server.
qmsg Append a message to the output of an executing job.
qrerun Terminate an executing job and return it to a queue.
qrls Remove a hold from a job.
qselect Obtain a list of jobs that met certain criteria.
qsig Send a signal to an executing job.
SEE ALSO
qalter(1B), qdel(1B), qhold(1B), qmove(1B), qmsg(1B), qrerun(1B), qrls(1B), qselect(1B), qsig(1B), qsub(1B) and the PBS User Guide. Start-
ing with qsub(1B), you can find all other available PBS man pages by following references in the "See Also" section.
Local pbs(1B)