Excellent article:
http://www.tomcatexpert.com/blog/2010/07/20/basic-tomcat-clustering-grails-applications
Those useful and interesting technology snippets that I keep forgetting to write down until I need them again.
Friday, 25 March 2011
Sunday, 13 March 2011
Apoache Ab For Performace Tests
http://httpd.apache.org/docs/2.0/programs/ab.html
common script:
ab -c 50 -n 1000 -e "grails_list_test.csv" http://localhost:8080/benchmark/book/inzsertData?rows=100
common script:
ab -c 50 -n 1000 -e "grails_list_test.csv" http://localhost:8080/benchmark/book/inzsertData?rows=100
Enabling JConsole JMX Remote Monitoring of Tomcat
1) Make sure your CATALINA_HOME environment variable is set to the home directory of your catalina installation
2) Create a file runCatalina.bat somewhere hat looks like:
@startlocal
SET JAVA_OPTS= -Dcom.sun.management.jmxremote
SET JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.port=8086
SET JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.ssl=false
SET JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.authenticate=false
SET JAVA_OPTS=%JAVA_OPTS% -XX:PermSize=256m -XX:MaxPermSize=256m
SET JAVA_OPTS=%JAVA_OPTS% -server -Xms1024m -Xmx1024m
%CATALINA_HOME%\bin\catalina run
endlocal
3) If running Vista check this out, and apply the bugfix:
http://marxsoftware.blogspot.com/2008/01/making-jps-and-jconsole-work-with-java.html
I.e. need to make sure that "Everybody" has appropriate permission on the folder that JConsole uses
4) Run Catalina
5) Run jconsole (in your %JAVA_HOME%\bin directory).
6) Connect to the tomcat instancer remotely using hostname and 8086 (as defined above)
Instructions on what JConsole output means:
http://java.sun.com/javase/6/webnotes/trouble/TSG-VM/html/p1.html
2) Create a file runCatalina.bat somewhere hat looks like:
@startlocal
SET JAVA_OPTS= -Dcom.sun.management.jmxremote
SET JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.port=8086
SET JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.ssl=false
SET JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.authenticate=false
SET JAVA_OPTS=%JAVA_OPTS% -XX:PermSize=256m -XX:MaxPermSize=256m
SET JAVA_OPTS=%JAVA_OPTS% -server -Xms1024m -Xmx1024m
%CATALINA_HOME%\bin\catalina run
endlocal
3) If running Vista check this out, and apply the bugfix:
http://marxsoftware.blogspot.com/2008/01/making-jps-and-jconsole-work-with-java.html
I.e. need to make sure that "Everybody" has appropriate permission on the folder that JConsole uses
4) Run Catalina
5) Run jconsole (in your %JAVA_HOME%\bin directory).
6) Connect to the tomcat instancer remotely using hostname and 8086 (as defined above)
Instructions on what JConsole output means:
http://java.sun.com/javase/6/webnotes/trouble/TSG-VM/html/p1.html
WSUS and Group Policy
To force client to windows update via WSUS server
wuauclt /detectnow
To force group policy to be applied
wpupdate /force
wuauclt /detectnow
To force group policy to be applied
wpupdate /force
Word Useful
1) Alt f9 to toggle field codes.
2) field codes delimited by {}, but you have to menu Insert Field to get them in.
3) custom doc properties via {DocProperty "custom field name"}.
4) Margin height determines where the distinct part of the document starts and ends. This fixes header and footer height. Header and Footer determines how far from the edge of the document the header and the footer start.
5) For borders, you can set a point setting to change the distance between a border a and the text in the box
2) field codes delimited by {}, but you have to menu Insert Field to get them in.
3) custom doc properties via {DocProperty "custom field name"}.
4) Margin height determines where the distinct part of the document starts and ends. This fixes header and footer height. Header and Footer determines how far from the edge of the document the header and the footer start.
5) For borders, you can set a point setting to change the distance between a border a and the text in the box
Subscribe to:
Posts (Atom)