如何提高 Liferay 6.2 的性能?
How to improve Liferay 6.2 performance?
我在 JVM 1.7 上通过 运行 Tomcat 7.0.42 启动 Liferay 6.2,在具有 8G Ram 的 CentOS 64 位服务器上使用以下选项,但它仍然是 运行 低速!
-XX:NewSize=1024m -XX:MaxNewSize=1024m -XX:+UseConcMarkSweepGC -Xms3072m
-Xmx3072m -XX:MaxPermSize=512m
我应该怎么做才能提高性能?
问题已通过一些数据库修改解决。数据碎片是减少数据库响应时间的原因之一。组织和重建索引有助于解决这个问题。当碎片平均值在 5% 到 30% 之间时,组织索引 (ALTER INDEX REORGANIZE) 是解决方案,当平均值大于 30% 时,您应该重建索引。更多信息可以参考https://technet.microsoft.com/en-us/library/ms189858(v=sql.110).aspx。
收缩是另一种可以优化数据库的方法。
Shrinking data files recovers space by moving pages of data from the end of the file to unoccupied space closer to the front of the file. When enough free space is created at the end of the file, data pages at the end of the file can be deallocated and returned to the file system.
https://msdn.microsoft.com/en-us/library/ms189035.aspx
运行 以下命令允许 DB:
中的 10% 免费 space
DBCC SHRINKDATABASE (UserDB, 10);
在Liferay 控制面板--> 服务器管理中,您可以找到一些可以释放内存的操作。像 运行 垃圾收集器释放内存 Button 和其他操作。
我在 JVM 1.7 上通过 运行 Tomcat 7.0.42 启动 Liferay 6.2,在具有 8G Ram 的 CentOS 64 位服务器上使用以下选项,但它仍然是 运行 低速!
-XX:NewSize=1024m -XX:MaxNewSize=1024m -XX:+UseConcMarkSweepGC -Xms3072m
-Xmx3072m -XX:MaxPermSize=512m
我应该怎么做才能提高性能?
问题已通过一些数据库修改解决。数据碎片是减少数据库响应时间的原因之一。组织和重建索引有助于解决这个问题。当碎片平均值在 5% 到 30% 之间时,组织索引 (ALTER INDEX REORGANIZE) 是解决方案,当平均值大于 30% 时,您应该重建索引。更多信息可以参考https://technet.microsoft.com/en-us/library/ms189858(v=sql.110).aspx。 收缩是另一种可以优化数据库的方法。
Shrinking data files recovers space by moving pages of data from the end of the file to unoccupied space closer to the front of the file. When enough free space is created at the end of the file, data pages at the end of the file can be deallocated and returned to the file system. https://msdn.microsoft.com/en-us/library/ms189035.aspx
运行 以下命令允许 DB:
中的 10% 免费 space DBCC SHRINKDATABASE (UserDB, 10);
在Liferay 控制面板--> 服务器管理中,您可以找到一些可以释放内存的操作。像 运行 垃圾收集器释放内存 Button 和其他操作。