Copy log files from client

(imported topic written by Shlomi91)

Hi,

i would like to copy (or display the content of) several specific log files from a known location on a client PC to my BES console. (the file names are always the same and always in the same location).

is this possible? how can i do this?

thanks,

Shlomi

(imported comment written by BenKus)

Hi Shlomi,

Do you have Windows privileges on the computers? If so, you can potentially use the customized “right-click” menu to copy the files… If you don’t have Windows privileges, you will want to have the BES Agent upload the files, but the files will end up on the server and you would have to copy them to the console yourself.

Ben

(imported comment written by Shlomi91)

Hi Ben,

i manage over 200 sites, not all of which are in our domain… so ill choose option 2 :slight_smile: (bigfix client uploads the file)

can i distinguish the client which uploaded the file on the server? (for example, each file will be uploaded to a folder with the client’s name)

thanks,

Shlomi

(imported comment written by BenKus)

Hi Shlomi,

You will want to take a look at our “Upload Manager” functionality. Documentation available at:

http://support.bigfix.com/resources.html

Here is an example action to upload the contents of the folder “C:\test” to the server:

// upload results example script

// set max size to 4 MB to prevent too much data
setting “_BESClient_ArchiveManager_MaxArchiveSize”=“4194304” on “{parameter “action issue date” of action}” for client

// Set the agent to send info only once (rather than resending periodically)
setting “_BESClient_ArchiveManager_OperatingMode”=“2” on “{parameter “action issue date” of action}” for client

// Tell agent which files to collect
setting “_BESClient_ArchiveManager_FileSet-test”=“C:\test*.*” on “{parameter “action issue date” of action}” for client

// send results
archive now

Ben

(imported comment written by sonny.mcmanigle91)

we use the upload manager to collect system logs from over 1200 remote sites over a 56k frame nightly… pull back around 2.5gb and the network utilization goes unnoticed… the upload manager is definitely a great asset for doing remote collection. the maxarchive bit us once… make sure you know the size of the files you’re collecting!! :wink:

you could also write an analysis for a file contains to return a true or false string, like if you’re trying to parse an install log to ensure something worked or didn’t work for a one time type of thing.

(imported comment written by venkat_murty91)

When you say “maxarchive bit us once”, is it referring to the MaxArchive limit set at the endpoint or was it some limit reached at your relay or server?

Is there a 2.5G limit at end point or a limit at the relay or a limit at the server ?

(imported comment written by sonny.mcmanigle91)

Hello Venkat…

I was referring to the MaxArchiveSize setting that is applied at the client Endpoint when you are creating your Upload job.

setting “_BESClient_ArchiveManager_MaxArchiveSize”=“45000000” on “{now}” for client

When we started our automated process, the logs that we were harvesting were small and maintained by the default setting. It turned out that over time the logging methodology changed, creating much more verbose logs, thus creating larger flat files to be uploaded. We noticed failures and discovered the default setting. The setting above is in bytes and controls the size of the files that you can pull back… this is important to us as we have constrained bandwidth to our endpoints and do not want to try to pull back grossly large files that would be affected by and cause network latency.

(imported comment written by cstoneba)

Say you wanted to upload files from two different folder (c:\test) and (c:\test2). How would one go about doing that?

(imported comment written by BenKus)

You would add another line that was:

setting “_BESClient_ArchiveManager_FileSet-test2”=“C:\test2*.*” on “{parameter “action issue date” of action}” for client

Ben

(imported comment written by cstoneba)

this command succeeded, but it didn’t upload the file.

setting “BESClient_ArchiveManager_FileSet-Pic”="__BESData\actionsite*.jpg" on “{parameter “action issue date” of action}” for client

Does it not like the actino site folder or the *.jpg ?

(imported comment written by BenKus)

Hey cstoneba,

Which files are you trying to collect?

First, I think that you need a full path, but also, I don’t think you will find many .jpg files in your actionsite (and if you do, they will disappear the next time your agent gathers).

Ben

(imported comment written by cstoneba)

There is a .jpg in the actionsite folder because an app that I am executing put it there. Here is what the index.txt says after the upload. The jpg did not upload though and I verified it was in the __Besdata\actionsite folder.

MIME-Version: 1.0

Content-Type: multipart/x-directory2; boundary="==="

Unique-ID: 313372

Archive-Size: 41

SendAll: 0

Date: Tue, 24 Mar 2009 00:47:47 +0000

FileSet-Info: __Download\vfwgrab\releaseu\info.txt

FileSet-Pic: __BESData\actionsite*.jpg

–===

URL: file:///__Download/vfwgrab/releaseu/info.txt

NAME: Info_0_info.txt

SIZE: 41

TYPE: FILE

HASH: 574a819e7f6ee0aeef717a6a1f1f1da275b2766d

MODIFIED: Tue, 24 Mar 2009 00:47:40 +0000

===

(imported comment written by BenKus)

Hey cstoneba,

The actionsite will be cleared every time a new a action is issued and that can complicate things. I recommend you use a different path and provide the full path to your setting.

Ben

(imported comment written by cstoneba)

So then I shouldn’t leave my working directory as __Download\test (the default location where the download was uncompressed to) because it will go away…?

(imported comment written by BenKus)

Yep… the __Download folder gets cleared during each action (to avoid having conflicting files in the same folder)…

Ben