Solved

additional column in crontab file?

Posted on 2014-01-22
2
187 Views
Last Modified: 2014-01-24
Hi

I'm looking at a list of cron jobs in the file created by crontab and they mostly seem to have the standard format

minute hour day_of_month month day_of_week command

However some of them have an extra word before the command. Do you have any idea what this is. I cant really post it as it might be sensitive but it would be something like

5 1 *** some_word command

Is that issuing the name of the user calling the command? Sorry i dont have access to a system at present to check this out for myself. I'm only on windows laptop reading some code

Thanks
0
Comment
Question by:andieje
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 48

Assisted Solution

by:Tintin
Tintin earned 250 total points
ID: 39801613
Some crontab formats (ie: vixie cron) allow for specifying the user to run the command as, eg:

5 1 * * * oracle /some/command

would run /some/command as the oracle user.

Using the traditional crontab format, the cronjob entry would be

5 1 * * * su oracle -c "/some/command"
0
 
LVL 8

Accepted Solution

by:
Surrano earned 250 total points
ID: 39802348
The problem with this format is that it can't distinguish between "user oracle should execute /some/command" and "command oracle should be executed with parameter /some/command"

So whoever invented this must have made this field mandatory which is normally redundant since the "standard" name of a crontab file matches the username who should execute these jobs.

My best bet is that if you don't recognise this "some_word" as a user name then it must be a command name (without an absolute path is another big NO-NO in crontab)
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Recently, an awarded photographer, Selina De Maeyer (http://www.selinademaeyer.com/), completed a photo shoot of a beautiful event (http://www.sintjacobantwerpen.be/verslag-en-fotoreportage-van-de-sacramentsprocessie-door-antwerpen#thumbnails) in An…
Utilizing an array to gracefully append to a list of EmailAddresses
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question