[racktables-users] Re: Mass Tag servers

  • From: Jonathan Poole <jpoole@xxxxxxxxxxxxx>
  • To: "Tyler J. Wagner" <tyler@xxxxxxxxxxx>, <racktables-users@xxxxxxxxxxxxx>
  • Date: Fri, 31 Aug 2012 10:08:36 -0400

Well, 

Let me run this by you and see if you can spot any potential issues?

Looking at TagStorage and Tagtree, lets just for instance say I want to
set these 450 plus objects with a tagid of 2.

First I would need to select all objects that have a common name
like('%foo-bar%').
Second, to be cautious, I would then copy TagStorage to TagStorage2 (make
a backup the table, or entire database since it's quite small currently).

Then do a mass insert into TagStorage VALUES ('object',123,2) along with
the current values in this table.

Let me know, 

Appreciate the input as well.

Regards, 
Jonathan D. Poole




On 8/31/12 9:54 AM, "Tyler J. Wagner" <tyler@xxxxxxxxxxx> wrote:

>On 2012-08-31 14:21, Jonathan Poole wrote:
>> I have about 450 servers I want to tag.  These servers have a similar
>> naming convention of foo-bar001 to foo-bar450.  Is there a way to mass
>>tag
>> all of these machines without tagging any other machines at the same
>>time?
>
>As far as I am aware, no.
>
>When asked "how do I perform a mass change in Racktables", I usually
>answer
>"use MySQL statements". phpmyadmin is your friend.
>
>Regards,
>Tyler
>
>-- 
>"Copyright is a bargain, not property. We agreed not to copy because
>they agreed it would only be for a short period of time. They have broken
>their end of the bargain; we are now breaking ours."
>   -- Russell Nelson



Other related posts: