On Thu, 30 Sep 2004 19:29:20 +0200, Matthijs Mohlmann wrote:
> Hi,
>
> I'm maintainer of raidtools2 and i'm having some trouble with the
> cron.daily script. This script checks if there are failed disks or if
> there are spare disks in use.
>
> Well the following guy is having trouble with it and i can't get it why
> it failed on his place. I've here a suitable setup and using also
> raidtools2 and all is going ok. It's about this expression:
>
> RAIDDEV=$(awk '/^[:blank:]*raiddev/ {print " " $2}' /etc/raidtab)
>
> This expression should get all the second arguments of lines beginning
> with raiddev. Can someone point me what's here failing ?
Three serious problems:
1. it should be [[:blank:]] not [:blank:]
2. character classes are supported by gawk but not by mawk or original-awk
3. awk is not essential and raidtools2 don't depend on it
Still, even in this broken form it shouldn't (and doesn't here)
match lines that start with '#'.
--
Michał Politowski
Talking has been known to lead to communication if practised carelessly.
Attachment:
signature.asc
Description: Digital signature