Phani Kumar
Phani Kumar

Reputation: 450

jstat - Any performance impact in production

Is there any performance impact if we keep running jstat command (say every 5 min or so) in production environment to monitor JVM (6.x) memory? The target system is a real time application and even one second pause does matter.

Upvotes: 5

Views: 2073

Answers (1)

apangin
apangin

Reputation: 98495

No, jstat does not impose any noticeable performance impact, even when run every second.

This tool relies on HotSpot Performance Counters (aka PerfData). jstat basically reads data from mmap'ed /tmp/hsperfdata_username/vmid. HotSpot exports these counters anyway, whether you read them or not.

Upvotes: 8

Related Questions