Immortal Memory vs PermGen

I know that with Java SE there are 3 memory areas (young, old gen and perm gen). Perm Gen being where the metadata of classes lives. With RealTime do these objects get stored in the Immortal Memory area? As far as i can tell, based off information provided in the Real-Time Java Programming with Java RTS, there is no perm gen memory area with RealTime. What confuses me is when i run out of perm space i have to increment the perm size (which i assume is permgen) via the java proc flag XX:MaxPermSize
any info would be greatly appreciated. Thanks!

No such thing as “too many songs”. :-D
See: How to Transfer Music Between the Computer and iPod
And: Transfer music manually
The iPod offers three ways to transfer music from your computer. You can select one of the following update modes from the iPod Preferences menu in iTunes (Edit=>Preferences=>'iPod' tab):
1) Automatically update all songs and playlists. This is the default mode, in which your entire music library, including playlists, is automatically synced to your iPod. If the music library on your computer exceeds the iPod storage capacity, you are prompted to select a different update method.
2) Automatically update selected playlists only. With this option, iTunes automatically copies the playlists you have selected to the iPod when you connect it to the computer.
3) Manually manage songs and playlists. You can also choose to transfer music to the iPod manually. This allows you to drag and drop individual songs and playlists from iTunes to the iPod.
Manage the iPod either Manually or via Selected Playlists.
How to Create a Smart Playlist
Deleting Songs or Playlists from your iPod

