If you can run the JMX server application (which I assume is implied by using jconsole / jvisualvm), you can invoke the MBean gc operation in memory using command line utilities.
First, you need some kind of JMX client from the command line. I used this in the past for simple command line calls, and it worked fine. (Edit: I actually used it just now to test the following command, and it successfully called GC in the local Tomcat process)
Then you will need to develop a command to start garbage collection. I think this should work (you, of course, will need to change hosts / ports / credentials):
java -jar cmdline-jmxclient-XXjar - localhost:8081 java.lang:type=Memory gc
Finally, you can schedule this command to be cron via cron or its equivalent.
Voila!
Andrzej doyle
source share