summaryrefslogtreecommitdiffstats
path: root/move/tools/nfs-accesses
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2003-11-03 13:31:46 +0000
committerPascal Rigaux <pixel@mandriva.com>2003-11-03 13:31:46 +0000
commit9c8ac72ce9d373b761379d4694a9346c40e17f26 (patch)
treee8a190c0fe24ce8ced7a70cb145078c0a1394f6d /move/tools/nfs-accesses
parent33ddaa74688741097dcaf2aed8cead7ea0d804ca (diff)
downloaddrakx-backup-do-not-use-9c8ac72ce9d373b761379d4694a9346c40e17f26.tar
drakx-backup-do-not-use-9c8ac72ce9d373b761379d4694a9346c40e17f26.tar.gz
drakx-backup-do-not-use-9c8ac72ce9d373b761379d4694a9346c40e17f26.tar.bz2
drakx-backup-do-not-use-9c8ac72ce9d373b761379d4694a9346c40e17f26.tar.xz
drakx-backup-do-not-use-9c8ac72ce9d373b761379d4694a9346c40e17f26.zip
various fixes
Diffstat (limited to 'move/tools/nfs-accesses')
-rwxr-xr-xmove/tools/nfs-accesses11
1 files changed, 5 insertions, 6 deletions
diff --git a/move/tools/nfs-accesses b/move/tools/nfs-accesses
index b77a53bfe..7c648ea8d 100755
--- a/move/tools/nfs-accesses
+++ b/move/tools/nfs-accesses
@@ -6,11 +6,12 @@ use Getopt::Long;
GetOptions('no-link' => \ (my $no_link),
'no-dir' => \ (my $no_dir),
'full-dirs=s', \ (my $full_dirs),
+ 'ip=s' => \ (my $wanted_ip),
);
my @skipped_dirs = (
'/usr/share/fonts',
- '/lib/modules/2.4.22-18mdk',
+ '/lib/modules/2.4.22-21mdk',
'/usr/X11R6/lib/modules/extensions',
'/usr/X11R6/lib/X11/fonts',
'/usr/lib/kbd/keymaps',
@@ -20,17 +21,15 @@ my @skipped_dirs = (
my $skipped_dirs = '/tmp/live_tree(' . join('|', map { quotemeta } @skipped_dirs) . ')/';
if ($full_dirs) {
- my @l = chomp_(MDK::Common::File::cat_or_die($full_dirs));
+ my @l = chomp_(map { MDK::Common::File::cat_or_die($_) } split(' ', $full_dirs));
$full_dirs = '/tmp/live_tree(' . join('|', map { quotemeta } @l) . ')/';
}
open(my $F, "tac /var/log/kernel/warnings |");
-my $wanted_ip;
-
my @l;
while (<$F>) {
- my ($ip, $file) = /kernel: nfsd (.*?): (.*)/ or next;
+ my ($ip, $file) = /kernel: nfsd \((.*?)\): (.*)/ or next;
if ($wanted_ip) {
$wanted_ip eq $ip or next;
@@ -51,4 +50,4 @@ while (<$F>) {
last if $file eq '/tmp/live_tree/usr/bin/totem';
}
-print "$_\n" foreach uniq(@l);
+print "$_\n" foreach sort uniq(@l);