Similar Messages

  • Java.lang.AssertionError: java.lang.OutOfMemoryError: PermGen space

    Given:
    fabio@nodo1:/Middleware/user_projects/domains/domain1/bin$ grep USER_MEM_ARGS setDomainEnv.sh
    # USER_MEM_ARGS - The variable to override the standard memory arguments
    USER_MEM_ARGS="-Xms1024m -Xmx1024m -XX:PermSize=128m -XX:MaxPermSize=512m"
    export USER_MEM_ARGS
    # IF USER_MEM_ARGS the environment variable is set, use it to override ALL MEM_ARGS values
    if [ "${USER_MEM_ARGS}" != "" ] ; then
         MEM_ARGS="${USER_MEM_ARGS}"
    fabio@nodo1:/Middleware/user_projects/domains/domain1/bin$
    Then, in Weblogic admin console, I start the ManagedServer registered in cluster1 asigned to that UnixMachine.
    ManagedServer1.log reports:
    ####<May 26, 2010 10:01:40 AM CST> <Notice> <WebLogicServer> <nodo1> <ManagedServer1> <main> <<WLS Kernel>> <> <> <1274889700427> <BEA-000365> <Server state changed to FAILED>
    ####<May 26, 2010 10:01:40 AM CST> <Error> <WebLogicServer> <nodo1> <ManagedServer1> <main> <<WLS Kernel>> <> <> <1274889700428> <BEA-000383> <A critical service failed. The server will shut itself down>
    ####<May 26, 2010 10:01:40 AM CST> <Notice> <WebLogicServer> <nodo1> <ManagedServer1> <main> <<WLS Kernel>> <> <> <1274889700465> <BEA-000365> <Server state changed to FORCE_SHUTTING_DOWN>
    ####<May 26, 2010 10:01:41 AM CST> <Error> <JMX> <nodo1> <ManagedServer1> <[STANDBY] ExecuteThread: '3' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1274889701769> <BEA-149500> <An exception occurred while registering the MBean com.bea:ServerRuntime=ManagedServer1,Name=ManagedServer1_/uddiexplorer,ApplicationRuntime=uddiexplorer,Type=WebAppComponentRuntime.
    javax.management.RuntimeErrorException: Error thrown in preRegister method
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.preRegisterInvoke(DefaultMBeanServerInterceptor.java:1015)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(DefaultMBeanServerInterceptor.java:938)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(DefaultMBeanServerInterceptor.java:917)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(DefaultMBeanServerInterceptor.java:312)
         at com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(JmxMBeanServer.java:482)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase$27.run(WLSMBeanServerInterceptorBase.java:714)
         at java.security.AccessController.doPrivileged(Native Method)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase.registerMBean(WLSMBeanServerInterceptorBase.java:709)
         at weblogic.management.mbeanservers.internal.JMXContextInterceptor.registerMBean(JMXContextInterceptor.java:448)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase$27.run(WLSMBeanServerInterceptorBase.java:712)
         at java.security.AccessController.doPrivileged(Native Method)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase.registerMBean(WLSMBeanServerInterceptorBase.java:709)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServer.registerMBean(WLSMBeanServer.java:444)
         at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:45)
         at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:106)
         at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
         at weblogic.management.provider.core.RegistrationManagerBase.invokeRegistrationHandlers(RegistrationManagerBase.java:180)
         at weblogic.management.provider.core.RegistrationManagerBase.register(RegistrationManagerBase.java:110)
         at weblogic.management.runtime.RuntimeMBeanDelegate.register(RuntimeMBeanDelegate.java:310)
         at weblogic.management.runtime.RuntimeMBeanDelegate.<init>(RuntimeMBeanDelegate.java:248)
         at weblogic.j2ee.ComponentRuntimeMBeanImpl.<init>(ComponentRuntimeMBeanImpl.java:57)
         at weblogic.servlet.internal.WebAppRuntimeMBeanImpl.<init>(WebAppRuntimeMBeanImpl.java:53)
         at weblogic.servlet.internal.WebAppServletContext.prepare(WebAppServletContext.java:1118)
         at weblogic.servlet.internal.HttpServer.doPostContextInit(HttpServer.java:449)
         at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:424)
         at weblogic.servlet.internal.WebAppModule.registerWebApp(WebAppModule.java:924)
         at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:356)
         at weblogic.application.internal.flow.ScopedModuleDriver.prepare(ScopedModuleDriver.java:176)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:391)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:59)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:43)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:1221)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:367)
         at weblogic.application.internal.SingleModuleDeployment.prepare(SingleModuleDeployment.java:39)
         at weblogic.application.internal.BackgroundDeploymentService$1.next(BackgroundDeploymentService.java:348)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.BackgroundDeploymentService$BackgroundDeployAction.run(BackgroundDeploymentService.java:273)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused By: java.lang.AssertionError: java.lang.OutOfMemoryError: PermGen space
         at weblogic.management.jmx.modelmbean.NotificationTranslatorBuilder.instantiateNotificationTranslator(NotificationTranslatorBuilder.java:51)
         at weblogic.management.jmx.modelmbean.NotificationTranslatorBuilder.instantiateNotificationTranslator(NotificationTranslatorBuilder.java:22)
         at weblogic.management.jmx.modelmbean.WLSModelMBean.bindNotifications(WLSModelMBean.java:116)
         at weblogic.management.jmx.modelmbean.WLSModelMBean.preRegister(WLSModelMBean.java:1147)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.preRegisterInvoke(DefaultMBeanServerInterceptor.java:1010)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(DefaultMBeanServerInterceptor.java:938)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(DefaultMBeanServerInterceptor.java:917)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(DefaultMBeanServerInterceptor.java:312)
         at com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(JmxMBeanServer.java:482)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase$27.run(WLSMBeanServerInterceptorBase.java:714)
         at java.security.AccessController.doPrivileged(Native Method)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase.registerMBean(WLSMBeanServerInterceptorBase.java:709)
         at weblogic.management.mbeanservers.internal.JMXContextInterceptor.registerMBean(JMXContextInterceptor.java:448)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase$27.run(WLSMBeanServerInterceptorBase.java:712)
         at java.security.AccessController.doPrivileged(Native Method)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase.registerMBean(WLSMBeanServerInterceptorBase.java:709)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServer.registerMBean(WLSMBeanServer.java:444)
         at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:45)
         at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:106)
         at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
         at weblogic.management.provider.core.RegistrationManagerBase.invokeRegistrationHandlers(RegistrationManagerBase.java:180)
         at weblogic.management.provider.core.RegistrationManagerBase.register(RegistrationManagerBase.java:110)
         at weblogic.management.runtime.RuntimeMBeanDelegate.register(RuntimeMBeanDelegate.java:310)
         at weblogic.management.runtime.RuntimeMBeanDelegate.<init>(RuntimeMBeanDelegate.java:248)
         at weblogic.j2ee.ComponentRuntimeMBeanImpl.<init>(ComponentRuntimeMBeanImpl.java:57)
         at weblogic.servlet.internal.WebAppRuntimeMBeanImpl.<init>(WebAppRuntimeMBeanImpl.java:53)
         at weblogic.servlet.internal.WebAppServletContext.prepare(WebAppServletContext.java:1118)
         at weblogic.servlet.internal.HttpServer.doPostContextInit(HttpServer.java:449)
         at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:424)
         at weblogic.servlet.internal.WebAppModule.registerWebApp(WebAppModule.java:924)
         at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:356)
         at weblogic.application.internal.flow.ScopedModuleDriver.prepare(ScopedModuleDriver.java:176)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:391)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:59)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:43)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:1221)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:367)
         at weblogic.application.internal.SingleModuleDeployment.prepare(SingleModuleDeployment.java:39)
         at weblogic.application.internal.BackgroundDeploymentService$1.next(BackgroundDeploymentService.java:348)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.BackgroundDeploymentService$BackgroundDeployAction.run(BackgroundDeploymentService.java:273)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused By: java.lang.OutOfMemoryError: PermGen space
         at java.lang.Class.getDeclaredMethods0(Native Method)
         at java.lang.Class.privateGetDeclaredMethods(Class.java:2427)
         at java.lang.Class.getMethod0(Class.java:2670)
         at java.lang.Class.getMethod(Class.java:1603)
         at weblogic.management.jmx.modelmbean.PropertyChangeNotificationTranslator.<init>(PropertyChangeNotificationTranslator.java:66)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
         at weblogic.management.jmx.modelmbean.NotificationTranslatorBuilder.instantiateNotificationTranslator(NotificationTranslatorBuilder.java:45)
         at weblogic.management.jmx.modelmbean.NotificationTranslatorBuilder.instantiateNotificationTranslator(NotificationTranslatorBuilder.java:22)
         at weblogic.management.jmx.modelmbean.WLSModelMBean.bindNotifications(WLSModelMBean.java:116)
         at weblogic.management.jmx.modelmbean.WLSModelMBean.preRegister(WLSModelMBean.java:1147)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.preRegisterInvoke(DefaultMBeanServerInterceptor.java:1010)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(DefaultMBeanServerInterceptor.java:938)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(DefaultMBeanServerInterceptor.java:917)
         at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(DefaultMBeanServerInterceptor.java:312)
         at com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(JmxMBeanServer.java:482)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase$27.run(WLSMBeanServerInterceptorBase.java:714)
         at java.security.AccessController.doPrivileged(Native Method)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase.registerMBean(WLSMBeanServerInterceptorBase.java:709)
         at weblogic.management.mbeanservers.internal.JMXContextInterceptor.registerMBean(JMXContextInterceptor.java:448)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase$27.run(WLSMBeanServerInterceptorBase.java:712)
         at java.security.AccessController.doPrivileged(Native Method)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServerInterceptorBase.registerMBean(WLSMBeanServerInterceptorBase.java:709)
         at weblogic.management.jmx.mbeanserver.WLSMBeanServer.registerMBean(WLSMBeanServer.java:444)
         at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:45)
         at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:106)
         at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
         at weblogic.management.provider.core.RegistrationManagerBase.invokeRegistrationHandlers(RegistrationManagerBase.java:180)
         at weblogic.management.provider.core.RegistrationManagerBase.register(RegistrationManagerBase.java:110)
         at weblogic.management.runtime.RuntimeMBeanDelegate.register(RuntimeMBeanDelegate.java:310)
    >
    ####<May 26, 2010 10:01:41 AM CST> <Info> <Cluster> <nodo1> <ManagedServer1> <main> <<WLS Kernel>> <> <> <1274889701790> <BEA-000158> <Server has stopped sending cluster heartbeats and announcements. It is still receiving heartbeats and announcements from other cluster members.>
    ####<May 26, 2010 10:01:41 AM CST> <Notice> <Cluster> <nodo1> <ManagedServer1> <main> <<WLS Kernel>> <> <> <1274889701793> <BEA-000163> <Stopping "async" replication service>
    What is the exact tuning I need to start up a simple managedserver in Weblogic 10.3.2, Linux Ubuntu ?

    Hi,
    I doubt that the following USER_MEM_ARGS which u have mentioned in the *"setDomainEnv.sh"* is not taking effect....
    USER_MEM_ARGS="-Xms1024m -Xmx1024m -XX:PermSize=128m -XX:MaxPermSize=512m"
    Can u check the STDOUT of the Server or first few lines of Server Log....there u will be able to see that what value it is taking actually to startup. Sometimes it happens if we set the MEM_ARGS values in if---else block then mistakenly it takes the default values....
    Because 512M Memory for PermGen is enough for most of the Applications and Servers.
    One more thing .... How r u starting your Servers ...Using StartScripts or using NodeManager (through AdminConsole)? Because there are different ways of setting the Memory Arguments for these two scenarios. Like mentioned in the following link: http://weblogic-wonders.com/weblogic/2010/03/26/nodemanager-based-managedservers-setting-mem_args/
    Thanks
    Jay SenSharma
    http://weblogic-wonders.com/weblogic  (WebLogic Wonders Are Here)

  • Classloading in scoped memory

    Hello,
    currently I am trying to figure out how classloading in scoped memory can be done.
    I tried the following code which is executed by a RealtimeThread:
    public void run() {
    // allocation context is: heap
    final ScopedMemory scopeA = new LTMemory(50000);
    final ScopedMemory scopeB = new LTMemory(50000);
    // RtjTestClassloader simply loads a class from a .class-file that
    // exists somewhere in the filesystem
    final ClassLoader cloader = new RtjTestClassloader();
    try {
        // loading a class in scoped memory fails if no class was loaded
        // using that classloader before entering the scope
        Class<?> c = cloader.loadClass(OTHER_CLASS);
    } catch (ClassNotFoundException e) {
        System.exit(1);
    scopeA.enter(new Runnable() {
        public void run() {
            try {
                System.err.println("scopeA entered");
                Class<?> clazz = cloader.loadClass(CLASS);
                TestClass tc = (TestClass)clazz.newInstance();
                System.err.println("scopeA memory consumed: " + scopeA.memoryConsumed());
            } catch (Exception e) {
                e.printStackTrace();
    scopeB.enter(new Runnable() {
        public void run() {
            try {
                System.err.println("scopeB entered");
                System.err.println("scopeA memory consumed: " + scopeA.memoryConsumed());
                Class<?> clazz = cloader.loadClass(CLASS);
                TestClass tc = (TestClass)clazz.newInstance();
                System.err.println("scopeB memory consumed: " + scopeB.memoryConsumed());
            } catch (Exception e) {
                e.printStackTrace();
    }the output is:
    scopeA entered
    scopeA memory consumed: 16240
    scopeB entered
    scopeA memory consumed: 0
    scopeB memory consumed: 1896
    If the Class object would be allocated in scopeA it would not be possible to
    use that Class object in scopeB since classes can only be loaded once per
    classloader (the high memory consumption of scopeA is probably because of
    opening a file). That implies that classes must be allocated on the heap or in
    immortal memory. Is that the case in the Sun Java RTS?
    Furthermore the above code fails when run in TimeSys JVM. Trying to load the
    class in scopeA causes an IllegalAsignmentError when defineClass(...) is called.
    I suspect that is due to the storing of the reference to the loaded class for
    later use. Which would again imply that TimeSys really allocates memory for
    Class objects inside the scope.
    The same Error happened when I tried to load a class with a classloader that was
    instanciated in scoped memory (using Sun Java RTS).
    Another interesting notice is that the loading of the class in scopeA only works
    if the classloader was used to load a class in heap or immortal memory before
    entering the scope.
    What happens when a class is being loaded and scopes are involved? Is there an
    approach that should be used when having multiple classloaders and scopes?
    And is there anything in the RTSJ Spec on that? I wasn't able to find anything.
    Thank you,
    Matthias
    Edited by: user13696541 on 11.01.2011 13:46

    Hello,
    I have to push this topic, because it addresses a common question about the scenario of (user-defined) class loading in Real-Time Java, especially when mixed up with Scope usage.
    I'm wondering if user-defined Class Loading has been addressed yet in the RTSJ?
    Because of the absence of any statement about it within the RTSJ specification (or any of the well-known books about RTSJ),
    we assumed the problem is implementation-specific.
    Therefore we decided to do some tests, which Matthias has presented here in his previous post.
    The cited code above exemplifies a simple class loading scenario executed by a Real-Time JVM:
    A RealTimeThread enters a scope A and uses a Class Loader instance "cloader" residing on the Heap in order to load a certain class "CLASS" within that scope.
    On success, I would expect that the entire control structures defining the class "CLASS" are situated within the scope A.
    As you can see the program output, after the class loading procedure Class<?> clazz = cloader.loadClass(CLASS),
    there are about 16 Kbytes of scope A in use (e.g. something happened on class loading within that scope).
    Afterwards, the RT-Thread leaves the scope A, and according to it's memory usage (= 0) the latter seems to be already freed (e.g. no active threads therein anymore).
    This would impose, that the definition structures (or parts of them) of the class "CLASS" that were placed within the scope A are lost now, wouldn't it?
    However, this seems not to be the case.
    The RT-Thread enters a new scope B and tries to reload the same class "CLASS" with the same "cloader" instance residing on the heap.
    I would expect, that the "CLASS" is either redefined in some way within scope B, or that the JVM throws a kind of error since the definition for "CLASS" has been already lost with scope A.
    Nevertheless, "cloader" simply returns a valid Class object for the "CLASS" which can be further instantiated and used without any problems.
    But, the memory usage of scope B is much lower (= 1896 bytes) than that of scope A after defining the "CLASS".
    This raises a common question:
    1. Where does the JRTS JVM place Class Objects of newly defined classes (in terms of the Java "Class" object and the corresponding JVM-internal definition structures)?
    a) The current allocation scope of the Thread actually defining a class?
    b) Some other scope (e.g. a class cache) ?
    2. What happens in the scenario above? What is allocated on class loading within scope A, and how is it possible to have a valid class definition of "CLASS" since scope A has been freed?
    We've tried another use case, having a separate class loader object "rtcl" instantiated within a scope C, which again loads the class "CLASS" within the same scope C:
    mc.enter(new Runnable() {
                    public void run() {
                        try {
                            ClassLoader rtcl = new RtjTestClassloader();
                            Class c = rtcl.loadClass(CLASS3);
                            TestClass cl3 = (TestClass) c.newInstance();
                        } catch (Exception e) { e.printStackTrace(); }
    Output:
    Exception in thread "RealtimeThread-0" javax.realtime.IllegalAssignmentError
         at java.util.HashMap$Entry.<init>(HashMap.java:730)
         at java.util.HashMap.addEntry(HashMap.java:797)
         at java.util.HashMap.put(HashMap.java:431)
         at java.util.HashSet.add(HashSet.java:194)
         at java.lang.ClassLoader.checkPackageAccess(ClassLoader.java:346)
         at java.lang.ClassLoader.defineClass1(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:630)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:475)
         at rtjtests.classloader.RtjTestClassloader.loadClass(RtjTestClassloader.java:35)
         at rtjtests.classloader.ClassLoadingInScopeTest$3.run(ClassLoadingInScopeTest.java:138)
         at javax.realtime.MemoryArea.enter0(Native Method)
         at javax.realtime.MemoryArea.enter(MemoryArea.java:190)
         at javax.realtime.ScopedMemory.enter(ScopedMemory.java:191)
         at rtjtests.classloader.ClassLoadingInScopeTest.run(ClassLoadingInScopeTest.java:114)3. If I interpret the programs output right,
    - Class Loaders in JRTS seem to use traditional java.util.HashMap objects for storing references to their loaded classes
    - The class loading procedure really placed something on the scope (i.e. the class's Class object?)
    - For some reasons the class loader cannot store a reference to that object on the scope within its HashMap.
    Could anyone give us a short explaination of the internal representation of class objects and their corresponding class loaders?
    What are the reasons the RT-JVM behavior described above during our tests?
    Is there any intended or standardized way for the usage of extended class loading within RTSJ scopes?
    We would appreciate any help !
    Sincerely,
    Vladimir
    Edited by: vladimir.nikolov on Jan 17, 2011 5:05 AM
    Edited by: vladimir.nikolov on Jan 17, 2011 5:06 AM
    Edited by: vladimir.nikolov on Jan 17, 2011 5:07 AM

  • AspectJ load time weaving AnnotatedNoClassDefFoundError

    I am trying to use AspectJ load time weaving on an application running on OC4J 10.1 on JRE 1.5. I get AnnotatedNoClassDefFoundError with Missing class: org.aspectj.runtime.internal.AroundClosure message.
    Here is what I am doing:
    1. Starting the server with JVM argument -javaagent:aspectjweaver.jar to enable AspectJ load time weaving.
    2. I put an AspectJ library MaintainJAspect.jar under j2ee\home\applib folder.
    3. I put the aspect defined in aop.xml at j2ee\home\applib\META-INF\aop.xml .
    The aspect defined in aop.xml is properly weaved into the application class (I can see in the dumped source). But when the application is running, it fails with the message pasted below.
    My question is, while it says that the missing class is available in oc4j classloader, which is parent of system and application class loaders, why is it not available to my application?
    Thanks in advance,
    Choudary Kothapalli.
    oracle.classloader.util.AnnotatedNoClassDefFoundError:
         Missing class: org.aspectj.runtime.internal.AroundClosure
         Dependent class: com.maintainj.aspect.ExecutionAspect
         Loader: global.libraries:1.0
         Code-Source: /C:/Programs/oc4j10/j2ee/home/applib/MaintainJAspect.jar
         Configuration: <code-source> in /c:/Programs/oc4j10/j2ee/home/config/server.xml
    The missing class is available from the following locations:
         1. Code-Source: /C:/Programs/oc4j10/j2ee/home/maintainj/aspectjweaver.jar (from system property java.class.path)
         This code-source is available in loader oc4j:10.1.3.
         at oracle.classloader.PolicyClassLoader.handleClassNotFound (PolicyClassLoader.java:2068) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at oracle.classloader.PolicyClassLoader.internalLoadClass (PolicyClassLoader.java:1679) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at oracle.classloader.PolicyClassLoader.loadClass (PolicyClassLoader.java:1635) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at oracle.classloader.PolicyClassLoader.loadClass (PolicyClassLoader.java:1620) [C:/Programs/oc4j10/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@9627532]
         at java.lang.ClassLoader.loadClassInternal (ClassLoader.java:319) [jre bootstrap, by jre.bootstrap:1.5.0_08]
         at com.maintainj.aspect.ExecutionAspect.ajc$around$com_maintainj_aspect_ExecutionAspect$1$133697c9proceed (ExecutionAspect.aj:1) [C:/Programs/oc4j10/j2ee/home/applib/MaintainJAspect.jar (from <code-source> in /c:/Programs/oc4j10/j2ee/home/config/server.xml), by global.libraries:1.0]
         at com.maintainj.aspect.ExecutionAspect.ajc$around$com_maintainj_aspect_ExecutionAspect$1$133697c9 (ExecutionAspect.aj:42) [C:/Programs/oc4j10/j2ee/home/applib/MaintainJAspect.jar (from <code-source> in /c:/Programs/oc4j10/j2ee/home/config/server.xml), by global.libraries:1.0]
         at simple.SimpleServlet.<init> (SimpleServlet.java:12) [C:/Programs/oc4j10/j2ee/home/applications/SimpleWeb/SimpleWeb/WEB-INF/classes/ (from WEB-INF/classes/ in C:\Programs\oc4j10\j2ee\home\applications\SimpleWeb\SimpleWeb\WEB-INF\classes), by SimpleWeb.web.SimpleWeb:0.0.0]

    Not sure what you mean by "support". AspectJ rewrites bytecodes so the VM will just execute them. You'll probably encounter increased memory usage with load-time weaving as class loading/initialization occurs in Immortal memory. Also load-time weaving won't be compatible with Java RTS's Initialization Time Compilation (ITC) feature ... or at least not the pre-initialization part. It's likely that no-heap threads won't work well running weaved code if there are any references back to heap-allocated AspectJ runtime objects, and similarly (like most libraries) it's not likely to work from scoped memory.
    HTH.
    David Holmes

  • GetPreemptionLatency in Sun's RTJ

    Hello,
    I've tried the following piece of code to obtain information about the interference introduced by the garbage collector:
    System.out.println( RealtimeSystem.currentGC().getPreemptionLatency());in the following system:
    - Ubuntu (9.1)
    - Real-time Linux Patch (linux-rt package)
    - Sun's VM
    - 1,6 Ghz Laptop
    My results showed that the preemption time for JRTS 2.1 is 1 ms. After testing this value empirically, running one low-priority thread which is executing System.gc() and measuring the interference on a high-priority NoHeapRealTimeThread, some questions come to my mind.
    - Is this the maximum interference any NoHeapRealTimeThreadshould expected from the garbage collector?
    - How is it possible that a garbage collector obtain this value?
    - Is there any strategy to reduce the preemption time?
    Thanks,
    Pablo
    Edited by: pbasanta@ on Dec 3, 2009 10:41 AM

    Hi Bertrand,
    Bertrand.Delsart wrote:
    Hi Pablo,
    By construction, NHRTs do not have any reference to the Heap on their stack. Hence the RTGC need not scan their >stack.
    So, if you have a NHRT that has a reference to an object in immortal memory that has a connection to an object allocated in the heap.
    (NHRT->[scopedmemory or immortal object]->Heap-object)
    Then, according to your comment, el heap object is not destroyed if:
    1) There is another object in immortal memory that has a reference to the object (even if the object is not reachable)
    2) The whole scope (*LTMemory*) is not reclaimed (even if the object is not reachable).
    >
    The interference of the RTGC logic on the NHRT is negligible (mainly activating and deactivating barriers). We can still reach latencies in the tens of microseconds with NHRT when the RTGC is running.
    Of course, at this level of determinism, you have to be careful with hardware issues (cache misses, bus saturation, ...) and use for instance processor sets and interrupt shielding.In this case, the garbage collector is similar to another thread. Nice solution .;)
    Thanks,
    Pablo
    Edited by: pbasanta@ on Dec 4, 2009 4:16 AM

  • AspectJ with real time java

    Hi
    Does real time java supports aspectJ with Load-time weaving ( LTW ) ? ( compile time weaving )

    Not sure what you mean by "support". AspectJ rewrites bytecodes so the VM will just execute them. You'll probably encounter increased memory usage with load-time weaving as class loading/initialization occurs in Immortal memory. Also load-time weaving won't be compatible with Java RTS's Initialization Time Compilation (ITC) feature ... or at least not the pre-initialization part. It's likely that no-heap threads won't work well running weaved code if there are any references back to heap-allocated AspectJ runtime objects, and similarly (like most libraries) it's not likely to work from scoped memory.
    HTH.
    David Holmes

  • CF 11 very slow to load web pages - up to 10 seconds

    Running CF11  Windows 2012 r2 Data center IIS 8 4Gb RAM 4 cores no adjusments have been made to default CF11 - waiting from [email protected] to send me the hotfix hf1100-3776060.123 or hf1100-3776060.jar as services keep stopping
    What can I do? My CF 8 is running way faster than this
    thank you!

    Hello,
    This CF11 blog entry may help:
    http://blogs.coldfusion.com/post.cfm/coldfusion-11-iis-connector-tuning
    I guess CF8 is on 32 bit and CF11 on 64 bit. So you could do well to adjust the initial and maximum memory plus PermGen. These settings in CF11admin >    Server Settings > Java and JVM
    Minimum JVM Heap Size (in MB) 256
    Maximum JVM Heap Size (in MB) 512
    JVM Arguments
    -XX:MaxPermSize=192m
    EG 1024 3072 and 512m respectively.
    Well that is not exactly CF Java tuning more of a try this and see. You could always perform some CF Java and CF tomcat monitoring to know better what values to apply.
    HTH, Carl.

  • Problem with PermGen memory (Java) - Tomcat Server - Business Object XI

    We have installed Business Objects XI on a W2003 Standard with SP2 (x86), using Tomcat as web server and MySQL as DBMS. The server has 4 GB of RAM and dual-core processor. From the beginning we have been given the memory problems of the Java virtual machine. The exception that occurs is of type "java.lang.OutOfMemoryError: PermGen space failure". We modify environment variables (JAVA_OPTS) -XX: PermSize = 256m and-XX: MaxPermSize = 512m and install the monitor LambdaProbe to see the use made of memory. We note that at no time was the PermGen memory indicated by these variables, continuing in that has a default 64MB. For this reason we decided to change the Tomcat 5.5 BO included in the version 6.0.20 and also updated Java to version 1.6.0_18-b07, and make deployment by wdeploy.bat file that comes with BusinessObjects (changing config.tomcat55 and tomcat55.xml). The deployment was successful and everything works, but as with the previous version of Java / Tomcat, shortly PermGen memory fills and returns to "hang". In this latest version of Tomcat installed as a service, do not use environment variables, use an application, "Configure Tomcat", which is a tab to pass parameters to the JVM. After looking at many sites, I have seen to be putting "-D" to pass the parameter. Currently this is my configuration:
    -Dcatalina.home = C: \ Program Files \ Apache Software Foundation \ Tomcat 6.0-Dcatalina.base = C: \ Program Files \ Apache Software Foundation \ Tomcat 6.0-Djava.endorsed.dirs = C : \ Program Files \ Apache Software Foundation \ Tomcat 6.0 \ endorsed-Djava.io.tmpdir = C: \ Program Files \ Apache Software Foundation \ Tomcat 6.0 \ temp-Djava.util.logging.manager = org.apache.juli . ClassLoaderLogManager-Djava.util.logging.config.file = C: \ Program Files \ Apache Software Foundation \ Tomcat 6.0 \ conf \ logging.properties-Dcom.sun.management.jmxremote-D-Xms2g-D-Xmx2g-D -XX: + UseConcMarkSweepGC-D-XX:-D PermSize = 256m-XX: MaxPermSize = 512m-Daf.configdir = C: / Program Files / Business Objects / Dashboard and Analytics 12.0-D-verbose: gc-D-XX : + PrintGCTimeStamps-D-XX: + PrintGCDetails
    I tried changing the values of-XX: PermSize and XX: MaxPermSize, and modifying the various policies of the Garbage Collector (-XX: + UseConcMarkSweepGC,-XX: + UseParNewGC,-XX: + UseParallelGC, ...), but nothing. Any idea how to get change the value of the report? Or how to solve this problem?
    Thank you!

    Victor,
    Is the Product you are using BusinessObjects Enterprise XI (Release 1)?
    With XIR2 and XI31, Tomcat 5.0 and Tomcat 5.5 are included with the software, and when installed with the BOE installer, you will get an application installed to the startmenu named "Tomcat Configuration".
    Using this "Tomcat Configuration" utility, there are several configuration options available.  On the JAVA tab, you will see the JAVA_OPTS that are set (These are prefixed with "-D") and also your initial and max memory sizes are listed at the bottom (Max 1024 by default in XI31).
    Here is the default setting for permsize in XI31 Tomcat:
    -XX:MaxPermSize=256M
    From your post, your issue might be the spaces in between your values (there should be no spaces, each "-" parameter on its own line).
    I would suggest starting Tomcat and reviewing your stdout.log file to review what options were set.
    Hope that helps
    -Brian

  • Weblogic Optional Packages - Permgen Memory Space

    Hi,
    We are packaging some common jars as Optional Packages in weblogic and using them from different EAR files.We know for classes in side the EAR, each classloader creates individual clazz objects in the permgen space.
    For classes inside the Optional packages and which are referenced in multiple EAR,does weblogic create seperate clazz instances in the permgen space for each classloader? If so then it would mean that classes inside the Optional Package will be created multiple times in the permgen space (attributed to different classloaders)
    Any idea on the behaviour will be highly appreciated.Is the situation same with shared libraries ?

    Depends on where your optinal classes are located.
    If you insert them in the system (or server) classloader they will be loaded once, by the system
    classloader. You can use the ${DOMAIN_HOME}/lib directory for this purpose. The jars located in
    this directory will be picked up and added to the end of the server classpath at server startup.
    The jars will be ordered lexically in the classpath.
    If you are using shared libraries, these shared libraries will be merged at runtime with the
    applications referencing them, so they will be local to the application and to my knowledge
    loaded by the classloader of the application and not a separate shared library classloader. Thus
    if you reference the shared library from multiple applications, the shared libraries get merged
    multiple times and loaded multiple times. The reason is that WebLogic uses classloading
    isolation between the deployed applications, so that from a classloading perspective
    other applications do not bother other applications.

  • Mbean Null  /// PermGen // Manifest.mf  --- Many many errors.

    Hello,
    im setting up, an Liferay 6.1.1 on an WebLogic 11G all based on Linux Redhead.
    At the moment i get this error after 5 hours using Google, it still cant help me with MBean null errors :-/
    My problem: Weblogic installtion was succesfull and without problems.
    I connected Weblogic with the Oracle DB -> no problems.
    I added the liberays needed for Liferay -> no problems.
    I deployed liferay -> first error (time out, its not acitvated but deployed)
    I activated it again (top right corner) -> all perfect
    So i watched the deployment and Weblogic said me its running but i cant connect on it. (Yep i used the right link)
    Then i tried to restart Weblogic - an now i got this mistakes ...
    Has someone hints how i can eliminate this errors?
    best regards,
    Jens
    <JMX> <BEA-149500> <An exception occurred while registering the MBean null.
    java.lang.IllegalArgumentException: Registered more than one instance with the same objectName : com.bea:ServerRuntime=AdminServer,Name=liferay,Type=ApplicationRuntime new:[email protected]a existing [email protected]4
    at weblogic.management.jmx.ObjectNameManagerBase.registerObject(ObjectNameManagerBase.java:168)
    at weblogic.management.mbeanservers.internal.WLSObjectNameManager.lookupObjectName(WLSObjectNameManager.java:131)
    at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:87)
    at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
    at weblogic.management.provider.core.RegistrationManagerBase.invokeRegistrationHandlers(RegistrationManagerBase.java:180)
    Truncated. see log file for complete stacktrace
    >
    <May 24, 2013 3:36:18 PM CEST> <Error> <JMX> <BEA-149500> <An exception occurred while registering the MBean null.
    java.lang.IllegalArgumentException: Registered more than one instance with the same objectName : com.bea:ServerRuntime=AdminServer,Name=default,ApplicationRuntime=liferay,Type=WorkManagerRuntime new:weblogic.work.WorkManagerRuntimeMBeanImpl@11e5966b existing weblogic.work.WorkManagerRuntimeMBeanImpl@550b98aa
    at weblogic.management.jmx.ObjectNameManagerBase.registerObject(ObjectNameManagerBase.java:168)
    at weblogic.management.mbeanservers.internal.WLSObjectNameManager.lookupObjectName(WLSObjectNameManager.java:131)
    at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:87)
    at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
    at weblogic.management.provider.core.RegistrationManagerBase.invokeRegistrationHandlers(RegistrationManagerBase.java:180)
    Truncated. see log file for complete stacktrace
    >
    <May 24, 2013 3:36:18 PM CEST> <Error> <JMX> <BEA-149500> <An exception occurred while registering the MBean null.
    java.lang.IllegalArgumentException: Registered more than one instance with the same objectName : com.bea:ServerRuntime=AdminServer,Name=default@liferay@null,WorkManagerRuntime=default,ApplicationRuntime=liferay,Type=RequestClassRuntime new:weblogic.work.RequestClassRuntimeMBeanImpl@77f653fa existing weblogic.work.RequestClassRuntimeMBeanImpl@6c53ec84
    at weblogic.management.jmx.ObjectNameManagerBase.registerObject(ObjectNameManagerBase.java:168)
    at weblogic.management.mbeanservers.internal.WLSObjectNameManager.lookupObjectName(WLSObjectNameManager.java:131)
    at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:87)
    at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
    at weblogic.management.provider.core.RegistrationManagerBase.invokeRegistrationHandlers(RegistrationManagerBase.java:180)
    Truncated. see log file for complete stacktrace
    >
    May 24, 2013 3:36:32 PM com.liferay.portal.kernel.log.Jdk14LogImpl info
    INFO: Detected server weblogic
    Loading zip:/opt/oracle/user_projects/domains/weblogic/servers/AdminServer/tmp/_WL_user/liferay/3t4tek/war/WEB-INF/lib/portal-impl.jar!/system.properties
    May 24, 2013 3:36:32 PM com.liferay.portal.kernel.log.Jdk14LogImpl info
    INFO: Global shared lib directory /opt/oracle/modules/
    May 24, 2013 3:36:32 PM com.liferay.portal.kernel.log.Jdk14LogImpl info
    INFO: Global lib directory /opt/oracle/user_projects/domains/weblogic/lib/
    May 24, 2013 3:36:32 PM com.liferay.portal.kernel.log.Jdk14LogImpl info
    INFO: Portal lib directory /opt/oracle/user_projects/domains/weblogic/servers/AdminServer/tmp/_WL_user/liferay/3t4tek/war/WEB-INF/lib/
    May 24, 2013 3:36:33 PM com.liferay.portal.kernel.log.Jdk14LogImpl info
    INFO: Properties for portal loaded from [file:/opt/oracle/user_projects/domains/portal-ext.properties, zip:/opt/oracle/user_projects/domains/weblogic/servers/AdminServer/tmp/_WL_user/liferay/3t4tek/war/WEB-INF/lib/portal-impl.jar!/portal.properties]
    Loading zip:/opt/oracle/user_projects/domains/weblogic/servers/AdminServer/tmp/_WL_user/liferay/3t4tek/war/WEB-INF/lib/portal-impl.jar!/portal.properties
    Loading file:/opt/oracle/user_projects/domains/portal-ext.properties
    <May 24, 2013 3:37:08 PM CEST> <Warning> <HTTP> <BEA-101342> <liferay: Error(s) encountered while precompiling JSP jspURI
    configuration.jsp:17:18: Error in "init.jsp" at line 249: The code of method _jspService(HttpServletRequest, HttpServletResponse) is exceeding the 65535 bytes limit
    <%@ include file="/html/portlet/asset_publisher/init.jsp" %>
    ^--------------------------------------^
    >
    <May 24, 2013 3:37:08 PM CEST> <Warning> <J2EE> <BEA-160140> <Unresolved optional package references (in META-INF/MANIFEST.MF): [Extension-Name: javax.crypto, referenced from: /opt/oracle/user_projects/domains/weblogic/servers/AdminServer/tmp/_WL_user/liferay/3t4tek/war/WEB-INF/lib/_wl_cls_gen.jar]. Ensure that the referenced optional package has been deployed as a library.>
    15:37:28,951 INFO [[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'][DialectDetector:71] Determine dialect for Oracle 11
    15:37:29,105 INFO [[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'][DialectDetector:136] Found dialect org.hibernate.dialect.Oracle10gDialect
    May 24, 2013 3:37:43 PM net.sf.ehcache.Cache initialise
    WARNING: Cache: com.liferay.portal.service.impl.PortletLocalServiceImpl has a maxElementsInMemory of 0. In Ehcache 2.0 this has been changed to mean a store with no capacity limit. Set it to 1 if you want no elements cached in memory
    May 24, 2013 3:38:31 PM org.quartz.impl.StdSchedulerFactory instantiate
    INFO: Using default implementation for ThreadExecutor
    Exception in thread "[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'"
    <May 24, 2013 3:40:35 PM CEST> <Warning> <HTTP> <BEA-101162> <User defined listener com.liferay.portal.spring.context.PortalContextLoaderListener failed: java.lang.OutOfMemoryError: PermGen space.
    java.lang.OutOfMemoryError: PermGen space
    >
    <May 24, 2013 3:40:38 PM CEST> <Warning> <HTTP> <BEA-101162> <User defined listener com.sun.faces.config.ConfigureListener failed: java.lang.OutOfMemoryError: PermGen space.
    java.lang.OutOfMemoryError: PermGen space
    >
    Exception in thread "[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception in thread "[ACTIVE] ExecuteThread: '4' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "[ACTIVE] ExecuteThread: '4' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception in thread "[STANDBY] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "[STANDBY] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'"
    <May 24, 2013 11:03:12 PM CEST> <Critical> <WebLogicServer> <BEA-000386> <Server subsystem failed. Reason: java.lang.OutOfMemoryError: PermGen space
    java.lang.OutOfMemoryError: PermGen space
    >
    Exception in thread "[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'"
    Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'"

    Hi,
    ok thats it, i found the config file.
    And yes i noticed my deployment and my jdbc connect got the same name :-/
    Damn it im silly :(
    Thanks a lot!
    Jens
    Edited by: 1008097 on 27.05.2013 05:21

  • Upgrading to PT 8.49.14 - PermGen problem with weblogic console

    All Peoplesoft domain Comes you fine in our env setup (Admin, PIA1, and PIA2).
    When we try to bring up the console, we're able to get the initial signon screen.
    We enter the account and password, hit the signon button, and it never comes back.
    The log ends up showing a PermGen error:
    hrdmo@peo1asdv-z1:/psa1asdv/apps/hrdmo/hr890/webserv/hrdmo/servers/WebLo
    gicAdmin/logs> more WebLogicAdmin_stderr.log
    Exception in thread "VDE Replication Thread" java.lang.OutOfMemoryError:
    PermGen space
    Exception in thread "[STANDBY] ExecuteThread: '6' for queue:
    'weblogic.kernel.Default (self-tuning)'" java.lang.OutOfMemoryError:
    PermGen space
    Exception in thread "[ACTIVE] ExecuteThread: '0' for queue:
    'weblogic.kernel.Default (self-tuning)'" java.lang.OutOfMemoryError:
    PermGen space
    Exception in thread "[ACTIVE] ExecuteThread: '7' for queue:
    'weblogic.kernel.Default (self-tuning)'" java.lang.OutOfMemoryError:
    PermGen space
    Changed Java heap from Solution:
    from:
    JAVA_OPTIONS_SOLARIS="-server -Xms512m -Xmx512m -XX:MaxPermSize=256m
    -Dtoplink.xml.platform=oracle.toplink.platform.xml.jaxp.JAXPPlatform"
    To:
    JAVA_OPTIONS_SOLARIS="-server -Xms1024m -Xmx1024m -XX:MaxPermSize=256m
    -Dtoplink.xml.platform=oracle.toplink.platform.xml.jaxp.JAXPPlatform"
    Changed the adminserver:
    from:
    JAVA_OPTIONS_ADMINSERVER="-Xms256m -Xmx1024m"
    to:
    JAVA_OPTIONS_ADMINSERVER="-Xms1024m -Xmx1024m"
    still getting PermGen space error, any thoughts?
    Env setup: Solaris 10, WLS 92 MP3 patch1, PTools 849.14
    Thanks

    Increasing PermGen size doesn't solve problem at all. Source of the problem is related with class loader. After you web app is undeployed class loader can not unload all classes from PermGen memory. This leads to extra memory consumption after every undeploy, deploy cycle. Make sure every class can be released and undeployed after undeploy.
    Regards
    Remis B
    Remigijus Bauzys
    Java EE freelancer
    IT Consultant.

  • Java.lang.OutOfMemoryError: PermGen space error while creat weblogic domain

    Hi,
    OBIEE 11g installing in Linux server now. domain creation is in progress for about an hour and in log I can see below error.
    Creating a new AdminServer Object ...
    AdminServer port is 7001
    Starting the domain ...
    java.lang.OutOfMemoryError: PermGen space
    java.lang.OutOfMemoryError: PermGen space
    java.lang.OutOfMemoryError: PermGen space
    domain creation is still running and looks like it is struck to start domain no idea how to solve the issue. waiting to see whether domain creation successful.
    I was searching on web and found below solution but no idea how to do it in Linux server. Please provide detail instructions to do it.
    * java.lang.OutOfMemoryError: PermGen space
    at java.lang.Class.getDeclaredConstructors0(Native Method)
    at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
    at java.lang.Class.getConstructor0(Unknown Source)
    at java.lang.Class.getConstructor(Unknown Source)
    Solution: Increase the max permgen space -XX:MaxPermSize=256m
    There can be a leak in the permgen objects. If tuning parameters do not resolve the issue, we need to use the memory leak detector tools and find out which instances in the permgen space are not getting cleared.
    Refer: http://weblogic-wonders.com/weblogic/2010/12/30/different-out-of-memory-issues/
    Appreciate for your help.
    Thanks
    Jay.

    Hi,
    The script that configures the domain $DOMAIN_HOME/bin/setDomainEnv.sh... it should detect you are using JDK from Sun (JAVA_VENDOR="Sun") and add -XX:MaxPermSize=512m automatically...
    Simple solution, use JRockit... This problem only occurs with Sun JDK...
    Alternatively, add manually -XX:MaxPermSize=512m to the last JAVA_PROPERTIES in setDomainEnv.sh then you will be sure it is there...
    Cheers,
    Vlad

  • XML parser memory usage

    I try to proove the advantage of SAX (and StAX) parser, i.e. the memory usage over time is very low and quite constant over time while parsing a large XML file.
    DOM APIs create a DOM that is stored in the memory and therefore the memory usage is at least the filesize.
    To analyse the SAX heap usage over time I used the following source:
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.InputStream;
    import org.xml.sax.InputSource;
    import org.xml.sax.XMLReader;
    import org.xml.sax.helpers.XMLReaderFactory;
    public class ParserMemTest {
        public static void main(String[] args) {
            System.out.println("Start");
            try {
                InputStream xmlIS = new FileInputStream(
                        new File("xmlTestFile-0.xml") );
                HeapAnalyser ha = new HeapAnalyser(xmlIS);
                InputSource insource = new InputSource(ha);
                XMLReader SAX2parser = XMLReaderFactory.createXMLReader();
                //SAX2EventHandler handler = new SAX2EventHandler();
                //SAX2parser.setContentHandler(handler);
                SAX2parser.parse(insource);
            } catch (Exception e) {
            System.out.println("Finished.");
    }and the HeapAnalyser class:
    import java.io.IOException;
    import java.io.InputStream;
    public class HeapAnalyser extends InputStream {
        private InputStream is = null;
        private int byteCounter = 0;
        private int lastByteCounter = 0;
        private int byteStepLogging = 200000; //bytes between logging times of measurement
        public HeapAnalyser(InputStream is) {
            this.is = is;
        @Override
        public int read() throws IOException {
            int b = is.read();
            if(b!=-1) {
                byteCounter++;
            return b;
        @Override
        public int read(byte b[]) throws IOException {
            int i = is.read(b);
            if(i!=-1) {
                byteCounter += i;
            //LOG
            if ((byteCounter-lastByteCounter)>byteStepLogging) {
                lastByteCounter = byteCounter;
                System.out.println(byteCounter + ": " + getHeapSize() + " bytes.");
            return i;
        @Override
        public int read(byte b[], int off, int len) throws IOException {
            int i = is.read(b, off, len);
            if (i!=-1) {
                byteCounter += i;
            //LOG
            if ((byteCounter-lastByteCounter)>byteStepLogging) {
                lastByteCounter = byteCounter;
                System.out.println(byteCounter + ": " + getHeapSize() + " bytes.");
            return i;
        public static String getHeapSize(){
            Runtime.getRuntime().gc();
            return Long.toString((Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory())/1000);
    }and these are the results:
    Start
    204728: 1013 bytes.
    409415: 1713 bytes.
    614073: 2400 bytes.
    818763: 3085 bytes.
    1023449: 3772 bytes.
    1228130: 4458 bytes.
    1432802: 5145 bytes.
    1637473: 5832 bytes.
    1842118: 6519 bytes.
    2046789: 7206 bytes.
    2251470: 7894 bytes.
    2456134: 8580 bytes.
    2660814: 9268 bytes.
    2865496: 9955 bytes.
    3070177: 10625 bytes.
    3274775: 11287 bytes.
    3479418: 11950 bytes.
    3684031: 12612 bytes.
    3888695: 13275 bytes.
    4093364: 13937 bytes.
    4298027: 14600 bytes.
    4502694: 15262 bytes.
    4707372: 15925 bytes.
    4912040: 16586 bytes.
    5116662: 17249 bytes.
    5321331: 17912 bytes.
    5525975: 18574 bytes.
    5730640: 19237 bytes.
    5935308: 19898 bytes.
    Finished.
    As you can see while parsing the XML file (200k elements, about 6MB) the heap memory raises. I would expect this result when a DOM API is analysed, but not with SAX .
    What could be the reason? The Runtime class measurement, the SAX implementation or what?
    thanks!

    http://img214.imageshack.us/img214/7277/jprobeparser.jpg
    Test with jProbe while parsing the 64MB XML file.
    Testsystem: Windows 7 64bit, java version "1.6.0_20" Java(TM) SE Runtime Environment (build 1.6.0_20-b02), Java HotSpot(TM) 64-Bit Server VM (build 16.3-b01, mixed mode), Xerces 2.10.0
    Eclipse Console System output:
    25818828: 116752 bytes.
    26018980: 117948 bytes.
    26219154: 99503 bytes.
    26419322: 100852 bytes.
    26619463: 102275 bytes.
    26819642: 103624 bytes.
    27019805: 104974 bytes.
    27220008: 105649 bytes.
    27420115: 106998 bytes.
    27620234: 108348 bytes.
    27820330: 109697 bytes.
    Exception in thread "main" java.lang.OutOfMemoryError: PermGen space
    at java.lang.String.intern(Native Method)
    at org.apache.xerces.util.SymbolTable$Entry.<init>(Unknown Source)
    at org.apache.xerces.util.SymbolTable.addSymbol(Unknown Source)
    at org.apache.xerces.impl.XMLEntityScanner.scanQName(Unknown Source)
    at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
    at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
    at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
    at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
    at ParserMemTest.main(ParserMemTest.java:47)<img src="file:///C:/Users/*******/AppData/Local/Temp/moz-screenshot.png" alt="" />
    Edited by: SUNMrFlipp on Sep 13, 2010 11:48 AM
    Edited by: SUNMrFlipp on Sep 13, 2010 11:50 AM

  • Memory leak and char[] ?

    Hello all,
    I'm not sure whether this post should be here or in WebLogic section, so correct me if I'm wrong.
    I'm working on JDeveloper 11.1.1.3 while deployments are made on standalone WebLogic 10.3.3. This thing occurred in previous versions also.
    With every deployment WebLogic increases it's used memory until the famous PermGen space error, which is after about 5-6 deployments.
    I'm doing my best to understand how to use memleak detection tools. I've switched JDev and WL from Sun jdk which was used before to JRockit, same thing happens. Both JDev's memory profiler and JRockit mission control show something that I really do not understand. char[] uses around 30% of heap space and keeps growing with deployments, next is String with 8%. I never use char in app.
    Am I looking at the wrong thing? Is it normal for char[] to increase on WebLogic on deployments? Does anyone know how to check other things and what to check? Someone on other forums mentioned it would be useful to check if ApplicationContext keeps initializing over again on deployments. Does anyone know how to check this?
    One more thing, I have successfully deployed app on Tomcat, and Tomcat said there is a memory leak in app, but could not tell anything specific.
    I'm kinda lost in this :(

    It is normal for the PermGen space of the Sun's JVM to get filled after several re-deployments. PermGen stands for "permanent generational". This space is used by classes that is unlikely to need to be garbage-collected, so they are placed in this memory space that is never garbage-collected (for example, the Class instances). When you redeploy an application, a new class loader instance is used and it instantiates new Class instances that fill up the PermGen space. But why this happens on JRockit either, I could not explain.
    We have experienced memory leaks related to classes and components that use native memory. For example, we have had significant memory leak when using Oracle's JDBC OCI driver. We were not able to solve this problem, so we switched to JDBC Thin driver (which is very performant and stable today comparing to some years ago). If you are using Oracle JRockit, you can monitor the overall memory usage by the following JRockit command executed at OS command line:
    jrcmd <jrockit_pid> print_memusage>where <jrockit_pid> should be replaced by the JVM process ID.
    If you suspect existence of native memory leaks, then have a look at the article Thanks for the memory for explanations about how Java uses native memory.
    Dimitar

  • Memory leak on the native side

    Hello,
    I am hoping someone here can offer some troubleshooting advice, as I am completely stumped. I am running JBoss 5.1 with JDK 1.6_u18 (same problem with u17 and u16 too)
    - 32-bit, Linux (RHEL 5).
    - min/max heap setting of 1024M
    - permgen max of 256M
    - Thread stack size of 128K
    - No JNI
    My problem: The memory footprint of the JVM slowly grows until it hits the 3G OS limit. This takes about 8 hours under moderate load. At this time, it of course dies as it has no more addressable memory left.
    Here is the strange part: I have used every possible memory debugging tool (jmap, Eclipse MAT, etc) and nothing looks out of the ordinary in my Java heap. Thread count stays at a reasonable 350 threads, Java heap size stabilizes at about 500M. For the first hour or so, the JVM footprint stays at about 1.7G, which makes sense. After that it starts to slowly grow until in exceeds the 3G limit.
    What can I do to figure out where the leak is occurring? There is clearly some native resource that is being allocated but not freed. As I indicated, all the Java analysis tools report a healthy, stable heap and thread count.
    Thanks in advance.
    Jon

    Thanks for the reply.
    I have confirmed with -verbose:jni that the only JNI libraries getting loaded are those belonging to the JDK. My application does make heavy use of the ProcessClassLoader from the Jboss JBPM library, but classes all seem to be unloading normally, and my Permgen usage stays very low and stable. Is there anything I should look at in regards to this class loader? I have tried both a lack of GC parameters and specified the concurrent mark sweep collector, with the same results.

Maybe you are looking for