Tidsplanlagte kommandoer og jobber

## Denne hjelpesiden er ufullstendig

### Introduksjon

This module can be used to setup commands to be run automatically at scheduled times. It uses the standard Unix `cron` daemon, which can run commands as various users at selected minutes, hours, days of the month, days of the week and months of the year. Every job is owned by a user, and when executed runs with the permissions of that user.

The module's main page lists all the known scheduled jobs, grouped by the user to run as. Some systems will have jobs that are part of the operating system, owned by users like `root` or `sys`. There may also be jobs created by users on your system using the `crontab` command, owned by the users who created them.

### Opprett en ny tidsplanlagt jobb

To create a new job, click on the `Create new Scheduled Job` below the list of existing jobs. This will display a form for entering the following parameters :

- User to run as
  The login name of the Unix users the job will be run as.

- Active?
  If a job is not active, it will still be displayed in the list of known jobs, but will not be run on schedule.

- Command
  The actual Unix command to run at the schedules time. This can be any command that you would type at the command line.

- Input to command
  If this field is not empty, then whatever you enter will be provided as input to the command when it is run. For example, if the command was `mail foo@bar.com` and the input `hello world`, then the input text would be emailed to `foo@bar.com`.

- Times to run
  The times when a command is run are chosen by specifying the minutes, hours, days of the month, months of the year and days of week to run. For each of these you can either choose `All`, or select the times when the command should be run.

  For example, if you chose 5 for the hour and tuesday for the day of the week then the command would be run every minute from 5:00am to 5:59am on tuesdays.
  Alternatively, if you chose 30 for the minute and 14 for the hour, then the command would be run every day at 2:30pm.

Once you have filled in the form, click on the `Create` button on the bottom on the page. The new job will take effect immediately.

### Editing an Existing Scheduled Job

To edit an existing job, click on the command from the list of jobs on the main page. The form for editing an existing job is the same as the form for creating a new job, described above. One you have made whatever changes are needed, click on the `Save` button at the bottom of the page.

To delete a job, click on the `Delete` button at the bottom of the job editing form. This will immediately delete the job without asking for confirmation.

Return to module