Out of Memory error end erratic behavior

Brief description of the issue: while importing images at their current location, some of them would show in grid view with an exclamation mark, and LR would not allow me to adjust them. Removing and importing the same set of images again, the subset of troubled images changed. At some stage, trying to develop one of the images, I got an "Out of Memory" written in red in the center pane. PS CS opens the same images without any problem, and Windows Task Manager indicates there is plenty of available physical and virtual memory.
Here what I did in detail.
While I was importing images at their current location into the library from DVDs, I started to see en exclamation mark in the upper right corner of several images in the grid view. When I selected any of those images and hit "D" to develop them, I got "An unknown error occurred" in the Develop module, and LR would not allow me to do any adjustment.
I have tried removing the images from the Library and importing them again, and then some of the troubled images were not the same as before, and LR would allow me to develop some of the previously troubled images.
PS CS File Browser shows them all correctly, and also PS can open any of the images without any issue.
I have copied some of the troubled images to my hard disk, and then tried to import them into LR from there. The same image sometimes worked, sometimes didn't. Finally, when trying to develop one of those, I got an "Out of Memory" error message printed in red and upside down in the middle of the picture.
Windows Task Manager was reporting 833824 KB of Available Physical Memory out of 2095536 KB, and was reporting as Commit Charge: Total 1281084 KB, Limit 5080272 KB, Peak 1707720 KB.
Any idea what is going on? It looks to me like instability after I imported a few hundred pictures in a row.

You are ABSOLUTELY right that I had explorer windows open when I got the export failed messages!!!! I do all my printing at costco, so I have Lr export my final pics to a 'jpeg finals' directory, and then individual sub-directories for each folder they came from, and then manually copy from each of these sub directories to the root directory on my CF card for transport to Costco.
Will see if it happens in the future without that window open. Still wouldnt help the upside down OOM messages, tho thanks for the update that the team is working on it.
These two issues and the UI lag are really all that I can ***** about too much, which is pretty amazing given my beta frustrations. I still wish I wasnt locked to the DB. I still cannot in good conscience recommend Lr to most new DSLR users. But for my own use I'm pretty happy. I wish I could get better highlight and shadow recovery like I got in RSP but I'm sure that is user error and n00bishness more than a failure of the app. I'm also not happy that I can't toggle the crop tool to the way I want to work permanently but I guess that ship has sailed too.

