cronjob met ssh?

Pagina: 1
Acties:

  • Jorn
  • Registratie: Juni 2001
  • Laatst online: 17-08 13:25
Hoi,

Ik heb een account bij een betaalde internetprovider, ik kan hiernaar toe ssh-en.
Nu wil ik graag een cron-job instellen op die server, alleen ik heb hier totaal geen ervaring mee en ik vraag mij dus af hoe ik dit kan doen, en ook hoe ik hem weer kan verwijderen?
Het moet naar een url(php-script) op internet.
Ik heb geen telnet-toegang, alleen ssh.

* Erkens is een sukkel en ramt in mirc op f5 :+
* XTerm GROOOOOOTE kuis houden op hd's :)


Verwijderd

crontab -e intypen in een ssh sessie :?

Verwijderd

Op vrijdag 15 februari 2002 17:55 schreef sharpe het volgende:
crontab -e intypen in een ssh sessie :?
Ik reply nu ff namens j_iscool, ik ken hem persoonlijk, jah dat wist hij wel, maar hij moet dan die code weten, die crontab code...

Verwijderd

* * * * * /path/naar/script
waarbij de sterretjes staan voor: minuten, uren, dag van de maand, maand, dag van de week.

Verwijderd

hoe crontab en ssh samengebruiken? ik vat het niet helemaal...via contrab inloggen op je provider??

  • MikeN
  • Registratie: April 2001
  • Laatst online: 22:38
man crontab

:?

Tis maar een idee....

  • Marcel
  • Registratie: Juli 1999
  • Laatst online: 15-08 11:12
Let nou niet te veel op de topictitel, hij wil gewoon weten hoe cron werkt. Sharpe heeft gelijk, maar voor iemand die niet bekend is met crontab lijkt het me toch handiger om op zoek te gaan naar een handleiding.

Een kort verhaal uit de man-page:
code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
Actually, the crontab man page DOES give a bunch of syntax examples --
more than most man pages in fact. From the crontab man page:

     The crontab format is roughly similar to that used by vix-
     iecron, but without complex features.   Individual  fields
     may contain a time, a time range, a time range with a skip
     factor, a symbolic range for the day of week and month  in
     year,  and  additional  subranges  delimited  with commas.

     Blank lines in the crontab or lines that begin with a hash
     (#)  are  ignored.  If you specify both a day in the month
     and a day of week, the result is  effectively  ORd...  the
     crontab entry will be run on the specified day of week and
     on the specified day in the month.

     # MIN HOUR DAY MONTH DAYOFWEEK   COMMAND
     # at 6:10 a.m. every day
     10 6 * * * date

     # every two hours at the top of the hour
     0 */2 * * * date

     # every two hours from 11p.m. to 7a.m., and at 8a.m.
     0 23-7/2,8 * * * date

     # at 11:00 a.m. on the 4th and on every mon, tue, wed
     0 11 4 * mon-wed date

     # 4:00 a.m. on january 1st
     0 4 1 jan * date

     # once an hour, all output appended to log file
     0 4 1 jan * date >>/var/log/messages 2>&1

     The command portion of the line is  run  with  /bin/sh  -c
     <command> and may therefore contain any valid bourne shell
     command.  A common practice is to run  your  command  with
     exec  to  keep  the process table uncluttered.  It is also
     common to redirect output to a log file.  If you  do  not,
     and  the command generates output on stdout or stderr, the
     result will be mailed to the user in question.  If you use
     this  mechanism  for  special users, such as UUCP, you may
     want to create an alias for the user to direct the mail to
     someone else, such as root or postmaster.

Is wel geen echte handleiding, maar moet toch voldoen als eerste start.

Verwijderd

Op vrijdag 15 februari 2002 21:52 schreef freebie het volgende:
hoe crontab en ssh samengebruiken? ik vat het niet helemaal...via contrab inloggen op je provider??
Nu snap ik het wel, hij kan met ssh inloggen en wil dan een cronjob instellen op de server.

  • Jorn
  • Registratie: Juni 2001
  • Laatst online: 17-08 13:25
Ok, bedankt, ik ga het zo ff proberen.
En hoe kan ik een eenmaal ingestelde cronjob weer verwijderen?

* Erkens is een sukkel en ramt in mirc op f5 :+
* XTerm GROOOOOOTE kuis houden op hd's :)


Verwijderd

Op zaterdag 16 februari 2002 13:30 schreef j_iscool het volgende:
Ok, bedankt, ik ga het zo ff proberen.
En hoe kan ik een eenmaal ingestelde cronjob weer verwijderen?
Door hem weer gewoon weg te halen uit crontab -e :)

  • Jorn
  • Registratie: Juni 2001
  • Laatst online: 17-08 13:25
ok, heel erg bedankt.

* Erkens is een sukkel en ramt in mirc op f5 :+
* XTerm GROOOOOOTE kuis houden op hd's :)

Pagina: 1