LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-13-2005, 01:13 PM   #1
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Rep: Reputation: 0
couldn't start jvm


i'm trying to run java

[root@as bin]# ./java
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.

but i get that error, hope someone can help me out.

thanks.
 
Old 10-13-2005, 01:54 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
What's the output of
free
on that machine?


Cheers,
Tink
 
Old 10-14-2005, 10:20 PM   #3
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Original Poster
Rep: Reputation: 0
how do you get the free memory of a linux machine in shell?

but i believe there are sufficient memory
 
Old 10-14-2005, 10:36 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
free


Cheers,
Tink
 
Old 10-14-2005, 11:16 PM   #5
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Original Poster
Rep: Reputation: 0
        total used free shared buffers cached
Mem: 6135416 6084432 50984 0 534640 2536028
-/+ buffers/cache: 3013764 3121652
Swap: 2048152 2048084 68


that means i like have 50984 free memory... must be this the problem?

is this in bytes? so my linux only has 6mb of memory??

how can i reduce the memory footprint of my linux server?

-david

Last edited by mickeyren; 10-14-2005 at 11:19 PM.
 
Old 10-14-2005, 11:53 PM   #6
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
The values are in KB... the box would have 6GB, and a 2GB
swapper.

Yep. You ran out of RAM and swap-sapce ... 68Kbytes
available for swapping.

The question would be what services you're running, and
who gobbles up all the RAM. Have a look at the output of
top, sort by memory usage. With top running, press Shft-m


Cheers,
Tink

P.S.: Next time you post system output please enclose it
in code-tags, that makes it more readable :}
 
Old 10-15-2005, 03:40 AM   #7
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Original Poster
Rep: Reputation: 0
hi tinkster

its all apache, mysqld, postgres, mailman and a few more others running multiple instances... i have like 15 mysqld processes running.

even still, adding this all up won't hog all the 5 GB of ram.

any other ways?
 
