[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [hobbit] Is there a way to clone host definitions in bb-hosts?
- To: hobbit (at) hswn.dk
- Subject: Re: [hobbit] Is there a way to clone host definitions in bb-hosts?
- From: "Josh Luthman" <josh (at) imaginenetworksllc.com>
- Date: Wed, 11 Jun 2008 01:37:58 -0400
- References: <961092e10806101815oef6757fjedca48ac0efacfd5 (at) mail.gmail.com> <BAC1D28A5AB852439A6914CA7AB4E63F05192D4D (at) permls05.wde.woodside.com.au>
Colin gets what I'm saying! That is exactly what I was getting to.
On Tue, Jun 10, 2008 at 9:26 PM, Coe, Colin C. (Unix Engineer)
<Colin.Coe (at) woodside.com.au> wrote:
>
> Our cluster nodes are node000 -> node999
>
> We do the following:
>
> for I in `seq -w 0 999`; do echo "`getent hosts node$I | cut -d' ' -f1`
> node$I # ssh etc"; done > /tmp/output.txt
>
> CC
>
>
>> -----Original Message-----
>> From: Josh Luthman [mailto:josh (at) imaginenetworksllc.com]
>> Sent: Wednesday, 11 June 2008 9:15 AM
>> To: hobbit (at) hswn.dk
>> Subject: Re: [hobbit] Is there a way to clone host
>> definitions in bb-hosts?
>>
>> What I do in cases of this are to use for, if/then kind of things.
>>
>> Example, I have a log that sticks in lines like
>>
>> 1.2.3.4 n y
>> 2.2.5.6 x z
>>
>> And I find repeating lines by IP in $1 then get a count of
>> them using wc.
>>
>> I can show you the script if this didn't come out clear.
>>
>> Josh
>>
>>
>>
>> On 6/10/08, John Burk <john.d.burk (at) gmail.com> wrote:
>> > let's just assume that after wrangling *nix machines for
>> over 20 years
>> > I'm familiar with a couple of shells.
>> >
>> > What I'm looking for is a more helpful answer; loading several files
>> > up into vi and doing a search and replace on all lines that match a
>> > pattern feels kludgy to me.
>> >
>> > 2008/6/10 Josh Luthman <josh (at) imaginenetworksllc.com>:
>> >> Get familiar with bash or tcsh =)
>> >>
>> >> On Tue, Jun 10, 2008 at 7:29 PM, John Burk
>> <john.d.burk (at) gmail.com> wrote:
>> >>> I'm using hobbit for monitoring a compute cluster of nearly 1000
>> >>> identical hosts. I'm using includes in my bb-hosts to
>> keep the file
>> >>> length down, but my included files are comprised of
>> hundreds of hosts
>> >>> all identical except for the ipaddresses and hostnames.
>> >>>
>> >>> Surely there must be a way to template this, I just can't
>> find it in
>> >>> the bb-hosts manpage...
>> >>>
>> >>> << bb-hosts >>
>> >>> ==============================
>> >>> 172.16.133.45 spork # bbd http://spork/
>> >>>
>> >>> group Qube Supervisor
>> >>> 172.16.136.68 greenjeans # conn mysql RAID
>> >>> NOCOLUMNS:files,ports
>> >>>
>> TRENDS:*,vmstat:vmstat|vmstat5,mysql:mysql|mysqlthreadsconnect
>> ed|mysqlthreadrunqueue|mysqlopenfiles|mysqlopentables|mysqlope
>> nedtables|mysqlrestrictiontablerowcount
>> >>>
>> >>> page farm Farm Hosts
>> >>>
>> >>> include clients.d/opteron
>> >>> include clients.d/rfl
>> >>> include clients.d/hp_blade
>> >>> ==============================
>> >>>
>> >>>
>> >>>
>> >>> Right now I'm doing this:
>> >>> << clients.d/hpblade >>
>> >>> ==============================
>> >>> subpage chassis01 bladeChassis 01
>> >>> 172.16.131.20 rn0101 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.21 rn0102 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.22 rn0103 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.23 rn0104 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.24 rn0105 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.25 rn0106 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.26 rn0107 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.27 rn0108 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.28 rn0109 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.29 rn0110 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.30 rn0111 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.31 rn0112 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.32 rn0113 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.33 rn0114 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.34 rn0115 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.35 rn0116 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>>
>> >>> subpage chassis02 bladeChassis 02
>> >>> 172.16.131.60 rn0201 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.61 rn0202 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.62 rn0203 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>> 172.16.131.63 rn0204 # NOPROPRED:+cpu
>> NOPROPYELLOW:+memory
>> >>> NOCOLUMNS:files,ports
>> >>>
>> >>> and so on in mind-numbing repetition...
>> >>> ==============================
>> >>>
>> >>> I'd like to be able to define the tags in a template, and
>> simply use
>> >>> that template. Does this mechanism exist in bb-host? That way
>> >>> if/when I need to change the tags for all my hosts, I
>> only need to do
>> >>> it in one place, and not on every line in 3 different files.
>> >>>
>> >>>
>> >>> John Burk
>> >>>
>> >>> To unsubscribe from the hobbit list, send an e-mail to
>> >>> hobbit-unsubscribe (at) hswn.dk
>> >>>
>> >>>
>> >>>
>> >>
>> >>
>> >>
>> >> --
>> >> Josh Luthman
>> >> Office: 937-552-2340
>> >> Direct: 937-552-2343
>> >> 1100 Wayne St
>> >> Suite 1337
>> >> Troy, OH 45373
>> >>
>> >> Those who don't understand UNIX are condemned to reinvent
>> it, poorly.
>> >> --- Henry Spencer
>> >>
>> >> To unsubscribe from the hobbit list, send an e-mail to
>> >> hobbit-unsubscribe (at) hswn.dk
>> >>
>> >>
>> >>
>> >
>> > To unsubscribe from the hobbit list, send an e-mail to
>> > hobbit-unsubscribe (at) hswn.dk
>> >
>> >
>> >
>>
>>
>> --
>> Josh Luthman
>> Office: 937-552-2340
>> Direct: 937-552-2343
>> 1100 Wayne St
>> Suite 1337
>> Troy, OH 45373
>>
>> Those who don't understand UNIX are condemned to reinvent it, poorly.
>> --- Henry Spencer
>>
>> To unsubscribe from the hobbit list, send an e-mail to
>> hobbit-unsubscribe (at) hswn.dk
>>
>>
>>
>
> NOTICE: This email and any attachments are confidential.
> They may contain legally privileged information or
> copyright material. You must not read, copy, use or
> disclose them without authorisation. If you are not an
> intended recipient, please contact us at once by return
> email and then delete both messages and all attachments.
>
>
> To unsubscribe from the hobbit list, send an e-mail to
> hobbit-unsubscribe (at) hswn.dk
>
>
>
--
Josh Luthman
Office: 937-552-2340
Direct: 937-552-2343
1100 Wayne St
Suite 1337
Troy, OH 45373
Those who don't understand UNIX are condemned to reinvent it, poorly.
--- Henry Spencer