Hello,

We use a vb script who detect and list all of the active monitors on our computer into a txt file, we have added this script into our k1000, made a custom inventory field for adding the monitors returned information from the script into our custom inventory field with the command "ShellCommandTextReturn"

Our problem is that the custom inventory field never get the information ...

We have tried with the fileexist command, who return a boolean, and we get a custom software who appear in the software list, that make us think that our custom inventory field is correctly setup. But when we change the command fileexist for the shellcommandtextreturn, the custom program disappear from the software list, and the custom inventory field is still blank.

Could someone help us with this problem ?

Here our K1000 version : v5.3.47927

Thanks by advance
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
What command are you running?
Answered 11/17/2011 by: dchristian
Red Belt

Please log in to comment
0
As David stated, we can't help if you don't give us the custom inventory code you're using.
Answered 11/21/2011 by: airwolf
Tenth Degree Black Belt

Please log in to comment
0
Sorry for the late reply

We use this command :

Shellcommandtextreturn(type c:\temp\monitor.txt)

Normally it should return the text inside the file, but nothing is returned.
Answered 11/23/2011 by: demonvip
Senior Yellow Belt

Please log in to comment
0
The command is correct. Did this used to work and all of the sudden stop working?

I'm guessing this may be a 5.3 bug. Have you contacted support?

Another thought is that you may be exceeding the maximum field size (i.e. the text in the file is too long), and the K1000 may just dump the entire shell output as a result. Try modifying that file on a test system to only contain 1 line of text and try again. If it works, then that is the problem.
Answered 11/23/2011 by: airwolf
Tenth Degree Black Belt

Please log in to comment
1
Try this:

Shellcommandtextreturn(cmd.exe /c type c:\temp\monitor.txt)
Answered 11/23/2011 by: dchristian
Red Belt

Please log in to comment
0
I hadn't thought of that, David. Good one!

If that works, then I'm not too crazy about having to call the shell from the shell to get the output of the command... a bit of redundancy (and not the good kind). [;)]
Answered 11/23/2011 by: airwolf
Tenth Degree Black Belt

Please log in to comment
0
Great it works with the "cmd.exe /c ..."

For information, it's the first time we try to make a custom inventory field and it never works before we try with this command.

Thanks a lot for your help.
Answered 11/23/2011 by: demonvip
Senior Yellow Belt

Please log in to comment
0
Did your other command work in 5.1? If so please let us know.
Answered 11/28/2011 by: GillySpy
Seventh Degree Black Belt

Please log in to comment
0
Have the same problem, I`m using custom rule: Shellcommandtextreturn(cmd.exe /c type c:\installedmemory.txt) but no data in computer inventory. Please help
Answered 02/21/2012 by: tomikuku
Senior Yellow Belt

Please log in to comment
0
Custom inventory rules like this are dependant on a number of factors. Some things to check:

1. Is there data in that file?
2. If you open a command prompt and execute that command, do you get data?
3. Is the machine your testing running an OS that is selected in the Supported OS section of the custom Software Inventory rule?
4. If you look in the KDeploy log, you should see reference to this CI rule being processed. What does it say?
Answered 02/21/2012 by: scottlutz
Orange Senior Belt

Please log in to comment
0
1) There is data in that file:
Memory installed in . (VMware Virtual Platform)
----------------------------------------------
Slot 1 : 1GB EDO DRAM MHz
Slot 2 : -- empty --
Slot 3 : -- empty --
Slot 4 : -- empty --
Slot 5 : -- empty --
Slot 6 : -- empty --
Slot 7 : -- empty --
Slot 8 : -- empty --
Slot 9 : -- empty --
Slot 10 : -- empty --
Slot 11 : -- empty --
Slot 12 : -- empty --
Slot 13 : -- empty --
Slot 14 : -- empty --
Slot 15 : -- empty --
1GB Installed
256GB Maximum

2) Yes I do get output from cmd.
3) I`m testing it on virtual Win7 Ent x86
4) mmm.. where can I find that log?
Answered 02/21/2012 by: tomikuku
Senior Yellow Belt

Please log in to comment
0
To point 3, you need to go into the custom inventory rule that is running the command to ensure that you have:
Microsoft Windows 7 Enterprise
Listed under "Supported Operating Systems", within the record of the Software Inventory record.


You can find all logs under:
c:\programdata\dell\kace
Answered 02/21/2012 by: scottlutz
Orange Senior Belt

Please log in to comment
0
3) It is being deployed to Microsoft Windows 7 Enterprise

There is no reference to that rule in Kdeploy.log.

Strange thing is that I can see software with custom rule as Installed Programs and no data in Custom Inventory Fields
Answered 02/21/2012 by: tomikuku
Senior Yellow Belt

Please log in to comment
0
tomikuku,

What version of the agent are you running?
Answered 02/21/2012 by: dchristian
Red Belt

Please log in to comment
0
dchristian,
I`m running: Agent Version: 5.3.44367

and foolowed http://itninja.com/question/silent-uninstall-oracle-8-cilent0701 to set it up.
Answered 02/21/2012 by: tomikuku
Senior Yellow Belt

Please log in to comment
0
Try upgrading the latest agent, 5.3.53177 (its pretty sweet).

One last thing, can you post a screenshot of your custom inventory rule and the file on your machine?
Answered 02/22/2012 by: dchristian
Red Belt

Please log in to comment
0
Here is screenshot and contents of file:

Microsoft (R) Windows Script Host Version 5.8
Copyright (C) Microsoft Corporation. All rights reserved.

Memory installed in . (OptiPlex 980)
----------------------------------------------
Slot 1 : 2GB DDR 1333MHz
Slot 2 : 2GB DDR 1333MHz
Slot 3 : -- empty --
Slot 4 : -- empty --
4GB Installed
16GB Maximum



Answered 02/22/2012 by: tomikuku
Senior Yellow Belt

Please log in to comment
0
How about a screen shot of the file location?

I just tested your command on my machine and it works.

BTW i didn't think the more would work but it does.

Is that new or has it always worked?

Also tried changing the more to a type?
Answered 02/22/2012 by: dchristian
Red Belt

Please log in to comment
0
Strange thing is tha I get info about that package in Installed Programs scetion in Inventory

In my case it never worked actually :)





Answered 02/22/2012 by: tomikuku
Senior Yellow Belt

Please log in to comment
0
That's weird man, it should be working...

Last thing to check, make sure there's nothing after the command in your custom inventory rule (no spaces, or carriage returns).

Try deleting the whole rule and re-creating.

If that doesn't work open up a ticket, because it looks right.
Answered 02/22/2012 by: dchristian
Red Belt

Please log in to comment
0
I know, I also tried to return any value from that file with no success. It looks like ShellCommandTextReturn returns nothing.
Answered 02/22/2012 by: tomikuku
Senior Yellow Belt

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