5 # Where to read local configuration:
6 my $pokinom_config = 'pokinom.config';
8 ########################################
10 ########################################
11 # Possible mount points
12 my @possible_mount_points;
14 # Other settings from $pokinom_config, not used here.
15 my $path_under_mount_point;
16 my $path_under_mount_point_backed_up;
17 my $path_under_mount_point_being_deleted;
22 my $interrupted_prefix;
23 my $shut_down_when_done;
25 my $rsync_partial_dir_name;
27 # Local changes to the above.
28 eval `cat $pokinom_config`;
30 # Return sorted intersection of arrays which are supposed to have unique
33 my @intersection = ();
36 foreach $element (@_) { $count{$element}++ }
37 foreach $element (keys %count) {
38 push @intersection, $element if $count{$element} > 1;
43 if (qx(whoami
) eq "bertb\n") {
44 qx(killall pokinom
&> /dev/null
);
45 # Find checkable (i.e. mounted) disks
46 my @raw_mount_points = grep (s/\S+ on (.*) type .*/$1/, qx/mount/);
47 chomp @raw_mount_points;
48 my @sources = intersection
@raw_mount_points, @possible_mount_points;
52 # qx(umount /dev/disk/by-label/Platte_* && fsck -fp /dev/disk/by-label/Platte_*);
55 print "$0: only root can run this.\n";