Mailing List Archives
Authenticated access
|
|
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Condor-users] Use IP constraint in condor_status, but why is there also port number?
- Date: Tue, 10 Mar 2009 09:24:20 -0500
- From: Daniel Forrest <dan.forrest@xxxxxxxxxxxxx>
- Subject: Re: [Condor-users] Use IP constraint in condor_status, but why is there also port number?
> > In a shell script, I want to be able to do following:
> >
> > IP="<125.125.120.67>"
> > Slot="1"
> > condor_status -l \
> > -constraint "MyIP == \"$IP\""\
> > -constraint "SlotID == $Slot"
> >
>
> In this particular case, something like this should work:
>
>
> condor_status -const 'slotid == 1 && regexp("<1.2.3.4:\d+>", MyAddress)'
Alternatively, you can do it this way:
IP="125.125.120.67"
Slot="1"
condor_status -l \
-constraint "RegExpS(\"<(.*):\d+>\",MyAddress,\"\1\") == \"$IP\"" \
-constraint "SlotID == $Slot"
And avoid needing to add the "<" and ">" to $IP.
--
Dan