zoukankan      html  css  js  c++  java
  • myeclipse 内存优化

    MyEclipse占用内存很大,合理设置相关的参数:
    1、可以在MyEclipse中看到当前heap size的分配和使用情况,还可以强制执行垃圾回收。在MyEclipse的快捷方式上点击右键,在目标栏添加参数: -debug options -vm javaw.exe然后,在${MyEclipseHOme}/eclipse/根目录下,新建一个名为options的文件,不要后缀名。在该文件中加入内容:org.eclipse.ui/perf/showHeapStatus=true,重启MyEclipse,就可以在MyEclipse的左下角看到当前heap size的使用情况和分配情况了,还可以手工执行垃圾回收,看heap size不够时就来一次。

    2、有时还会提示内存不足:

    MyEclipse has detected that less than 5% of the 64MB of Perm 
    Gen (Non-heap memory) space remains. It is strongly recommended
    that you exit and restart MyEclipse with new virtual machine memory
    paramters to increase this memory.   Failure to do so can result in
    data loss. The recommended Eclipse memory parameters are: 
    eclipse.exe -vmargs -Xms128M -Xmx512M -XX:PermSize=64M -XX:MaxPermSize=128M
    查看${MyEclipseHOme}/eclipse/下的eclipse.ini文件
    -clean
    -showsplash
    com.genuitec.myeclipse.product.ide
    --launcher.XXMaxPermSize
    512m
    -vmargs    说明后面是VM的参数
    -Xms128m 虚拟机占用系统的最小内存
    -Xmx512m    虚拟机占用系统的最大内存
    -Duser.language=en 
    -XX:PermSize=128M         最小堆大小。一般报内存不足时,都是说这个太小,视机器内存大小来设置。
    -XX:MaxPermSize=256M   最大堆大小。这个也适当大些

    -Xmx512M的5%为25.6M,理论上要求-Xmx的数值与-XX:MaxPermSize必须大于25.6M

    3、tomcat 内存优化

  • 相关阅读:
    node + express 搭建服务器,修改为自动重启服务器
    在sublime上运行node
    node + express本地搭建服务器,开启一个新的项目
    关于数据库的一些基本操作语句
    8.数据库编程
    2.关于偏函数
    7.多线程编程
    1.关于__call__的很有意思的用法
    6.python中的网络编程
    4.python中常用的魔法方法(长期更新)
  • 原文地址:https://www.cnblogs.com/xinzhuangzi/p/4100483.html
Copyright © 2011-2022 走看看