Similar Messages

  • Out of memory error importing a JPA Entity in WebDynpro Project

    Hi All!
    We are having problems importing JPA entities in a WebDynPro project, this is our escenario.
    We have two entities, entity A that has a ManyToOne relationship with entity B and at the same time entity B has a OneToMany relationship with entity A. When in the controller context we try to create a node usign a model binding to Entity A we got an Out of memory error from NetWeaver DS. Trying to figure out the problem we identified that in the model that we imported we got the following.
    Entity A
        Entity B
            Entity A
               Entity B
                  and so on....... without and end
    What are we doing wrong? Or how can we avoid these behavior?
    Regards,

    Hi Kaylan:
    Thanks for your reply. You are rigth about the error that we are getting. This is our scenario.
    We have a ejb that in some of his method uses the entity Lote, and this entity has a relationship with entity Categoria. When we import the EJB using the model importer netweaver imports the EJB methods and the entities that they use.
    So after doing this besides the ejb's methods we got these two entities that are the ones that are generating the error, when we try to create a context node using the Categoria entity.
    @Entity
    @Table(name="TB_LOTE")
    public class Lote implements Serializable {
         @EmbeddedId
         private Lote.PK pk;
         @ManyToOne
         @JoinColumn(name="CO_CATEGORIALOTE")
         private Categoria coCategorialote;
         @Embeddable
         public static class PK implements Serializable {
              @Column(name="CO_LOTE")
              private String coLote;
              @Column(name="CO_ORDENFABRICACION")
              private String coOrdenfabricacion2;
                   ^ this.coOrdenfabricacion2.hashCode();
    @Entity
    @Table(name="TB_CATEGORIA")
    public class Categoria implements Serializable {
         @Id
         @Column(name="CO_CATEGORIA")
         private String coCategoria;
         @OneToMany(mappedBy="coCategorialote")
         private Set<Lote> tbLoteCollection;
    Regards,
    Jose Arango

  • Out of Memory Error - not a RAM issue

    I'm using Flash 8 and am getting an out of memory error
    simply trying to copy and paste text in Flash. The error tells me
    to allocate more memory to flash by getting info on the app in the
    finder. This seems strange to me because I thought this was an OS9
    function (I'm running OSx 10.4.9). When I get info, there is
    actually a twirl down menu for Memory, but everything is grayed out
    so I can't change it (it's currently set to 512kb). I don't have
    Flash open at the time.
    Does anyone know what might be going on?
    Thanks ahead of time.
    David

    The application is downloaded from a server Tomcat and launched by Java Web start.
    The settings of the JVM are :
    <j2se version="1.6.0.4+" java-vm-args="-Xms20m -Xmx256m -XX:MinHeapFreeRatio=30 -XX:MaxHeapFreeRatio=50" href="http://java.sun.com/products/autodl/j2se" />
    So the heap can increase up to 256 Mbytes, which I think is sufficient for the application.
    Sometimes the test scenario, which sends the same messages periodically without ending, doesn't cause any problem to the application : the amount of heap it uses remains stable. The application seems to be able to run indefinitely (I let it run for a week without stop).
    Sometimes, with the same scenario, after a few runtime hours, the amount of heap used by the application increases suddenly (in a lapse of 2 or 3 minutes). The GC throws an OOM error and the application freezes. The only solution is to re-launch it.
    The behavior of the JVM and the GC is beyond understanding to me.
    Should I change the tuning parameters of the JVM ?
    Would it be a solution to set the Xms and Xmx parameters to the same value, for example 246 MBytes.
    Are there other parameters of the JVM that could improve the running of the application ?

  • Uploading large files from applet to servlet throws out of memory error

    I have a java applet that needs to upload files from a client machine
    to a web server using a servlet. the problem i am having is that in
    the current scheme, files larger than 17-20MB throw an out of memory
    error. is there any way we can get around this problem? i will post
    the client and server side code for reference.
    Client Side Code:
    import java.io.*;
    import java.net.*;
    // this class is a client that enables transfer of files from client
    // to server. This client connects to a servlet running on the server
    // and transmits the file.
    public class fileTransferClient
    private static final String FILENAME_HEADER = "fileName";
    private static final String FILELASTMOD_HEADER = "fileLastMod";
    // this method transfers the prescribed file to the server.
    // if the destination directory is "", it transfers the file to
    "d:\\".
    //11-21-02 Changes : This method now has a new parameter that
    references the item
    //that is being transferred in the import list.
    public static String transferFile(String srcFileName, String
    destFileName,
    String destDir, int itemID)
    if (destDir.equals(""))
    destDir = "E:\\FTP\\incoming\\";
    // get the fully qualified filename and the mere filename.
    String fqfn = srcFileName;
    String fname =
    fqfn.substring(fqfn.lastIndexOf(File.separator)+1);
    try
    //importTable importer = jbInit.getImportTable();
    // create the file to be uploaded and a connection to
    servlet.
    File fileToUpload = new File(fqfn);
    long fileSize = fileToUpload.length();
    // get last mod of this file.
    // The last mod is sent to the servlet as a header.
    long lastMod = fileToUpload.lastModified();
    String strLastMod = String.valueOf(lastMod);
    URL serverURL = new URL(webadminApplet.strServletURL);
    URLConnection serverCon = serverURL.openConnection();
    // a bunch of connection setup related things.
    serverCon.setDoInput(true);
    serverCon.setDoOutput(true);
    // Don't use a cached version of URL connection.
    serverCon.setUseCaches (false);
    serverCon.setDefaultUseCaches (false);
    // set headers and their values.
    serverCon.setRequestProperty("Content-Type",
    "application/octet-stream");
    serverCon.setRequestProperty("Content-Length",
    Long.toString(fileToUpload.length()));
    serverCon.setRequestProperty(FILENAME_HEADER, destDir +
    destFileName);
    serverCon.setRequestProperty(FILELASTMOD_HEADER, strLastMod);
    if (webadminApplet.DEBUG) System.out.println("Connection with
    FTP server established");
    // create file stream and write stream to write file data.
    FileInputStream fis = new FileInputStream(fileToUpload);
    OutputStream os = serverCon.getOutputStream();
    try
    // transfer the file in 4K chunks.
    byte[] buffer = new byte[4096];
    long byteCnt = 0;
    //long percent = 0;
    int newPercent = 0;
    int oldPercent = 0;
    while (true)
    int bytes = fis.read(buffer);
    byteCnt += bytes;
    //11-21-02 :
    //If itemID is greater than -1 this is an import file
    transfer
    //otherwise this is a header graphic file transfer.
    if (itemID > -1)
    newPercent = (int) ((double) byteCnt/ (double)
    fileSize * 100.0);
    int diff = newPercent - oldPercent;
    if (newPercent == 0 || diff >= 20)
    oldPercent = newPercent;
    jbInit.getImportTable().displayFileTransferStatus
    (itemID,
    newPercent);
    if (bytes < 0) break;
    os.write(buffer, 0, bytes);
    os.flush();
    if (webadminApplet.DEBUG) System.out.println("No of bytes
    sent: " + byteCnt);
    finally
    // close related streams.
    os.close();
    fis.close();
    if (webadminApplet.DEBUG) System.out.println("File
    Transmission complete");
    // find out what the servlet has got to say in response.
    BufferedReader reader = new BufferedReader(
    new
    InputStreamReader(serverCon.getInputStream()));
    try
    String line;
    while ((line = reader.readLine()) != null)
    if (webadminApplet.DEBUG) System.out.println(line);
    finally
    // close the reader stream from servlet.
    reader.close();
    } // end of the big try block.
    catch (Exception e)
    System.out.println("Exception during file transfer:\n" + e);
    e.printStackTrace();
    return("FTP failed. See Java Console for Errors.");
    } // end of catch block.
    return("File: " + fname + " successfully transferred.");
    } // end of method transferFile().
    } // end of class fileTransferClient
    Server side code:
    import java.io.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.util.*;
    import java.net.*;
    // This servlet class acts as an FTP server to enable transfer of
    files
    // from client side.
    public class FtpServerServlet extends HttpServlet
    String ftpDir = "D:\\pub\\FTP\\";
    private static final String FILENAME_HEADER = "fileName";
    private static final String FILELASTMOD_HEADER = "fileLastMod";
    public void doGet(HttpServletRequest req, HttpServletResponse resp)
    throws ServletException,
    IOException
    doPost(req, resp);
    public void doPost(HttpServletRequest req, HttpServletResponse
    resp)
    throws ServletException,
    IOException
    // ### for now enable overwrite by default.
    boolean overwrite = true;
    // get the fileName for this transmission.
    String fileName = req.getHeader(FILENAME_HEADER);
    // also get the last mod of this file.
    String strLastMod = req.getHeader(FILELASTMOD_HEADER);
    String message = "Filename: " + fileName + " saved
    successfully.";
    int status = HttpServletResponse.SC_OK;
    System.out.println("fileName from client: " + fileName);
    // if filename is not specified, complain.
    if (fileName == null)
    message = "Filename not specified";
    status = HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
    else
    // open the file stream for the file about to be transferred.
    File uploadedFile = new File(fileName);
    // check if file already exists - and overwrite if necessary.
    if (uploadedFile.exists())
    if (overwrite)
    // delete the file.
    uploadedFile.delete();
    // ensure the directory is writable - and a new file may be
    created.
    if (!uploadedFile.createNewFile())
    message = "Unable to create file on server. FTP failed.";
    status = HttpServletResponse.SC_INTERNAL_SERVER_ERROR;
    else
    // get the necessary streams for file creation.
    FileOutputStream fos = new FileOutputStream(uploadedFile);
    InputStream is = req.getInputStream();
    try
    // create a buffer. 4K!
    byte[] buffer = new byte[4096];
    // read from input stream and write to file stream.
    int byteCnt = 0;
    while (true)
    int bytes = is.read(buffer);
    if (bytes < 0) break;
    byteCnt += bytes;
    // System.out.println(buffer);
    fos.write(buffer, 0, bytes);
    // flush the stream.
    fos.flush();
    } // end of try block.
    finally
    is.close();
    fos.close();
    // set last mod date for this file.
    uploadedFile.setLastModified((new
    Long(strLastMod)).longValue());
    } // end of finally block.
    } // end - the new file may be created on server.
    } // end - we have a valid filename.
    // set response headers.
    resp.setContentType("text/plain");
    resp.setStatus(status);
    if (status != HttpServletResponse.SC_OK)
    getServletContext().log("ERROR: " + message);
    // get output stream.
    PrintWriter out = resp.getWriter();
    out.println(message);
    } // end of doPost().
    } // end of class FtpServerServlet

    OK - the problem you describe is definitely what's giving you grief.
    The workaround is to use a socket connection and send your own request headers, with the content length filled in. You may have to multi-part mime encode the stream on its way out as well (I'm not about that...).
    You can use the following:
    http://porsche.cis.udel.edu:8080/cis479/lectures/slides-04/slide-02.html
    on your server to get a feel for the format that the request headers need to take.
    - Kevin
    I get the out of Memory Error on the client side. I
    was told that this might be a bug in the URLConnection
    class implementation that basically it wont know the
    content length until all the data has been written to
    the output stream, so it uses an in memory buffer to
    store the data which basically causes memory issues..
    do you think there might be a workaround of any kind..
    or maybe a way that the buffer might be flushed after
    a certain size of file has been uploaded.. ?? do you
    have any ideas?

  • Adobe X Pro 10.1.10 Out of Memory error message

    Hello One, Hello All
    Since updating our Adobe X Pro machines to version update 10.1.10, we occasionally receive an "Out of Memory" error message, which depending on what we are doing, may force us to shutdown all Adobe windows and re-open Adobe, or simply click OK and continue working with the PDF document like nothing is wrong. It seems to have no rhyme or reason to when or why it occurs. I do not see any warnings or errors in the Windows Event Log. It happens with files we have created, and also happens with files received from internal and external sources through email. It is affecting our high end machines: Lenovo X Series and W Series laptops with Windows 8.1 3rd/4th gen i5 CPUs, 8+GB RAM, 128+GB SSD's. We have all system and Windows updates applied. We have Trend Micro and Malwarebytes real-time protection and system scans do not find any malware.
    I have found a few other recent threads on Adobe forum related to this error message but the responses are weak at best with no definitive fix. The system and user temp folders size are less than 100MB each so this cannot be the issue. When the error occurs I check task manager and system utilization, including memory, is well below 100%.
    We did not have this issue prior to version update 10.1.10.
    Really hoping Adobe can step in to help here and hoping boilerplate responses are not used.

    Hi wayne103,
    We released a new security update yesterday that is v10.1.11
    Please update to this version and check the performance.
    I have seen this error message occur while opening a 3rd party created pdf that has corrupted file structure.
    Please let me know if the issue occurs for some specific files or random
    Also let me know the PDF producer for these pdfs.
    Regards,
    Rave

  • JavaScript Out of Memory Error on Portal timeout.

    Hello All,
    I am using jsf and Inline navigation in all our portlets and when user leave the browser idle for portal timeout we have 2 problems. 1: Login portlet shows in that specific portlet. 2: we get a javascript alert saying out of memory at line 40. and the porltet shows error message as "Gateway was not able to access requested content. If the error persists, contact your portal Administrator."
    We are using Plumtree 5.0.4 Java version.
    any help is highly appreciated.
    Thanks
    A.J.

    Both are valid behaviors unfortunately.
    1) login portlet is showing up in specific portlet b/c inline navigation allows for you to create and load pages without affecting the overall portal.
    This happens when you use iframes (which behave in a similar fashion).
    - your only workaround is really to write some javascript function to "listen" to the portal login page getting loaded and then throwing the session into the parent browser (which is Portal). At least this is the only solution that I ever came up with when using Iframes.
    2) Don't know about out of memory error actually, but getting the "gatewy was not able to access requested content" is valid b/c the session died.
    - javascript errors require javascript solutions. Sorry I couldn't be more helpful than that.
    Maybe someone else will have better suggestions.
    The other suggestion is to use your app server to listen to the logout event and redirect appropriately to somewhere else, or have it do what you want it to do in situations as this.

  • ERROR [B3108]: Unrecoverable out of memory error during a cluster operation

    We are using Sun Java(tm) System Message Queue Version: 3.5 SP1 (Build 48-G). We are using two JMS servers as a cluster.
    But we frequently getting the out of memory issue during the cluster operation.
    Messages also got queued up in the Topics. Eventhough listeners have the capability to reconnect with the Server after the broker restarting, usually we are restarting consumer instances to get work this.
    Here is detailed log :
    Jan 5 13:45:40 polar1-18.eastern.com imqbrokerd_cns-jms-18[8980]: [ID 478930 daemon.error] ERROR [B3108]: Unrecoverable out of memory error during a cluster operation. Shutting down the broker.
    Jan 5 13:45:57 polar1-18.eastern18.chntva1-dc1.cscehub.com imqbrokerd: [ID 702911 daemon.notice] Message Queue broker terminated abnormally -- restarting.
    Expecting your attention on this.
    Thanks

    Hi,
    If you do not use any special cmdline options, how do you configure your servers/
    brokers to 1 Gb or 2 Gb JVM heap ?
    Regarding your question on why the consumers appear to be connecting to just
    one of the brokers -
    How are the connection factories that the consumers use configured ?
    Is the connection factory configured using the imqAddressList and
    imqAddressListBehavior attributes ? Documentation for this is at:
    http://docs.sun.com/source/819-2571/ref_adminobj_props.html#wp62463
    imqAddressList should contain a list of brokers (i.e. 2 for you) in the cluster
    e.g.
    mq://server1:7676/jms,mq://server2:7676/jms
    imqAddressListBehavior defines how the 2 brokers in the above list are picked.
    The default is in the order of the list - so mq://server1:7676/jms will always be
    picked by default. If you want random behavior (which will hopefully even out the
    load), set imqAddressListBehavior to RANDOM.
    regards,
    -i
    http://www.sun.com/software/products/message_queue/index.xml

  • Out of memory error - from parsing a "fixed width file"

    This may be fairly simple for someone out there but I am trying to write a simple program that can go through a "fixed width" flat txt file and parse it to be comma dilmeted.
    I use a xml file with data dictionary specifications to do the work. I do this because there are over 430 fields that need to be parsed from a fixed width with close to 250,000 lines I can read the xml file fine to get the width dimensions but when I try to apply the parsing instructions, I get an out of memory error.
    I am hoping it is an error with code and not the large files. If it is the latter, does anyone out there know some techniques for getting at this data?
    Here is the code
       import java.io.*;
       import org.w3c.dom.Document;
       import org.w3c.dom.*;
       import javax.xml.parsers.DocumentBuilderFactory;
       import javax.xml.parsers.DocumentBuilder;
       import org.xml.sax.SAXException;
       import org.xml.sax.SAXParseException;
        public class FixedWidthConverter{
          String[] fieldNameArray;
          String[] fieldTypeArray;
          String[] fieldSizeArray;      
           public static void main(String args []){
             FixedWidthConverter fwc = new FixedWidthConverter();
             fwc.go();
             fwc.loadFixedWidthFile();
            //System.exit (0);
          }//end of main
           public void go(){
             try {
                DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
                DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
                Document doc = docBuilder.parse (new File("files/dic.xml"));
                // normalize text representation            doc.getDocumentElement ().normalize ();
                System.out.println ("Root element of the doc is " +
                     doc.getDocumentElement().getNodeName());
                NodeList listOfFields = doc.getElementsByTagName("FIELD");
                int totalFields = listOfFields.getLength();
                System.out.println("Total no of fields : " + totalFields);
                String[] fldNameArray = new String[totalFields];
                String[] fldTypeArray = new String[totalFields];
                String[] fldSizeArray = new String[totalFields];
                for(int s=0; s<listOfFields.getLength() ; s++){
                   Node firstFieldNode = listOfFields.item(s);
                   if(firstFieldNode.getNodeType() == Node.ELEMENT_NODE){
                      Element firstFieldElement = (Element)firstFieldNode;
                      NodeList firstFieldNMList = firstFieldElement.getElementsByTagName("FIELD_NM");
                      Element firstFieldNMElement = (Element)firstFieldNMList.item(0);
                      NodeList textFNList = firstFieldNMElement.getChildNodes();
                      //System.out.println("Field Name : " +
                               //((Node)textFNList.item(0)).getNodeValue().trim());
                      //loads values into an array
                      //fldNameArray[s] = ((Node)textFNList.item(0)).getNodeValue().trim();
                      NodeList typeList = firstFieldElement.getElementsByTagName("TYPE");
                      Element typeElement = (Element)typeList.item(0);
                      NodeList textTypList = typeElement.getChildNodes();
                      //System.out.println("Field Type : " +
                               //((Node)textTypList.item(0)).getNodeValue().trim());
                      //loads values into an array
                      //fldTypeArray[s] = ((Node)textTypList.item(0)).getNodeValue().trim(); 
                      NodeList sizeList = firstFieldElement.getElementsByTagName("SIZE");
                      Element sizeElement = (Element)sizeList.item(0);
                      NodeList textSizeList = sizeElement.getChildNodes();
                      //System.out.println("Field Size : " +
                               //((Node)textSizeList.item(0)).getNodeValue().trim());
                      //loads values into an array
                      fldSizeArray[s] = ((Node)textSizeList.item(0)).getNodeValue().trim();   
                   }//end of if clause
                }//end of for loop with s var
                //setFldNameArray(fldNameArray);
                //setFldTypeArray(fldTypeArray);
                setFldSizeArray(fldSizeArray);
                 catch (SAXParseException err) {
                   System.out.println ("** Parsing error" + ", line "
                      + err.getLineNumber () + ", uri " + err.getSystemId ());
                   System.out.println(" " + err.getMessage ());
                 catch (SAXException e) {
                   Exception x = e.getException ();
                   ((x == null) ? e : x).printStackTrace ();
                 catch (Throwable t) {
                   t.printStackTrace ();
          }//end go();
           public void setFldNameArray(String[] s){
             fieldNameArray = s;
          }//end setFldNameArray
           public void setFldTypeArray(String[] s){
             fieldTypeArray = s;
          }//end setFldTypeArray
           public void setFldSizeArray(String[] s){
             fieldSizeArray = s;
          }//end setFldSizeArray
           public String[] getFldNameArray(){
             return fieldNameArray;
          }//end setFldNameArray
           public String[] getFldTypeArray(){
             return fieldTypeArray;
          }//end setFldTypeArray
           public String[] getFldSizeArray(){
             return fieldSizeArray;
          }//end setFldSizeArray 
           public int getNumLines(){
             int countLines = 0;
             try {
                    //File must be in same director and be the name of the string below
                BufferedReader in = new BufferedReader(new FileReader("files/FLAT.txt"));
                String str;
                while ((str = in.readLine()) != null) {
                   countLines++;
                in.close();
                 catch (IOException e) {}    
             return countLines;
          }//end of getNumLines
           public void loadFixedWidthFile(){
             int c = getNumLines();
             int i = 0;
             String[] lineProcessed = new String[c];
             String chars;
             try {
                    //File must be in same director and be the name of the string below
                BufferedReader in = new BufferedReader(new FileReader("files/FLAT.txt"));
                String str;
                while ((str = in.readLine()) != null) {
                   //System.out.println(str.length());
                   lineProcessed[i] = parseThatLine(str);
                   i++;
                in.close();
                 catch (IOException e) {}     
                //write out the lineProcess[] array to another file
             writeThatFile(lineProcessed);
          }//end loadFixedWidthFile()
           public void writeThatFile(String[] s){
             try {
                BufferedWriter out = new BufferedWriter(new FileWriter("files/outfilename.txt"));
                for(int i = 0; i < s.length -1; i++){
                   out.write(s);
    }//end for loop
    out.close();
    catch (IOException e) {}
    }//end writeThatFile
    public String parseThatLine(String s){
    int start = 0;
    int end = 0;
    String parsedLine = "";
    int numChars = getFldSizeArray().length;
    //Print number of lines for testing
    //System.out.println(numChars);
    String[] oArray = getFldSizeArray();
    //String chars = oArray[0];
    //System.out.println(chars.length());
    //oArray
    for(int i = 0; i < numChars -1; i++ ){
    if(i == 0){
    start = 0;
    end = end + Integer.parseInt(oArray[i])-1;
    else
    start = end;
    end = end + Integer.parseInt(oArray[i]);
    parsedLine = parsedLine + s.substring(start, end) + "~";
    }//end for loop
    return parsedLine;
    }//End of parseThatLine
    I have tried to illeminate as many arrays as I can thinking that was chewing up the memory but to no avail.
    Any thoughts or ideas?
    Message was edited by:
    SaipanMan2005

    You should not keep a String array of all the lines of the file read.
    Instead for each line read, parse it, then write the parsed line in the other file:      public void loadFixedWidthFile() {
             BufferedReader in = null;
             BufferedWriter out = null;
             try {
                //File must be in same director and be the name of the string below
                in = new BufferedReader(new FileReader("files/FLAT.txt"));
                out = new BufferedWriter(new FileWriter("files/outfilename.txt"));
                String str;
                while ((str = in.readLine()) != null) {
                   //System.out.println(str.length());
                   str = parseThatLine(str);
                   //write out the parsed str to another file
                   out.write(str);
             catch (IOException e) {
                e.printStackTrace(); // At least print the exception - never swallow an exception
             finally { // Use a finally block to be sure of closing the files even when exception occurs
                try { in.close(); }
                catch (Exception e) {}
                try { out.close(); }
                catch (Exception e) {}
          }//end loadFixedWidthFile()Regards

  • Out of memory Error with jdk 1.6

    Hello,
    I have a swing application launched on the client with the help of Java web start. The applications works fine in jre 1.4 and jre 1.5. The heap sizes are :
    initial-heap-size="5m" max-heap-size="24m"
    But when I run this using jre 1.6.0_05-b13, I am getting Out of memory Error, java heap size. And I see the memory usage is growing rapidly which I didn't notice in other jre versions (1.4 and 1.5).
    Does anyone have any idea on this?
    Thanks in advance,
    MR.

    Thanks for your response Peter. During my continuous testing I identified that error happens on jdk 1.5 also. And I have increased the min-heap-size to 24 MB and max-heap-size to 64 MB. But in that case also I noticed the out of memory error. The interesting thing is, the min-heap-size is never increased from 24MB and lot of free memory also.
    Memory: 24,448K Free: 12,714K (52%) ... completed.
    The Outofmemoryerror triggers from the reader thread which does the job of reading the data from the InputStream. One thing is we are continuously pushing more data on the output stream from the other end. Is that any limitation on InputStream which can hold some definite amount of data.
    Please throw some light on this.

  • How can I solve out of memory error on excell file in PL/SQL

    Hi,
    I'm new on PL/SQL. One of the PL/SQL code which is created excell report got out of Memory error. The first reason of this error, excell file not supported more than 65536 data. So I change the excell file separeted sheets. So that the single sheet size cannot exceed 65536 data.
    All the data are held on system cach and if many user want to take the report the they would get an out of memory error.
    So I want to change the code like that; when out of memory exception raises,
    the old excell file save to disk and new excell file is created,
    and go on to write the new file without exiting the program.
    At the end of the data all the excell file append and show only one file to the user.
    I do know how to save the file and create a new file. But I don't know how can PL/SQL program to turn back to loop again when the exception occurs.
    Is anyone help me on this issue?
    Here is my code
    Thank you
    dworkbook:=hssfworkbook.new;
    dCurrentItem := Get_Block_Property(pCurrentBlock, FIRST_ITEM);     
    while not (name_in('system.last_record')='TRUE') loop
    /* The data would be written to the excell file column order. */
    if (dRow=0) then
              /* Create a new sheet */
    elsif (dRow <= dMaxWorksheetNum) then
         /* Data of the report are written here. The data are written in column order */
    if (dRow > dMaxWorksheetNum) then
         /* give dRow and dColumn intial value */
    /* increase worksheet number */
    end if; /* End of if (dRow=1) */
    if (isWritten) and not name_in('system.last_record')='TRUE'then
         /* if not at the end of the record and the previously read record is written to the file
         , then go to next record */
         next_record;
    end if;
    /* save excell report */
    workbookwriter.save(dworkbook,global.gethome||dFileName);
    web.show_document('/users/'||dFileName,'_BLANK');
    /* when exceptions occurs */
    EXCEPTION
    WHEN ORA_JAVA.EXCEPTION_THROWN THEN
    begin
         javaException := ORA_JAVA.LAST_EXCEPTION;
         -- Print out the Exception by using the toString()
         -- Method of the exception Object
         javaException2 := Exception_.new(javaException);
         mess(27002,Exception_.getMessage(javaException2));
         -- and clean up
         ORA_JAVA.CLEAR_EXCEPTION;
    exception
         WHEN ORA_JAVA.JAVA_ERROR THEN
    -- In this case, the error would be
    -- Argument 1 can not be null
    mess(27002,ORA_JAVA.LAST_ERROR);
    --Clean up
    ORA_JAVA.CLEAR_ERROR;
    end;
    WHEN ORA_JAVA.JAVA_ERROR THEN
    -- In this case, the error would be
    -- Argument 1 can not be null
    message(ORA_JAVA.LAST_ERROR);
    --Clean up
    ORA_JAVA.CLEAR_ERROR;

    No need to double-post... most questions are answered pretty quickly...

  • Another version of 'out of memory' error

    Hi all
    I have a colleague who is getting the following error message.
    As discussed...when I attempt to render a clip on the timeline, once it
    gets to the end of the rendering process and attempts to play the clip, an
    'out of memory' error message box appears on the screen.
    Then when I click on 'OK' to close this box, the canvas window turns to red
    and the following message displays in the canvas window...'Out of memory.
    Free up memory and window will redraw.'
    He is using HDV footage captured with the "HDV" codec [not the intermediate one], and editing it into HDV1080i50 sequences.
    He has a G5 DP 2 GHZ machine running Tiger 10.4.2 and 2 GB of ram.
    He has approx 80 GB free space on Mac HD and approx 400 GB on external Lacie HD. He is running only FCP HD 5 at any one time.
    I have sourced some previous posts which speak of corrupt graphics, clips, sequences and trashing fcp prefs.
    Does anyone have any other suggestions for him?
    [He is quite new to macs and FCP especially].
    I am going to send him an email to subscribe and create an account for this forum, his name is AGebhardt.

    Hello,
    I had the same issue last night, when a render (only 15 min., so not THAT big) completed and would not play and the canvas turned red and said I was out of memory.
    This is different than a general error! out of memory warning, which I have seen happen. Some of the answers in linked threads seem to be pointing to this other situation.
    I have plenty of space and plenty of RAM and was only running iTunes. I quit iTunes and it worked, almost to my disappointment because in the past I have had many apps working at a time with no problems,
    I would be pretty bummed if I could only have FCP open all of a sudden.
    I will try going through my clips to check for corruptions as suggested just to be on the safe side, but have a question;
    What good is it to throw out your render files if you have already checked to see if you have enough storage space? I can see the good if a file is corrupt, but with every project a new render folder is created and unless there is a limit on these folders that I'm unaware of I can't see the sense in trashing the folder.
    Am I missing something?
    Thanks,
    Jesse
    733 G4    

  • Question - Out of memory error

    Receiving "Out of Memory" error when trying to insert pages into an existing pdf.  I'm using Acrobat 9 Standard version 9.5.1.

    I downloaded JProfiler.
    Even though I'm new to Java and only had JProfiler for an hour or two
    I was able to get my app running from JProfiler and observe the heap
    in real time. I saw that when I first run the server app it is level then when
    I pull up the client lobby and then the chat room up it begins to climb very
    quickly going from 1 to 10 MB in a matter of a couple minutes and continues
    to rise fast. I checked the code closer and realized that I could close the
    prepared statment and resultset each time I go through the loop. Here is the
    code I added inside the loop at the end of the loop mentioned above.
    rs.close();
    ps.close();
    out.flush();
    System.gc();
    I ran the JProfiler again and the heap saw toothes right at 1 MB and stays there :) .
    I let it run for 10 minutes. It looks like it is still climbing a couple bytes every
    minute but like I said there are other threads in the app running so as I learn
    how to use JProfiler more and more I should be able to run that down as well.
    Made me feel alot better about the whole situation.
    One last ? When I use the line
    while (keepgoing) {
    switch (new Integer(in.readLine())) {
    within the keepgoing loop does the new Integer(
    use more and more memory each time it loops or is that collected since it is not referenced again?
    So looks like I will have to buy JProfiler even though i'm dirt poor lol. Thanks.

  • JNI and Out of Memory errors

    Hi,
    At my job, we seem to have a memory leak related to JNI. We know we
    have a memory leak because we keep getting Out of Memory errors even
    after increasing the maximum heap size to more than 256 megs. And we
    know that this is the application that is eating up all the system
    memory.
    We are running under Windows 2000, with both JDK 1.3.0 and JDK 1.4.1.
    We tried looking at the problem under JProbe, but it shows a stable
    Java heap (no problems, except that the Windows task manager shows it
    growing and growing...)
    I tried a strip down version, where I set the max heap size to 1 Meg,
    and print out the total memory, memory used, and maximum memory used at
    a 5 sec interval.
    Memory used = Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory().
    Well, I let that strip down version running for about a day. The
    maximum memory used has stabilized to about 1.1 Meg, and has not
    increased. The current memory used increases until it gets to some
    threshold, then it decreases again. However, the Windows task manager
    shows the memory increasing -- and currently it is at 245 Megs!
    In the lab, the behavior we see with the Windows task manager is as
    follows:
    1. Total memory used in the system increases until some threshold.
    2. Then it goes back down by about 100 Megs.
    3. This cycle continues, but at each cycle the memory goes back down
    less and less, until the app crashes.
    Now, our theory is that JNI is consuming all this memory (maybe we are
    using JNI wrong). That's the only explanation we can come up with to
    explain what we have seen (Java showing an OK heap, but the task
    manager showing it growing, until crashing).
    Does that make sense? Can the new operator throw an Out of Memory
    error if the system does not have enough memory to give it, even if
    there is still free heap space as far as the Runtime object is
    concerned? Does the Runtime object figures objects allocated through
    JNI methods into the heap used space?
    Note that I know the task manager is not a reliable indicator.
    However, I don't think a Java app is supposed to runaway with system
    memory -- the problem is not simply that the Java app is consuming too
    much memory, but that it seems to always want more memory. Besides, we
    do get the Out of Memory error.
    Thanks for your help,
    Nicolas Rivera

    Hi,
    there are two sources of memory leakage in JNI:
    - regular leaks in c/c++ code;
    - not released local/global references of java objects in JNI.
    I think that the first issue in not a problem for you. The second is more complex. In your JNI code you should check
    - how many local references alive you keep in your code as their number is restricted (about 16 and can be enlarged). The good style is not to store local references but keep only global.
    - any local reference accepted from java call in JNI are released by JVM. You should release local references you created in JNI and also global references.
    - do not use a large number of java object references. Each new reference gets new memory in JVM. Try to reuse refences.
    I guess that is your problem.
    Vitally

  • Out of memory errors

    I'm having problems starting 8i. When started from /etc/rc.d/
    init.d/dbora during bootup or manually by root, I get an out of
    memory error.
    If I start it from the dbadmin user (oracle), I either get the
    same out of memory error, or I end up with several hundred shell
    logins and the database still doesn't respond.
    This is RedHat Linux 6.0, kernel 2.2.5-22smp. Here is a sample of
    what happens when I get the out of memory error:
    Mem: 160448K av, 53488K used, 106960K free, 26264K shrd,
    6532K buff
    Swap: 656360K av, 0K used, 656360K free
    36328K cached
    Oracle Server Manager Release 3.1.5.0.0 - Production
    (c) Copyright 1997, Oracle Corporation. All Rights Reserved.
    Oracle8i Release 8.1.5.0.0 - Production
    With the Java option
    PL/SQL Release 8.1.5.0.0 - Production
    SVRMGR> Connected.
    SVRMGR> ORA-27102: out of memory
    Linux Error: 22: Invalid argument
    SVRMGR>
    Server Manager complete.
    Database "ORCL" warm started.
    null

    It turns out that the problem I was having with a large number of
    shell processes being created was due to the use of oraenv in my
    .bashrc file (so much for following the instructions!) It was
    calling itself recursively until the process limit was reached.
    However, even with this fixed, the out of memory error still
    exists.
    max (guest) wrote:
    : dan....
    : check your init.ora......
    Aside from comments, it has these lines, which were created by
    dbassist:
    db_name = test
    instance_name = ORCL
    service_names = test
    control_files = ("/u02/oradata/test/control01.ctl", "/u02/oradata/
    test/control02.ctl")
    db_block_buffers = 8192
    shared_pool_size = 4194304
    log_checkpoint_interval = 10000
    log_checkpoint_timeout = 1800
    # I reduced processes to see if it would help
    processes = 10
    log_buffer = 163840
    background_dump_dest = /u01/admin/test/bdump
    core_dump_dest = /u01/admin/test/cdump
    user_dump_dest = /u01/admin/test/udump
    db_block_size = 2048
    remote_login_passwordfile = exclusive
    os_authent_prefix = ""
    compatible = "8.1.0"
    : also check ulimit
    Here's ulimit -a:
    core file size (blocks) 1000000
    data seg size (kbytes) unlimited
    file size (blocks) unlimited
    max memory size (kbytes) unlimited
    stack size (kbytes) 8192
    cpu time (seconds) unlimited
    max user processes 256
    pipe size (512 bytes) 8
    open files 1024
    virtual memory (kbytes) 2105343
    Everything looks pretty large to me.
    : Dan Wilga (guest) wrote:
    : : I'm having problems starting 8i. When started from /etc/rc.d/
    : : init.d/dbora during bootup or manually by root, I get an out
    : of
    : : memory error.
    : : If I start it from the dbadmin user (oracle), I either get
    the
    : : same out of memory error, or I end up with several hundred
    : shell
    : : logins and the database still doesn't respond.
    : : This is RedHat Linux 6.0, kernel 2.2.5-22smp. Here is a
    sample
    : of
    : : what happens when I get the out of memory error:
    : : Mem: 160448K av, 53488K used, 106960K free, 26264K shrd,
    : : 6532K buff
    : : Swap: 656360K av, 0K used, 656360K free
    : : 36328K cached
    : : Oracle Server Manager Release 3.1.5.0.0 - Production
    : : (c) Copyright 1997, Oracle Corporation. All Rights Reserved.
    : : Oracle8i Release 8.1.5.0.0 - Production
    : : With the Java option
    : : PL/SQL Release 8.1.5.0.0 - Production
    : : SVRMGR> Connected.
    : : SVRMGR> ORA-27102: out of memory
    : : Linux Error: 22: Invalid argument
    : : SVRMGR>
    : : Server Manager complete.
    : : Database "ORCL" warm started.
    null

  • Oracle Service Bus For loop getting out of memory error

    I have a business service that is based on a JCA adapter to fetch an undertimed amout of records from a database.  I then need to upload those to another system using a webservice designed by an external source.  This web service will only accept upto to x amount of records.
    The process:
    for each object in the Jca Response
          Insert object into Service callout Request body
          if object index = number of objects in jca response or object index = next batch index
               Invoke service callout
               Append service callout Response to a total response object (xquery transform)
               increase next batch index by Batch size
               reset service callout to empty body
           endif
    end for
    replace body  with total response object.
    If I use the data set that only has 5 records  and use a batch size of 2 the process works fine.
    If I use  a data set with 89 records  and a batch size of 2 I get the below out of memory error  after about 10 service callouts
    the quantity of data in the objects is pretty small, less than 1kB for each JCA Object
    Server Name:
    AdminServer
    Log Name:
    ServerLog
    Message:
    Failed to process response message for service ProxyService Sa/Proxy Services/DataSync:
    java.lang.OutOfMemoryError: allocLargeObjectOrArray:
    [C, size 67108880 java.lang.OutOfMemoryError: allocLargeObjectOrArray:
    [C, size 67108880 at org.apache.xmlbeans.impl.store.Saver$TextSaver.resize(Saver.java:1700)
    at org.apache.xmlbeans.impl.store.Saver$TextSaver.preEmit(Saver.java:1303) at
    org.apache.xmlbeans.impl.store.Saver$TextSaver.emit(Saver.java:1234)
    at org.apache.xmlbeans.impl.store.Saver$TextSaver.emitXmlns(Saver.java:1003)
    at org.apache.xmlbeans.impl.store.Saver$TextSaver.emitNamespacesHelper(Saver.java:1021)
    at org.apache.xmlbeans.impl.store.Saver$TextSaver.emitElement(Saver.java:972)
    at org.apache.xmlbeans.impl.store.Saver.processElement(Saver.java:476)
    at org.apache.xmlbeans.impl.store.Saver.process(Saver.java:307)
    at org.apache.xmlbeans.impl.store.Saver$TextSaver.saveToString(Saver.java:1864)
    at org.apache.xmlbeans.impl.store.Cursor._xmlText(Cursor.java:546)
    at org.apache.xmlbeans.impl.store.Cursor.xmlText(Cursor.java:2436)
    at org.apache.xmlbeans.impl.values.XmlObjectBase.xmlText(XmlObjectBase.java:1500)
    at com.bea.wli.sb.test.service.ServiceTracer.getXmlData(ServiceTracer.java:968)
    at com.bea.wli.sb.test.service.ServiceTracer.addDataType(ServiceTracer.java:944)
    at com.bea.wli.sb.test.service.ServiceTracer.addDataType(ServiceTracer.java:924)
    at com.bea.wli.sb.test.service.ServiceTracer.addContextChanges(ServiceTracer.java:814)
    at com.bea.wli.sb.test.service.ServiceTracer.traceExit(ServiceTracer.java:398)
    at com.bea.wli.sb.pipeline.debug.DebuggerTracingStep.traceExit(DebuggerTracingStep.java:156)
    at com.bea.wli.sb.pipeline.PipelineContextImpl.exitComponent(PipelineContextImpl.java:1292)
    at com.bea.wli.sb.pipeline.MessageProcessor.finishProcessing(MessageProcessor.java:371)
    at com.bea.wli.sb.pipeline.RouterCallback.onReceiveResponse(RouterCallback.java:108)
    at com.bea.wli.sb.pipeline.RouterCallback.run(RouterCallback.java:183)
    at weblogic.work.ContextWrap.run(ContextWrap.java:41)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:545)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256) at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
    Subsystem:
    OSB Kernel
    Message ID:
    BEA-382005
    It appears to be the service callout that is the problem (it calls another OSB service that logins and performs the data upload to the External service)  because If I change the batch size up to 100  the loop will load all the 89 records into the callout request and execute it fine.  If I have a small batch size then I run out of memory.
    Is there some settings I need to change?  Is there a better way in OSB (less memory intensive than service callout in a for loop)?
    Thanks.

    hi,
    Could you please let me know if you get rid off this issue as we are also facing the same issue.
    Thanks,
    SV

Maybe you are looking for

  • How can i determine the order automator actually gets the files?

    Hi, I'm a newbie so excuse my probably simple question, but I have a problem using Automator to change the names of files. What I'm trying to do is using Automator to rename files that are in a specific order and have to stay that way. I'm trying to

  • Java plugin 1.5 not working with firefox

    Hey, i'm running SUSE 10.0 and I installed the Java Runtime Environment using the RPM file, and then copied over the .so file into my ~/.mozilla/plugins and ~/.mozilla/firefox/plugins directories, and firefox just ignores them when I try to run a jav

  • White space in InlineGraphic

    I just use EditManager.insertInlineGraphic with an URI as source parameter. If i insert image as first character (with firstBaselineOffset = "auto") ,it work perfect . However ,when i try to insert image after some character , the image display with

  • Large Files are locking up Windows 7 32 bit and 64 bit

    I am a tech and have done over 30 clean installs and cant figure out what the heck is going on with large as in 1gig or more file transfers hanging up. All clean installs with tests done immediately after activation and updates. This is a MS problem.

  • HT1918 I have moved to Turkey and this means that my pst code is not accepted .

    I have moved to Turkey .I am british . I have a Uk credit card wiith a Turkish billing address . I tunes will not accept my post code ! Has anyone overcome this issue