Boa tarde,
Estou com um problema estou percebendo que o uso da minha memoria java esta crescendo muito rapido e gostaria de saber se tem como expandir o tamanho dela ou limpar essa memoria que esta sendo utilizada.
Estive procurando nos historicos do grupo aqui mais não encontrei nada a respeito.
Obrigado.
Hello,
Java is a “memory managed” language - which means it has something called a Garbage Collector which does the job of freeing unused memory when it is needed by Java for something else. Java tends to use more memory than other languages for many reasons that I won’t go into here, but typically on modern systems this is not a problem.
You can tell Java it can use more or less memory from either the Java Console located in the Windows Control Panel (if you are running Windows), or by modifying the startup scripts for the Linux Spark version (look for -Xms and -Xmx, it will say something like -Xms256M -Xmx512M or similar)
If you are not running into problems on your system, and am simply observing large memory consumption, then I’d say this is reletively normal… unless Spark is locking up on you or causing other system issues.
Are you having a system problem caused by high java memory consumption?
1 Like
não não estou com nem um problema ainda, percebi que ontem estava em 30% e hoje esta proximo dos 50% de consumo e fiquei com medo dessa memoria estourar!
Welcome to Java!
I wouldn’t worry unless it starts to cause issues – the Garbage Collector will come along and free up unused memory if/when it is needed for something else. It’s common for Java to “balloon” in memory usage and then it doesn’t want to “let go” of that memory unless it really has to since it takes processing time for it to expand it’s memory footprint (called the Heap and Stack). So basically, unless it’s absolutely necessary/needed by the system or by Java for something else, it’s common for Java to not release it’s used memory. (it’s greedy!)
Jeferson, boa tarde, eu utilizo a memoria java do openfire setada em 512-1024, basta alterar o arquivo de configuração.
Caso você use como serviço, altere o arquivo da pasta bin de nome:
openfire-service
Exemplo:
-Xms512m
-Xmx1024m
Cara eu não achei esse arquivo vou mandar a foto da minha pasta bin.
Fala Jeferson, conseguiu resolver teu problema?
Eu estou exatamente com esse problema aqui… a memória Java não passa do espaço alocado padrão de 247,5 MB.
Já fiz as configurações nos arquivos openfired.vmoptions e openfire-service.vmoptions (como serviço) e as alterações não são aplicadas.
OBS: Rodo o openfire num Windows Server 2008 Standard R2, com bd padrão do openfire.
Alguém com esse mesmo problema?