• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

the first java program runs very slow

 
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The first java application/applet runs very slow (4 - 10 min) after PC boot up. Subsequent java program is OK (less than 1 min). The problem is due to Sophos anti-virus software. The first Java program triggers Sophos anti-virus software to run and the anti-virus program takes about 100% of CPU. So the other program just hang there. Anybody can help me to solve this problem. Thanks.
 
author and iconoclast
Posts: 24207
46
Mac OS X Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

Welcome to JavaRanch!

Perhaps your antivirus program can be configured to ignore whatever activity is taking so long; or perhaps you can switch to a different antivirus program. I would say this is a question for the makers of this virus software.
 
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Try to diminish the priority of the thread that triggers the anti-virus process...and see if that helps.
 
Cai DongShan
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ernest, Bhanu, thanks for your reply.

Because the antivirus software is corporate standard software, we cannot change it currently. There is not a setting in Sophos software to ignore the particular program like Java also. Unless we disable the antivirus software, but it cannot be done.

I think that the problem is not due to Java program itself but JVM. When JVM start, the antivirus program is triggered. So only first running Java program is affected. Not only application, but also applet.

Is there a way to start JVM (e.g. Java web start) when boot up and continue to activate it until PC shutdown?
 
Ranch Hand
Posts: 1923
Scala Postgres Database Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Virus-software sounds like windows-pc.

Start a dummy application in your autostart-group.
 
Cai DongShan
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I disable the option "Scan inside archive files" in Sophos antivirus software, the problem is solved.
 
Ranch Hand
Posts: 139
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dongshan,

Disabling the Archive scanning will hide realy viruses also.
So, that is not the best solution.

Stefan's suggestion is the right approach.

Start a dummy "Hello World" app on statrup, it will take care of scanning your classes.zip or rt.jar .....
 
Cai DongShan
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks, Deep and Stefan. Deep, you are right. Disabling the Archive scanning is not a good solution.

Because our Sophos antivirus software is updated (update/close/start) once or twice per day, depends on how often the virus definition is updated. We need to run the dummy program not only at the boot up time, but also after antivirus software updating. I don't know how to run the dummy program automatically after software updating.
 
Every plan is a little cooler if you have a blimp. And a tiny ad.
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic