Is there a good way to add about 400 machines to a manual label. These machines share nothing in common so I cannot use smart labels.

Answer Summary:
Cancel
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Answers

2

One way I cheated with the manual label is by doing the following. I was needing to have about 700 machines in a manual label. I lucked out by having a list of machines in csv.

I took my csv and ran this formula on the cells where the machine names were listed ="'"&B1&"',". Assuming B1 is the start of your machine names. This will add ' ', to every cell after you click and drag down your list. Then copy and paste that new row into the SQL query below.

 

I created a dummy smart label. I then modified it to include an IN command in the SQL.

select MACHINE.*, C.CLIENT_CONNECTED, UNIX_TIMESTAMP(now()) - UNIX_TIMESTAMP(LAST_SYNC) as LAST_SYNC_TIME,

UNIX_TIMESTAMP(LAST_SYNC) as LAST_SYNC_SECONDS

from ORG1.MACHINE

LEFT JOIN KBSYS.KUID_ORGANIZATION O ON O.KUID=MACHINE.KUID LEFT JOIN KBSYS.SMMP_CONNECTION C ON C.KUID = MACHINE.KUID AND O.ORGANIZATION_ID = 1

where (  MACHINE.NAME IN ('COMPUTER1','COMPUTER2', 'COMPUTER3'))

 

This will still be considered a smart label so you can still create a manual label afterwards. It does beat checkmarking 500 boxes though.

Answered 03/13/2013 by: dugullett
Red Belt

  • Nice!
  • This idea does sound nice, but I'm not fluent in SQL. I can and do use MySQL workbench to run and test queries, but I have no idea how to "copy and paste that new row into the SQL query"... Paste it where, exactly?
    • Copy and paste in place of 'COMPUTER1','COMPUTER2', 'COMPUTER3'. Make sure the names are in between ' '.
Please log in to comment
2

Here's another idea. I'm assuming that you at least have the list of those computers that need the label in a file of some sort, perhaps a spreadsheet? You can use a field to the Computer Asset type to designate those included in the audit. So it would work something like this:

Export from the Inventory a list of all computers including the serial number and computer name.

Using Excel you should be able to filter that list down to just those machines from your "needs audited" list.

Now you have a list of the computer serial numbers that need to be included in the audit.

Add a column to the spreadsheet that will be imported to the asset database. You can either use the Notes column if it isn't already in use, or add a field to the Computers asset type. If you think this may happen in the future, then perhaps a generic "Include in Audits" would work and you can populate it with Yes answers for these assets. 

Import the spreadsheet using the Asset Import function being sure to use the serial number as the primary key so that records are updated and not duplicated.

You can now perform an advanced search on the Inventory which allows you to search the Asset fields for the asset that matches the computer. You could actually even setup a smart label to search the same field if you wanted to.

 

Answered 07/05/2012 by: chucksteel
Red Belt

  • Sorry it took so long to reply. This did work. I got sidetracked on other projects. Thanks for your help.
Please log in to comment
1

One word: Intern :)

Answered 06/28/2012 by: Ben M
Ninth Degree Black Belt

  • Looks like I'm planning a "bring your son to work day".
  • We used our student helpdesk phone staff to do some of the custom input we needed.
  • I'm telling you, this is the easiest option by a long shot :)
Please log in to comment
0

I'm curious why you are labeling them with the same label if they don't have anything in common.

Answered 07/02/2012 by: chucksteel
Red Belt

  • We're under a software audit and the want the report to run on just these machines. Not every machine will have the software, but if they do then it will catch it with a custom inventory.
    There are other machines that will have this software, but those do not need to be included in the report.
  • Is the number of machines that will have the software but won't be included in the audit smaller? If so, you could manually apply a label to them (e.g. "No Software Audit") and then create a smart label that applies to machines with software but without designated label.
  • That is a great idea. Unfortunately there are 801 with the suite, and 400 that need to be audited. I guess is that number grows that will be the way I do it. I'm still waiting on the "official" word.
Please log in to comment
0
Hello - I actually just posted a How-To article that uses Powershell script to automate the generation of a SQL query containing machine names from a text file.


Hope this helps!
Answered 10/14/2016 by: ClayVan
Senior White Belt

Please log in to comment
0

If there's no common thread, I'd be prepared to start clicking.  ^_^

If you have a text list of the machine names, you could dump that into a smart label's SQL code (MACHINE.NAME rike '123,456,789,etc') and hit them like that.

Or if you use ADUC and is this something that will need maintained/updated?  If so, I would populate the computer object's Description field and pull them in via an LDAP label, so as more computers that meet this criteria can just be tagged as they are joined to the domain.  I just did this yesterday for ~350 machines yesterday when I completely redid my patch setup.

If you decide to go the LDAP route and need steps, I have a writeup on that here:

http://www.itninja.com/question/ldap-patching-sql-reports-using-all-three-for-efficient-managed-patching-and-other-cool-tric

Just forgive the formatting as it's being affected by a bug that's supposed to be addressed soon.  And ignore the patching section - I'll be doing a major rewrite on that.

John

Answered 06/28/2012 by: jverbosk
Red Belt

Please log in to comment
0

I'm not happy with these answers. :( I have a feeling these 400 are just the beginning.

Answered 06/28/2012 by: dugullett
Red Belt

  • Hey, look on the bright side - if *everything* could be automated, we wouldn't have jobs.

    John
Please log in to comment
0
I was looking to do what dugulett originally asked here and did find the links and info supplied by jverbosk to have some good content.

Another option I used for populating manual labels with devices is to go under "Devices", "Advanced Search and then to specify "System Name"  with "match RegEx". The field to match is where I paste multiple device names separated with a "pipe" (vertical bar) character. This "OR"s all the devices, and I am provided with a list of PCs I wish to add a label to. I can then select-all, "choose action" and "Apply Label". Maybe not the most elegant solution, but a little better then performing manual additions to labels one item at a time.

Just wanted to provide my input here in case others might search this concept further as I did originally.

- Tom -

Answered 07/21/2015 by: TDelaney
White Belt

Please log in to comment
Answer this question or Comment on this question for clarity