Old 10-15-2005, 03:10 PM   #8
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Please run this
top -n 1 -b
and post the output inside a quote
[ quote] [ /quote] (without the space
after the opening square brackets.


Cheers,
Tink
 
Old 10-15-2005, 03:15 PM   #9
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Original Poster
Rep: Reputation: 0
Quote:
13:15:49 up 8 days, 13:15, 1 user, load average: 0.02, 0.06, 0.01
79 processes: 77 sleeping, 1 running, 1 zombie, 0 stopped
CPU states: cpu user nice system irq softirq iowait idle
total 0.0% 0.0% 0.7% 0.0% 0.0% 0.0% 99.2%
cpu00 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 100.0%
cpu01 0.0% 0.0% 2.8% 0.0% 0.0% 0.0% 97.1%
cpu02 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 100.0%
cpu03 0.0% 0.0% 0.0% 0.0% 0.0% 0.0% 100.0%
Mem: 6135416k av, 6094488k used, 40928k free, 0k shrd, 487084k buff
2596488k active, 3011304k inactive
Swap: 2048152k av, 2045368k used, 2784k free 2361600k cached

PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME CPU COMMAND
652 root 16 0 1068 1068 756 R 0.7 0.0 0:00 1 top
1 root 9 0 464 440 416 S 0.0 0.0 0:29 0 init
8982 root 9 0 540 532 464 S 0.0 0.0 0:58 0 syslogd
8994 named 9 0 3060 2784 2040 S 0.0 0.0 0:00 0 named
8995 named 9 0 3060 2784 2040 S 0.0 0.0 0:10 1 named
8996 named 9 0 3060 2784 2040 S 0.0 0.0 0:02 3 named
8997 named 9 0 3060 2784 2040 S 0.0 0.0 0:03 2 named
8998 named 9 0 3060 2784 2040 S 0.0 0.0 0:00 2 named
9010 root 9 0 1440 1360 1236 S 0.0 0.0 0:58 3 sshd
9020 root 8 0 768 752 656 S 0.0 0.0 0:16 2 xinetd
9792 postgres 9 0 1372 1128 1036 S 0.0 0.0 0:08 0 postmaster
9856 postgres 9 0 1512 1200 1016 S 0.0 0.0 0:00 0 postmaster
9889 postgres 9 0 1420 1140 1052 S 0.0 0.0 0:02 1 postmaster
11248 root 8 0 984 984 792 S 0.0 0.0 0:00 3 couriertcpd
11250 root 9 0 904 904 720 S 0.0 0.0 0:00 2 courierlogger
11296 root 8 0 956 956 768 S 0.0 0.0 0:00 2 couriertcpd
11360 root 9 0 756 756 584 S 0.0 0.0 0:00 3 courierlogger
11616 root 9 0 980 980 792 S 0.0 0.0 0:02 0 couriertcpd
11680 root 9 0 900 900 720 S 0.0 0.0 0:00 1 courierlogger
11756 root 8 0 956 884 768 S 0.0 0.0 0:00 1 couriertcpd
11758 root 9 0 756 756 584 S 0.0 0.0 0:00 0 courierlogger
11768 qmails 8 0 456 456 360 S 0.0 0.0 3:00 2 qmail-send
11772 qmaill 9 0 424 416 360 S 0.0 0.0 0:27 1 splogger
11773 root 8 0 344 320 256 S 0.0 0.0 0:16 1 qmail-lspawn
11774 qmailr 8 0 356 348 268 S 0.0 0.0 0:17 3 qmail-rspawn
11775 qmailq 9 0 312 304 260 S 0.0 0.0 0:09 3 qmail-clean
12023 root 9 0 20880 20M 2276 S 0.0 0.3 0:01 1 spamd
12264 popuser 8 0 20540 20M 2020 S 0.0 0.3 0:20 0 spamd
12270 popuser 8 0 20504 16M 2080 S 0.0 0.2 1:33 1 spamd
13626 root 9 0 3868 3832 3212 S 0.0 0.0 0:29 2 httpsd
14368 drweb 9 0 6820 6644 1828 S 0.0 0.1 0:02 2 drwebd
14470 root 8 0 588 580 536 S 0.0 0.0 0:07 0 crond
14486 mailman 9 0 4652 2788 1976 S 0.0 0.0 0:00 0 python
14488 mailman 9 0 4664 4504 1944 S 0.0 0.0 3:23 1 python
14489 mailman 9 0 4668 4504 1944 S 0.0 0.0 0:05 1 python
14490 mailman 9 0 4664 4656 1944 S 0.0 0.0 3:18 2 python
14491 mailman 9 0 4664 4660 1944 S 0.0 0.0 3:13 1 python
14492 mailman 9 0 4704 4700 1944 S 0.0 0.0 3:17 3 python
14493 mailman 9 0 4748 4360 1944 S 0.0 0.0 3:25 1 python
14532 mailman 9 0 4664 2968 1944 S 0.0 0.0 3:18 1 python
4053 root 9 0 596 552 548 S 0.0 0.0 0:00 2 crond
4058 apache 9 0 0 0 0 Z 0.0 0.0 0:00 1 cache_clean <defunct>
4317 apache 9 0 1176 1124 520 S 0.0 0.0 0:47 3 cache_clean
10955 root 9 0 36804 35M 36460 S 0.0 0.5 0:09 1 httpd
11264 root 9 0 32756 31M 31960 S 0.0 0.5 0:00 2 httpd
27083 psaadm 8 0 9240 9208 4632 S 0.0 0.1 0:02 2 httpsd
3264 psaadm 9 0 12152 11M 4904 S 0.0 0.1 0:03 0 httpsd
3281 psaadm 9 0 9168 9136 4580 S 0.0 0.1 0:02 1 httpsd
3282 psaadm 9 0 9300 9268 4584 S 0.0 0.1 0:02 2 httpsd
15507 psaadm 9 0 12076 11M 4908 S 0.0 0.1 0:02 2 httpsd
17065 root 9 0 1028 1028 892 S 0.0 0.0 0:00 3 safe_mysqld
17184 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 3 mysqld
17216 mysql 8 0 23716 23M 3304 S 0.0 0.3 0:00 1 mysqld
17248 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 0 mysqld
17280 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 2 mysqld
17314 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 0 mysqld
17345 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 3 mysqld
17378 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 1 mysqld
17410 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:06 1 mysqld
17441 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 2 mysqld
17473 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:01 2 mysqld
19779 psaadm 8 0 9240 9204 4568 S 0.0 0.1 0:01 1 httpsd
27722 apache 9 0 41300 40M 34608 S 0.0 0.6 0:03 3 httpd
27724 apache 9 0 41108 40M 35648 S 0.0 0.6 0:03 1 httpd
16800 qmailr 9 0 952 952 764 S 0.0 0.0 0:00 1 qmail-remote
20219 apache 9 0 42544 41M 39276 S 0.0 0.6 0:00 1 httpd
20220 apache 9 0 41728 40M 38780 S 0.0 0.6 0:00 3 httpd
20221 apache 9 0 42132 41M 39080 S 0.0 0.6 0:00 1 httpd
3083 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 0 mysqld
3846 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 1 mysqld
3866 mysql 9 0 23716 23M 3304 S 0.0 0.3 0:00 1 mysqld
11936 qmaild 9 0 780 776 600 S 0.0 0.0 0:00 1 qmail-smtpd
11968 qmaild 9 0 776 772 600 S 0.0 0.0 0:00 0 qmail-smtpd
12000 qmaild 9 0 780 776 600 S 0.0 0.0 0:00 1 qmail-smtpd
12033 qmaild 9 0 776 772 600 S 0.0 0.0 0:00 3 qmail-smtpd
12035 qmaild 9 0 776 772 600 S 0.0 0.0 0:00 2 qmail-smtpd
12036 qmaild 9 0 776 772 600 S 0.0 0.0 0:00 3 qmail-smtpd
21792 root 11 0 2308 2248 1768 S 0.0 0.0 0:00 2 sshd
22272 root 11 0 1212 1212 988 S 0.0 0.0 0:00 2 bash
hi this was the output...
 
Old 10-15-2005, 03:37 PM   #10
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Man ... I *must* be tired. So many mistakes of
late... can you please change the tags from
quote to code?


Cheers,
Tink
 
Old 10-15-2005, 10:48 PM   #11
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Original Poster
Rep: Reputation: 0
Code:
 20:49:12  up  2:48,  1 user,  load average: 0.09, 0.10, 0.04
75 processes: 73 sleeping, 1 running, 1 zombie, 0 stopped
CPU states:  cpu    user    nice  system    irq  softirq  iowait    idle
           total    0.2%    0.0%    0.4%   0.0%     0.0%    0.0%   99.2%
           cpu00    0.0%    0.0%    0.0%   0.0%     0.0%    0.0%  100.0%
           cpu01    0.9%    0.0%    1.9%   0.0%     0.0%    0.0%   97.0%
           cpu02    0.0%    0.0%    0.0%   0.0%     0.0%    0.0%  100.0%
           cpu03    0.0%    0.0%    0.0%   0.0%     0.0%    0.0%  100.0%
Mem:  6135416k av, 5834684k used,  300732k free,       0k shrd,  488552k buff
      2546040k active,            2875340k inactive
Swap: 2048152k av, 2043496k used,    4656k free                 2337184k cached

  PID USER     PRI  NI  SIZE  RSS SHARE STAT %CPU %MEM   TIME CPU COMMAND
13127 root      14   0  1084 1084   756 R     0.7  0.0   0:00   1 top
    1 root       9   0   468  468   420 S     0.0  0.0   0:00   1 init
27722 root       9   0   540  540   464 S     0.0  0.0   0:00   3 syslogd
27733 named      9   0  2940 2936  2024 S     0.0  0.0   0:00   1 named
27734 named      9   0  2940 2936  2024 S     0.0  0.0   0:00   1 named
27735 named      9   0  2940 2936  2024 S     0.0  0.0   0:00   2 named
27736 named      9   0  2940 2936  2024 S     0.0  0.0   0:00   2 named
27737 named      9   0  2940 2936  2024 S     0.0  0.0   0:00   3 named
28001 root       9   0  1540 1540  1412 S     0.0  0.0   0:00   0 sshd
28041 root      15   0   816  816   708 S     0.0  0.0   0:00   2 xinetd
28905 postgres   8   0  1940 1940  1844 S     0.0  0.0   0:00   3 postmaster
28907 postgres   9   0  1756 1752  1684 S     0.0  0.0   0:00   2 postmaster
28908 postgres   9   0  1780 1776  1684 S     0.0  0.0   0:00   3 postmaster
29024 root       9   0  1020 1020   892 S     0.0  0.0   0:00   3 safe_mysqld
29952 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   3 mysqld
30240 root       8   0  1000 1000   808 S     0.0  0.0   0:00   1 couriertcpd
30304 root       9   0   900  900   720 S     0.0  0.0   0:00   1 courierlogger
30464 mysql     11   0 22164  21M  3116 S     0.0  0.3   0:00   0 mysqld
30501 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   3 mysqld
30529 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   1 mysqld
30560 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   1 mysqld
30592 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   2 mysqld
30785 root       8   0   984  984   800 S     0.0  0.0   0:00   2 couriertcpd
30848 root       9   0   760  760   592 S     0.0  0.0   0:00   1 courierlogger
31074 root       9   0   996  996   808 S     0.0  0.0   0:00   2 couriertcpd
31075 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   3 mysqld
31076 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:01   0 mysqld
31077 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   1 mysqld
31078 mysql      9   0 22164  21M  3116 S     0.0  0.3   0:00   3 mysqld
31080 root       9   0   900  900   720 S     0.0  0.0   0:00   0 courierlogger
31089 root       9   0   992  992   800 S     0.0  0.0   0:00   1 couriertcpd
31091 root       9   0   764  764   592 S     0.0  0.0   0:00   2 courierlogger
31100 qmails     8   0   448  448   360 S     0.0  0.0   0:01   1 qmail-send
31104 qmaill     9   0   416  416   360 S     0.0  0.0   0:00   2 splogger
31136 root       0   0   340  340   256 S     0.0  0.0   0:00   0 qmail-lspawn
31168 qmailr     8   0   348  348   268 S     0.0  0.0   0:00   2 qmail-rspawn
31200 qmailq     9   0   312  312   260 S     0.0  0.0   0:00   2 qmail-clean
31816 root       9   0 20932  20M  2332 S     0.0  0.3   0:00   0 spamd
32032 popuser    6   0 20592  20M  2064 S     0.0  0.3   0:00   1 spamd
32160 popuser    8   0 20580  20M  2064 S     0.0  0.3   0:00   0 spamd
32693 root       9   0 37264  36M 36928 S     0.0  0.6   0:03   0 httpd
  663 root       9   0 32772  31M 31964 S     0.0  0.5   0:00   2 httpd
  668 root       9   0  5412 5408  5248 S     0.0  0.0   0:00   0 httpsd
  673 psaadm     8   0  7288 7284  5284 S     0.0  0.1   0:00   3 httpsd
  704 psaadm     9   0  8032 8028  5348 S     0.0  0.1   0:00   2 httpsd
  736 psaadm     9   0  8320 8316  5316 S     0.0  0.1   0:00   1 httpsd
  768 psaadm     9   0  5540 5536  5328 S     0.0  0.0   0:00   2 httpsd
  801 psaadm     9   0  5540 5536  5328 S     0.0  0.0   0:00   1 httpsd
 1120 drweb      9   0  7180 7180  2160 S     0.0  0.1   0:00   3 drwebd
 1409 root       8   0   604  604   556 S     0.0  0.0   0:00   0 crond
 1664 mailman    9   0  4624 4620  1956 S     0.0  0.0   0:00   1 python
 1856 mailman   11   0  4664 4660  1948 S     0.0  0.0   0:02   1 python
 1888 mailman    9   0  4672 4668  1948 S     0.0  0.0   0:00   0 python
 1920 mailman    9   0  4664 4660  1948 S     0.0  0.0   0:02   2 python
 1952 mailman   11   0  4668 4664  1948 S     0.0  0.0   0:02   0 python
 1984 mailman    9   0  4704 4700  1948 S     0.0  0.0   0:02   0 python
 2016 mailman   11   0  4752 4748  1948 S     0.0  0.0   0:02   1 python
 2048 mailman    9   0  4664 4660  1948 S     0.0  0.0   0:02   0 python
 6897 psaadm     9   0  8228 8224  5292 S     0.0  0.1   0:00   2 httpsd
 9006 root       9   0   600  600   556 S     0.0  0.0   0:00   0 crond
 9010 apache     9   0     0    0     0 Z     0.0  0.0   0:00   1 cache_clean <defunct>
 9128 apache     9   0   712  712   520 S     0.0  0.0   0:00   1 cache_clean
23460 apache    10   0 43244  42M 37984 S     0.0  0.7   0:01   0 httpd
25751 apache     9   0 44412  43M 38988 S     0.0  0.7   0:01   3 httpd
26113 postgres   9   0  4084 4084  3156 S     0.0  0.0   0:01   2 postmaster
27168 postgres   9   0  4084 4084  3156 S     0.0  0.0   0:00   1 postmaster
  640 apache    10   0 37852  36M 36564 S     0.0  0.6   0:00   2 httpd
 9512 apache     9   0 41720  40M 39092 S     0.0  0.6   0:00   3 httpd
 9517 apache     9   0 41460  40M 38960 S     0.0  0.6   0:00   1 httpd
12329 postgres   9   0  4080 4080  3156 S     0.0  0.0   0:00   2 postmaster
13236 postgres   9   0  4080 4080  3156 S     0.0  0.0   0:00   0 postmaster
 3448 root      10   0  2268 2268  1848 S     0.0  0.0   0:00   0 sshd
 3462 root      12   0  1220 1220   992 S     0.0  0.0   0:00   0 bash
 5361 qmaild     9   0   780  776   600 S     0.0  0.0   0:00   2 qmail-smtpd
13031 root      12   0   452  452   392 S     0.0  0.0   0:00   1 tcp-env
there you go.
 
Old 10-16-2005, 01:13 AM   #12
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
OK, so according to
Code:
awk '{if(sub("M","",$6)){$6=$6*1024}; total+=$6 } END{print total}' processes.txt
your processes use up 701540K ...

That strongly suggests that some process is leaking
memory. What distro are you running, and where
did the programs installed come from?

Are you able to reboot the box and take a snapshot
of top like the one before? And of course the output
of free.

To actually assess which processes are chomping up
the RAM you'd have to run each of them under valgrind,
from memory (older posts I read somewhere) I recall
that Apache & MySQL as a combo had that problem
at some stage, can't recall when, and how it was fixed.


Cheers,
Tink

Last edited by Tinkster; 10-16-2005 at 12:18 PM.
 
Old 10-16-2005, 07:47 AM   #13
mickeyren
LQ Newbie
 
Registered: Feb 2005
Posts: 14

Original Poster
Rep: Reputation: 0
hi tinkster

i haven't tried restarting the computer yet.

you you've been a great help, i'll see what i can do with these information.

many thanks!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
JVM for HP-UX kaplan71 Other *NIX 0 06-01-2005 07:36 AM
Jvm Help! bumfan Linux - General 2 04-29-2004 10:13 AM
Ms Jvm kpharda Linux - Software 2 03-18-2004 04:29 PM
jvm zaman Linux - Software 1 07-07-2003 12:27 AM
Jvm tvines Linux - General 1 04-09-2002 12:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration