Unanswered: "There is not enough memory available" error using "restore database" command
1. I have created off-line database backup on DB2 Workgroup v8.2 FP9 on Windows 2003.
2. I copied backup file from computer (step 1) to Windows XP SP3 using DB2 Express-C v9.5 (no fixpack).
3. I executed the following command from db2cmd:
db2 RESTORE DATABASE mydb FROM "C:\backup_dir" TAKEN AT 20081107091504 TO "C:" INTO mydb WITH 2 BUFFERS BUFFER 1024 PARALLELISM 1 WITHOUT PROMPTING
and getting error: "SQL1022C There is not enough memory available to process the command. SQLSTATE=57011"
db2 ? sql1022c
SQL1022C There is not enough memory available to process the command.
Not enough random access memory (RAM) is available to process the
If a remote procedure was invoked, the remote procedure may use a local
variable space that is larger than the allowable maximum (4K).
If the statement involves a user-defined function (UDF), the memory set
controlled by the ASLHEAPSZ database manager configuration parameter may
be larger than the memory available.
The command cannot be processed.
Stop the application. Possible solutions include:
* Change the MEMMAN NO SWAP, NO MOVE option in the CONFIG.SYS file to
* Remove background processes.
* Decrease the values of the configuration parameters that define
allocation of memory, including ASLHEAPSZ if UDFs are involved in the
* Install more random access memory (RAM).
* If a remote procedure was invoked, ensure that the remote procedure
uses a local variable space that is less than or equal to 4K.
* If you are using Remote Data Services, increase the Remote Data
Services heap size (rsheapsz) in the server and client configuration
because at least one block is used per application.
On restore database computer there is 2,5 GB of RAM and 2,1 RAM free. It should not be the RAM problem.
Any idea what is wrong? How to restore database from v8.2 to v9.5 database?
It could be because of ASLHEAPSZ which is related to communication buffer.
The communication buffer stores the result of the query in the buffer space rather than storing it in temporary tables.
I guess restore command internally uses some blocking cursors with select statements and that's where the problem is popping up from. The communication buffer space should be large enough to hold the result set of the query.