Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VFP Garbage Collection

Status
Not open for further replies.

csr

Programmer
Jul 20, 2000
507
Many moons ago ... some (if not all) database languages engaged in a practice known as "garbage collection" where they would take time away from the specific tasks of the application to clean up various residues of data left over from previous processing. This could take considerable time depending upon the processing needs of the application.

I thought that was in the past but we seem to be experiencing periodic extremely slow (dead stop) processing from time to time with our VFP 8 application. It may be associated with concentrated data entry for long periods of time. I am wondering if there is still some chance that the VFP 8 software still does something like "garbage collection" even in this modern age.

Any thoughts on this ?


Don


 
No, VFP doesn't have any kind of garbage collection like that. Could your virus scanner be slowing things down?

Tamar
 
Well, I never associated a virus scanner with scanning portions of an in-house application. Do they do that ?


Don


 
You can and should perhaps use SYS(1104) from time to time (with VFP9 you can even provide an Alias or Workarea to limit the purging of memory associated with a certain cursor, view or table). And you should take finetune memory usage with SYS(3050). And monitor the values of other memory related outputs of Sys(1016), Sys(1001), Sys(12)...

Bye, Olaf.



 
Unless you tell it not to, your virus scanner may be checking DBFs every time you open them.

Tamar
 
Don,

Virus scanners are notorious for their effect on database applications. The point is that a virus scanner will check a file every time you open it, and most data-based applications open many files many times (this is especially true of VFP apps).

It's always worth ensuring that the AV prog is set so as not to scan DBFs, CDXs, FPTs and the like.

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

My Visual FoxPro site: www.ml-consult.co.uk
 
Well, that certainly sounds like it could be the problem because some of the files that are being opened are VERY LARGE. I will look into that. Thanks to all for the help.

Don


Don


 
Oh ... one more thing ...

What about the issue of leaving the DBF files vulnerable to virus attack ?

That certainly will come up when I mention this to the IT people.



Don


 
It's true that viruses may be resident in some non executable files to be executed from somewhere else - eg by getting renamed with executable extensions - but the main threat comes from executables, which are already by themselves executable, a virus needs to start somewhere...

If you had a virus in a dbf you will certainly find out very soon (data corruption/insert will not work), as a dbf file consists only of a small header and the records. It may be easier to hide a virus inside an fpt or cdx file, but if I were a virus programmer, I'd use other files to store a virus safely until it should get active.

The default settings of virus scanner is just that paranoid because for sure it's safer to scan every file without exceptions.

With several virsus scanners you cannot only define file extensions as exceptions, but also limit this exception to certain folders, if that makes your IT department happier.

Bye, Olaf.
 
Don,

Yes, Olaf is right. A DBF can't contain a virus because it is non-executable. The problem is that the AV program doesn't know that. Because it doesn't know what a DBF file is, it wants to check it anyway.

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

My Visual FoxPro site: www.ml-consult.co.uk
 
Mike, it _can_ contain a virus. It just cannot run it from there.
(I recon there was a virus that put hia body into JPG - though no way to execute from there as well).
 
Tsh73,

it _can_ contain a virus. It just cannot run it from there.

Maybe. But I'd still switch off the scanning of DBFs. If a virus "infected" a DBF, the DBF would either appear to VFP as corrupted, or would show rubbish data. Either way, you'd want to restore it from a backup (or use a file recovery utility on it), not have the AV program deal with it.

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

My Visual FoxPro site: www.ml-consult.co.uk
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top