How will you schedule a job that will run every month last day?(some months have 30 days,some 31 days,28,29 days)



How will you schedule a job that will run every month last day?(some months have 30 days,some 31 day..

Answer / kirtiranjan sahoo

55 23 28-31 * * [[ "$(date --date=tomorrow +\%d)" == "01" ]] && myjob.sh

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More Shell Script Interview Questions

What are filters explain sort with all the options available?

0 Answers  


Using set -A write a script to print the output of the ls command in 5 columns with two spaces between each column. Pretend that ls does not have multicolumn output.

0 Answers  


Explain about echo command?

0 Answers  


What is the use of "$?" Sign in shell script?

0 Answers  


What lives in a shell?

0 Answers  






c program which behaves like a shell(command interpreter). it has its own prompt say "NewShell$".any normal shell command is executed from your shell by starting a child process to execute a system program corrosponding to the command

0 Answers  


Is scripting and coding the same thing?

0 Answers  


What does $# stand for?

3 Answers   IBM,


What does $0 mean in shell script?

0 Answers  


What exactly is a shell?

0 Answers  


What is a shell script in windows?

0 Answers  


Hi, all Scripting professional. Q. I have written script1.sh and calling script2.sh in script1.sh file using bash shell as interpreter and my log in shell also bash shell.My code like Script1 #!/bin/bash echo "My script2 call" . script2.sh Here script2.sh file run successfully but when I have changed my interpreter bash to ksh like #!/bin/ksh Error are comming script2.sh command not found. Guid me how to call other script in our main script.

2 Answers  


Categories