OpenJDK

How can I figure out what anonymous memory is being used for?

 ̄綄美尐妖づ 提交于 2019-12-11 18:08:39
问题 I have a program which is not running out of heap but for which the use of anonymous/native memory grows and grows. How can I go about figuring out what is using this memory? 回答1: Inspect a heap dump for DirectByteBuffer objects and what's holding onto them. File mappings would also be a cause, but you say anonymous mappings so that's probably not the issue here since those would be named. For some things native memory tracking may be useful too. If it's neither DirectByteBuffer instances nor

Does the current HotSpot JVM run in parallel by default?

感情迁移 提交于 2019-12-11 09:50:15
问题 I'm using this Java version: java version "1.6.0_24" OpenJDK Runtime Environment (IcedTea6 1.11.3) (suse-9.1-x86_64) OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode) When I start a java program, e.g. java TestApp by default, will the JVM run in parallel ? If so, which parts run in parallel ? I am interested in this, because I found if I use taskset -c 0 java TestApp to bind TestApp running on processor 0 , the first running time is much slower than java TestApp . Does this imply

Tomcat giving 404 error with servlets

守給你的承諾、 提交于 2019-12-11 07:44:53
问题 I have developed a Java web application using Tomcat 7 and Oracle JDK 1.7 with NeatBeans 7.3 . My application runs on my local pc without any errors. But after i hosted my application, I can't access servlets. It is giving me 404 error. I'm not used web.xml in my application to map servlets. I used annotation for it. Hosted server use Tomcat 7 and Open JDK 1.7 . What could be the issue ? How can i solve this ? New Update The place where i have purchased hosting gave me cPanel to upload files.

build openjdk on mac “JAVA_HOME is not defined correctly”

梦想的初衷 提交于 2019-12-11 01:52:20
问题 I am building openjdk on MAC and facing a problem like this: Error: JAVA_HOME is not defined correctly. We cannot execute /NO_BOOTDIR/bin/java the OS of my mac is 10.10.2. the openjdk is openjdk-7u40-fcs-src-b43-26_aug_2013 the ALT_BOOTDIR export ALT_BOOTDIR=/Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home the $JAVA_HOME echo $JAVA_HOME /Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home when I set JAVA_HOME and run 'make sanity', the error is like this: ERROR: Your JAVA_HOME

Which JDK for Android Development on Ubuntu 10.04 64-bit?

Deadly 提交于 2019-12-11 01:38:00
问题 Ubuntu 10.04 64-bit looks promising as a development environment for Android. I now have it up and running but I am stuck at the following decision point: Synaptic Package Manager has ' default-jdk ' ("Standard Java or Java compatible Development Kit"). sun.com has two "Java SE Development Kit 6u23 for Linux x64, Multi-language": Java SE Development Kit 6u23: jdk-6u23-linux-x64-rpm.bin Java SE Development Kit 6u23: jdk-6u23-linux-x64.bin Which one is the right one for Android development

Solr fails to serve JSPs, admin interface 404s

Deadly 提交于 2019-12-11 00:23:01
问题 I'm having trouble with solr. I'm running it on Ubuntu with OpenJDK: >> java -version java version "1.6.0_22" OpenJDK Runtime Environment (IcedTea6 1.10.2) (6b22-1.10.2-0ubuntu1~11.04.1) OpenJDK 64-Bit Server VM (build 20.0-b11, mixed mode) The admin interface should be served by Jetty 7, which is installed in the solr/example folder according to these instructions: http://wiki.apache.org/solr/SolrJetty#Update_Jetty On starting solr with 'start.jar' I see the following: >> java -jar 2012-05

深入理解jvm—编译

泄露秘密 提交于 2019-12-10 22:14:55
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> java开发一阵子了,想深入了解下jvm,所以在ubuntu下本地编译学习一下openjdk代码 1,java虚拟机有很多不稳定参数,以xx开头可以使用java -XX:+PrintFlagsFinal 查看; 2,编译java 下载open jdk 源码;http://download.java.net/openjdk/jdk8/ 放到ubuntu 虚拟机,解压,根据readme.build操作 configure: error: Could not find freetype! You might be able to fix this by running 'sudo apt-get install libfreetype6-dev'. 安装完依然这个鸟样。FUCK!最近工作忙,找个时间继续 -------------------------------------- 开始重编译一次 1,在ubuntu 14.04 64b,先安装需要的软件 sudo apt-get install build-essential gawk m4 libasound2-dev libxrender-dev xorg-dev xutils-dev x11proto-print-dev binutils libmotif3

How to update JDK on Jenkins Server cartridge (OpenShift)?

让人想犯罪 __ 提交于 2019-12-10 19:59:29
问题 The Jenkins Server cartridge (OpenShift) uses OpenJDK 7u55. How to update to OpenJDK 7u60 or 8u05 or Oracle JDK (7u60 or 8u05), please? 回答1: You can do this using OpenShift's action hooks. Add a script which will check for the existence of the JDK you want to use, and download it if it doesn't exist. For example, in .openshift/action_hooks/deploy , add this snippet: #! /bin/bash JDK_HOME=$OPENSHIFT_DATA_DIR/jdk1.8.0 if [[ ! -L $JDK_HOME && ! -d $JDK_HOME ]] then cd $OPENSHIFT_DATA_DIR wget

Callbacks in JSR223 Javascript, difference between Oracle JRE 1.6 and OpenJDK 1.6 (as installed on, say, Debian)

我的梦境 提交于 2019-12-10 18:48:24
问题 Given the following, running with Oracle JRE 6 gives the output boo, but OpenJDK 6 gives an exception javax.script.ScriptException: sun.org.mozilla.javascript.EvaluatorException: The choice of Java constructor replace matching JavaScript argument types (function,string) is ambiguous; candidate constructors are: class java.lang.String replace(char,char) class java.lang.String replace(java.lang.CharSequence,java.lang.CharSequence) (<Unknown source>#1) in <Unknown source> at line number 1 That's

Java keeps saying it can't find the jdbc mysql driver

心不动则不痛 提交于 2019-12-10 17:27:29
问题 Here's yet another question about jdbc's mysql driver. Considering the number of search results I got when I googled, I'm pretty bummed nothing I found in them worked for me. The error: hostname# java -cp /usr/share/java/mysql-connector.jar:/home/user JDBCTest java.sql.SQLException: No suitable driver found for jdbc:mysql://<db ip>:3306/dbname at java.sql.DriverManager.getConnection(DriverManager.java:596) at java.sql.DriverManager.getConnection(DriverManager.java:215) at JDBCTest.main