Parsing txt file exists in bigfix server and copy the content to client

Hello,

I would like to know the possibility to create new files in the BF clients based on text file exists in the server,

the file has some information related to each client for example:

client_name1#diskspace
client_name2#diskspace2

so in client 1 I want to create file which has the first line and so on.

is it possible and if yes how can be done.

Thanks in advance

I’m a little confused about the specifics. I need as much detail as you can provide.

What is the starting condition that these things must be constructed from?

What is the end result you are looking for?

What is on the client? What is on the Server?

Where do you want things to happen, on the client or server?

By client_name1 do you mean the computer name?

What do you mean by diskspace? Is that the total size of the system disk? or free space of the system disk? or something else?

Hello @jgstew ,

Thanks for your reply,

I have file which is placed in the bigfix server and this file has data of all computers under this server as the following:

computer1#property1#propert2#
computer2#property1#propert2#

and so on

from this file in the server I want each computer read only its data and save it in file under bigfix client filesystem

I hope this time is much simpler explanation.

Thanks in advance

And forgot to add the most important point that I want to do that without downloading the file from server to clients.

If you don’t want the clients to download the file, then you must get the server to parse the file and send different actions to different clients based on the file content. So you’ll need to look at the REST API, and be prepared to write some code.

1 Like

in my case, I often use relevance & cURL to do the REST API work, so it is actually not really code, but of course, writing relevance that complicated isn’t any easier than coding.

You still haven’t explained what computer1 is.

Is this the computer name? Is it the BigFix Computer ID? Is it the Serial Number?

Basically, what is the primary key you will be using to correlate the info you wish to send to particular computers?

@JasonWalker is correct, this will absolutely require use of the REST API in order to achieve what you are looking to do.

  • This could be done through a BigFix action that runs on the Root Server periodically that uses the REST API to generate multiple actions to send this data to the correct computers.
  • This could also be done using some sort of program that runs periodically on the root server OR another location that has REST API access to the root server as well as access to the file with the data you wish to send.

It isn’t actually required that this run on the root server itself.

Is it safe for computer1 to download a file with just computer1 data? Is the issue data security related? I would assume so since you’re going to set properties visible in the registry on computer1…

If that’s the case, it can be done with a single task using dynamic downloads whereby each computer only downloads the file for itself. Requires a bit of work to build a manifest file since dynamic downloads need to use the sha1, etc… but it’s doable.

REST API can do it without file downloads, but you’re right… that will create a separate action for every endpoints which is ugly…