The following Perl script can be run on either a Mac or Windows machine (on Windows make sure you have ActivePerl or an equivalent installed). The script writes a simple timestamp to a log file (drobo.txt) on your Drobo to prevent the drives from spinning down.
Use this in conjunction with a crontab on a Mac or set up task scheduler on your PC. The following crontab is set to run every ten minutes (change it to the time frequency you prefer):
*/10 * * * * /Users/mysilmaril/bin/drobo.pl -update -config=myconfig
Make sure you do a chmod 755 on the Perl script below to make it executable:
this program is run by a crontab
each time the crontab runs, a timestamp is written to a log file on Drobo
the log file is written to drobo every 10 minutes to make sure Drobo
doesn’t go to sleep (spin down drives)
my @months = qw(Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec);
my @weekDays = qw(Sun Mon Tue Wed Thu Fri Sat Sun);
my ($second, $minute, $hour, $dayOfMonth, $month, $yearOffset, $dayOfWeek, $dayOfYear, $daylightSavings) = localtime();
my $year = 1900 + $yearOffset;
my $timeStamp = “$weekDays[$dayOfWeek] $months[$month] $dayOfMonth, $year, $hour:$minute”;
open (DROBOFILE, ‘>>/Volumes/Drobo/drobo.txt’);
print DROBOFILE $timeStamp . “\n”;
As mentioned previously, you can accomplish the same thing with a unix shell script on a Mac or a batch file on your PC. Simply use one of these methods to automate the process so that you write to your Drobo at regular intervals.