Java heap space ошибка как исправить dbeaver

I have a .sql file with size 1047399KB,I’m trying to run it on Windows10 with 4.00GB RAM on DBeaver program, i got java.lang.OutOfMemoryError: Java heap space error

I tried many solutions but didn’t work with me.
file.sql -Xms128m -Xmx512m, file.sql -vmargs -Xmx1024M, file.sql -Xmx800m -Xms500m all didn’t work with me.

asked Sep 20, 2018 at 12:39

Zeyad Etman's user avatar

6

I encountered same issue: every time you get it, you have to allocate more space and run DBeaver itself first with additional flags -vmargs -Xmx*m. Replace * with 2048 or 4096.

It doesn’t look like DBeaver takes garbage out when closing the script, so I had to restart application many times to check right amount of memory needed.

@Timothy Jannace just pointed out that you also can edit dbeaver.ini. Example.

answered Feb 4, 2019 at 6:45

vintprox's user avatar

vintproxvintprox

8831 gold badge10 silver badges24 bronze badges

10

Thanks. Database is HSQL embedded. I have checked all log files. The only entrance is in metadata.log:

!ENTRY org.eclipse.ui 4 0 2021-04-08 16:57:46.484
!MESSAGE Unhandled event loop exception
!STACK 0
java.lang.OutOfMemoryError: Java heap space

!ENTRY org.jkiss.dbeaver.model 4 0 2021-04-08 16:57:59.452
!MESSAGE Event loop exception
!SUBENTRY 1 org.jkiss.dbeaver.model 4 0 2021-04-08 16:57:59.452
!MESSAGE Java heap space
!STACK 0
java.lang.OutOfMemoryError: Java heap space

The behaviour is an increasing of memory usage (to the maximum specified in dbeaver.ini), 100% of cpu used (may be due to java gargabe collector) and dbeaver process unresponsive (I have to kill it).

This is my dbeaver.ini file:

-startup
plugins/org.eclipse.equinox.launcher_1.6.0.v20200915-1508.jar
—launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.2.0.v20200915-1442
-vmargs
-XX:+IgnoreUnrecognizedVMOptions
—add-modules=ALL-SYSTEM
-Dosgi.requiredJavaVersion=11
-Xms512m
-Xmx4096m

Я столкнулся с таким же issue: каждый раз, когда вы его получаете, вам нужно выделять больше места и сначала запускать сам DBeaver с дополнительными флагами -vmargs -Xmx*m. Замените * на 2048 или 4096.

Не похоже, что DBeaver убирает мусор при закрытии скрипта, поэтому мне пришлось перезапускать приложение много раз, чтобы проверить необходимый объем памяти.

@Timothy Jannace только что указал, что вы также можете редактировать dbeaver.ini. Пример.

person
vintproykt
  
schedule
04.02.2019

comment

Спасибо, это решило мою проблему! Немного беспокоит то, что проверка SELECT * FROM LEFT JOIN для небольшой базы данных на самом деле занимает около 2 ГБ оперативной памяти.
person Nicholas Humphrey; 30.04.2019

comment

@NicholasHumphrey Ну, я заметил, что phpMyAdmin пригодится для задачи импорта, например, лучше, чем DBeaver и HeidiSQL. Я предполагал, что собственное программное обеспечение должно обеспечивать более плавную работу и преодолевать ограничения памяти веб-приложения, но я полагаю, что это не относится к конкретному программному обеспечению для баз данных.
person vintproykt; 01.05.2019

comment

Я пробовал данные 1Crore для важной одной БД для другой БД, но инструмент не отвечает. Затем я увеличил параметры памяти в .ini файле, после чего он успешно импортирован. Надеюсь, это кому-то поможет.
person GIRI KUMAR PANEM; 04.03.2020

comment

может кто-нибудь объяснить, как запустить DBeaver из командной строки? Я использую версию Mac OS. Кажется, это файл .app
person cryanbhu; 20.05.2020

comment

Попробуйте вместо этого отредактировать значения в ini-файле. Вы должны найти файл в программном каталоге dbeaver. Он должен называться dbeaver.ini
person Timothy Jannace; 24.11.2020

comment

@cryanbhu отредактируйте dbeaver.ini файл, как показано здесь. Путь должен иметь вид /Applications/DBeaverEE.app/Contents/Eclipse/dbeaver.ini.
person vintproykt; 24.11.2020

I encountered same issue: every time you get it, you have to allocate more space and run DBeaver itself first with additional flags -vmargs -Xmx*m. Replace * with 2048 or 4096.

It doesn’t look like DBeaver takes garbage out when closing the script, so I had to restart application many times to check right amount of memory needed.

@Timothy Jannace just pointed out that you also can edit dbeaver.ini. Example.

Comments

  • I have a .sql file with size 1047399KB,I’m trying to run it on Windows10 with 4.00GB RAM on DBeaver program, i got java.lang.OutOfMemoryError: Java heap space error

    I tried many solutions but didn’t work with me.
    file.sql -Xms128m -Xmx512m, file.sql -vmargs -Xmx1024M, file.sql -Xmx800m -Xms500m all didn’t work with me.

  • Thanks this solved my problem! It’s a bit worrying that a test of SELECT * FROM LEFT JOIN for a small database actually takes around 2GB ram.

  • @NicholasHumphrey Well, I noticed phpMyAdmin comes in handy for import task, for example, better than DBeaver and HeidiSQL. I was assuming that native software must provide more seamless experience and overtake memory limits of web application, but it’s not the case with specific, database software, I guess.

  • I tried 1Crore data to important one DB to another DB but the tool is not responding. Then I have increased memory parameters in «.ini» file after that it’s successfully imported. Hope it’s helpful for someone.

  • can someone explain how to run DBeaver from command line? I am using Mac OS version. It seems it is an .app file

  • Try editing the values in the ini file instead. You should be able to find the file in the program directory of dbeaver. It should be called dbeaver.ini

  • @cryanbhu edit dbeaver.ini file as shown here. Path should be something like /Applications/DBeaverEE.app/Contents/Eclipse/dbeaver.ini.

  • I changed two parameters on my dbeaver.ini file: -Xms500m -Xmx4096m worked for me

Recents

First I was using the portable version of dbeaver. Then, I decided to install it.
(both are community edition)
In both cases I edited the dbeaver.ini file (multiple times) incrementally increasing memory to see if anything would work. Finally I tried setting this: -Xmx100000m (~100GB of RAM!) and it still wouldn’t open without the error. I have 32GB RAM installed and I did initially keep the setting under my actual max RAM, but then I thought, «What the heck? Let it cache to the SSD.» But it still didn’t work!

The sqlite database is only a little over 2GB. A little big but surely not unusual for a database.

Admittedly, this is just about my first time using dbeaver and sqlite so it’s probably user error.

Понравилась статья? Поделить с друзьями:
  • Как найти солдатов великой отечественной войны
  • Run time error 339 component mscomctl ocx как исправить
  • Как найти модем ета
  • Как найти в списках участников вов
  • Как найти сказку золушка