*/5 * * * * /path/to/script
Also, here’s a quick reference for the layout of cron. I suggest pasting this at the top of your cron file.
# MIN HOUR DAYOFMONTH MONTH DAYOFWEEK COMMAND
A collection of various tech tips for future reference
*/5 * * * * /path/to/script
# MIN HOUR DAYOFMONTH MONTH DAYOFWEEK COMMAND
#!/usr/bin/perl
use strict;
use warnings;
my @my_array = (1,6,9,2,5,12,1);
my $average = average(@my_array);
my $std_dev = std_dev($average, @my_array);
printf "avg=%.2f, st. dev=%.2f\n", $average, $std_dev;
sub average {
my (@values) = @_;
my $count = scalar @values;
my $total = 0;
$total += $_ for @values;
return $count ? $total / $count : 0;
}
sub std_dev {
my ($average, @values) = @_;
my $count = scalar @values;
my $std_dev_sum = 0;
$std_dev_sum += ($_ - $average) ** 2 for @values;
return $count ? sqrt($std_dev_sum / $count) : 0;
}
$ touch ~/.ssh/config
$ chmod 600 ~/.ssh/config
ServerAliveInterval 60
$ ssh -L 63333:localhost:5432 andrew@someserver.com
$ ssh -L 63333:192.168.1.40:5432 andrew@someserver.com
# mkdir /mnt/fedora
# mount /dev/sda3 /mnt/fedora
# mount /dev/sda1 /mnt/fedora/boot
# grub-install --root-directory=/mnt/fedora /dev/sda
title windows 7
root (hd0,3)
chainloader +1