Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • memory usage error

    Hello,

    I am a habitual Stata/SE 15.1 user. Today when opening a large dataset I received an insufficient memory error. My attempt to expand the memory gave me this error:


    . set max_memory 10g, permanently
    invalid syntax
    r(198);


    Can anyone diagnose what I am doing wrong?

  • #2
    I cannot replicate your error, but my Stata is not up to date.

    Anyway, the entry for

    Code:
    help memory
    suggests that the default memory provided is "all the memory the operating system is willing to supply". So, changing that setting is not going to provide more memory but less memory instead. You probably need to fix this in the OS that you are running, not within Stata.

    Best
    Daniel

    Comment


    • #3
      Further to Daniel's advice, I believe that you might be trying to open a dataset that exceeds the available system memory. Unfortunately, I do not have a dataset large enough to simulate this possible problem.

      Comment


      • #4
        Ugh, not an easy fix, but thank you both for responding.

        Comment


        • #5
          First, reboot and run Stata with nothing else running - that will give you the maximum possible memory available. The memory documentation also talks about setting segmentsize and a bug when run in Linux OS. Also, does max memory work if you give it a smaller number? The error says syntax which suggests a typo.

          Comment


          • #6
            There's something odd. The syntax of that command works fine on my machine. In fact, I can set (arbitrarily) the max memory to be several times the available RAM on my computer just fine, accepting that I don't actually have this memory available for use. Should you try to open a dataset larger than available memory (say but setting max_memory to 1M), Stata will complain about an "attempt to use too much memory".

            Comment


            • #7
              Originally posted by Amanda Botticello View Post
              Can anyone diagnose what I am doing wrong?
              1) The syntax shown is perfectly fine from the Stata's manual standpoint. So there must be something else that you don't show. If the problem may be reproduced from within a do-file, create such a file that we can run on other machines.

              2) For this kind of questions the specifics do matter. What is the Platform? Version? Stata falvor, version, build number? What is the machine configuration etc.

              Best, Sergiy

              Comment

              Working...
              X