Memory not used any more but still allocated

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP












2















I have something kind of weird going on with memory.



I have Ubuntu 14.04 servers with Zimbra 8.6 with kernel (for this one) 3.13.0-37-generic. But I have already seen the problem with other kernels.



Memory and swap are full :



$ free
total used free shared buffers cached
Mem: 6112624 5991208 121416 88 4752 79224
-/+ buffers/cache: 5907232 205392
Swap: 3905532 3624768 280764


I thought that Zimbra was eating all my memory but, strangely, it doesn't seems like it :



# ps -A --sort -rss -o comm,pmem | head -n 11
COMMAND %MEM
java 10.6
clamd 4.7
mysqld 3.0
java 2.0
slapd 1.2
/opt/zimbra/ama 1.1
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 0.9


All my process take like half of the memory. My buffers and cached take nearly nothing.



When I stop Zimbra, there is still 3.5Gb taken:



# ps -A --sort -rss -o comm,pmem | head -n 12
COMMAND %MEM
bash 0.0
bash 0.0
bash 0.0
sudo 0.0
rsyslogd 0.0
http 0.0
http 0.0
htop 0.0
init 0.0
ps 0.0


After a reboot, less than 200Mb was used.



Server was up for 139 days and memory use was growing bit by bit each day.



My question is then: what could have taken all the memory?



EDIT1, add some infos :



$ ls -l /dev/shm
lrwxrwxrwx 1 root root 8 mai 2 12:46 /dev/shm -> /run/shm

$ ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status

------ Semaphore Arrays --------
key semid owner perms nsems

------ Message Queues --------
key msqid owner perms used-bytes messages


$ df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 3051744 4 3051740 1% /dev
tmpfs 611260 496 610764 1% /run
/dev/sda2 14287344 2765996 10772548 21% /
none 4 0 4 0% /sys/fs/cgroup
none 5120 0 5120 0% /run/lock
none 3056288 0 3056288 0% /run/shm
none 102400 0 102400 0% /run/user


After reboot, (Zimbra started) :



$ free
total used free shared buffers cached
Mem: 6112576 5712908 399668 832 237892 1829424
-/+ buffers/cache: 3645592 2466984
Swap: 3905532 0 3905532


Some graphs of the RAM (I restarted the server around 12:30) :



RAM usage



Second graph shows results of :



ps aux |awk 's+=$4 END print s'


And third, results of :



smem -tw |grep -v Area | sed 's/ //;s/ //'









share|improve this question
























  • Any shared memory (or similar) used? (ipcs, ls -l /dev/shm, size of tmpfs file systems, ...)

    – Mat
    May 2 '16 at 12:18











  • Could you please provide free output in a couple of minutes after the moment when Zimbra is stopped and system is still using a log of memory?

    – rush
    May 2 '16 at 12:31












  • @Mat, I added some infos.

    – ouzmoutous
    May 2 '16 at 15:42











  • @rush, I did not save this info, but my htop was green for 3.5Go. It's like some process doesn't "unallocate" the memory

    – ouzmoutous
    May 2 '16 at 15:44















2















I have something kind of weird going on with memory.



I have Ubuntu 14.04 servers with Zimbra 8.6 with kernel (for this one) 3.13.0-37-generic. But I have already seen the problem with other kernels.



Memory and swap are full :



$ free
total used free shared buffers cached
Mem: 6112624 5991208 121416 88 4752 79224
-/+ buffers/cache: 5907232 205392
Swap: 3905532 3624768 280764


I thought that Zimbra was eating all my memory but, strangely, it doesn't seems like it :



# ps -A --sort -rss -o comm,pmem | head -n 11
COMMAND %MEM
java 10.6
clamd 4.7
mysqld 3.0
java 2.0
slapd 1.2
/opt/zimbra/ama 1.1
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 0.9


All my process take like half of the memory. My buffers and cached take nearly nothing.



When I stop Zimbra, there is still 3.5Gb taken:



# ps -A --sort -rss -o comm,pmem | head -n 12
COMMAND %MEM
bash 0.0
bash 0.0
bash 0.0
sudo 0.0
rsyslogd 0.0
http 0.0
http 0.0
htop 0.0
init 0.0
ps 0.0


After a reboot, less than 200Mb was used.



Server was up for 139 days and memory use was growing bit by bit each day.



My question is then: what could have taken all the memory?



EDIT1, add some infos :



$ ls -l /dev/shm
lrwxrwxrwx 1 root root 8 mai 2 12:46 /dev/shm -> /run/shm

$ ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status

------ Semaphore Arrays --------
key semid owner perms nsems

------ Message Queues --------
key msqid owner perms used-bytes messages


$ df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 3051744 4 3051740 1% /dev
tmpfs 611260 496 610764 1% /run
/dev/sda2 14287344 2765996 10772548 21% /
none 4 0 4 0% /sys/fs/cgroup
none 5120 0 5120 0% /run/lock
none 3056288 0 3056288 0% /run/shm
none 102400 0 102400 0% /run/user


After reboot, (Zimbra started) :



$ free
total used free shared buffers cached
Mem: 6112576 5712908 399668 832 237892 1829424
-/+ buffers/cache: 3645592 2466984
Swap: 3905532 0 3905532


Some graphs of the RAM (I restarted the server around 12:30) :



RAM usage



Second graph shows results of :



ps aux |awk 's+=$4 END print s'


And third, results of :



smem -tw |grep -v Area | sed 's/ //;s/ //'









share|improve this question
























  • Any shared memory (or similar) used? (ipcs, ls -l /dev/shm, size of tmpfs file systems, ...)

    – Mat
    May 2 '16 at 12:18











  • Could you please provide free output in a couple of minutes after the moment when Zimbra is stopped and system is still using a log of memory?

    – rush
    May 2 '16 at 12:31












  • @Mat, I added some infos.

    – ouzmoutous
    May 2 '16 at 15:42











  • @rush, I did not save this info, but my htop was green for 3.5Go. It's like some process doesn't "unallocate" the memory

    – ouzmoutous
    May 2 '16 at 15:44













2












2








2








I have something kind of weird going on with memory.



I have Ubuntu 14.04 servers with Zimbra 8.6 with kernel (for this one) 3.13.0-37-generic. But I have already seen the problem with other kernels.



Memory and swap are full :



$ free
total used free shared buffers cached
Mem: 6112624 5991208 121416 88 4752 79224
-/+ buffers/cache: 5907232 205392
Swap: 3905532 3624768 280764


I thought that Zimbra was eating all my memory but, strangely, it doesn't seems like it :



# ps -A --sort -rss -o comm,pmem | head -n 11
COMMAND %MEM
java 10.6
clamd 4.7
mysqld 3.0
java 2.0
slapd 1.2
/opt/zimbra/ama 1.1
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 0.9


All my process take like half of the memory. My buffers and cached take nearly nothing.



When I stop Zimbra, there is still 3.5Gb taken:



# ps -A --sort -rss -o comm,pmem | head -n 12
COMMAND %MEM
bash 0.0
bash 0.0
bash 0.0
sudo 0.0
rsyslogd 0.0
http 0.0
http 0.0
htop 0.0
init 0.0
ps 0.0


After a reboot, less than 200Mb was used.



Server was up for 139 days and memory use was growing bit by bit each day.



My question is then: what could have taken all the memory?



EDIT1, add some infos :



$ ls -l /dev/shm
lrwxrwxrwx 1 root root 8 mai 2 12:46 /dev/shm -> /run/shm

$ ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status

------ Semaphore Arrays --------
key semid owner perms nsems

------ Message Queues --------
key msqid owner perms used-bytes messages


$ df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 3051744 4 3051740 1% /dev
tmpfs 611260 496 610764 1% /run
/dev/sda2 14287344 2765996 10772548 21% /
none 4 0 4 0% /sys/fs/cgroup
none 5120 0 5120 0% /run/lock
none 3056288 0 3056288 0% /run/shm
none 102400 0 102400 0% /run/user


After reboot, (Zimbra started) :



$ free
total used free shared buffers cached
Mem: 6112576 5712908 399668 832 237892 1829424
-/+ buffers/cache: 3645592 2466984
Swap: 3905532 0 3905532


Some graphs of the RAM (I restarted the server around 12:30) :



RAM usage



Second graph shows results of :



ps aux |awk 's+=$4 END print s'


And third, results of :



smem -tw |grep -v Area | sed 's/ //;s/ //'









share|improve this question
















I have something kind of weird going on with memory.



I have Ubuntu 14.04 servers with Zimbra 8.6 with kernel (for this one) 3.13.0-37-generic. But I have already seen the problem with other kernels.



Memory and swap are full :



$ free
total used free shared buffers cached
Mem: 6112624 5991208 121416 88 4752 79224
-/+ buffers/cache: 5907232 205392
Swap: 3905532 3624768 280764


I thought that Zimbra was eating all my memory but, strangely, it doesn't seems like it :



# ps -A --sort -rss -o comm,pmem | head -n 11
COMMAND %MEM
java 10.6
clamd 4.7
mysqld 3.0
java 2.0
slapd 1.2
/opt/zimbra/ama 1.1
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 1.0
/opt/zimbra/ama 0.9


All my process take like half of the memory. My buffers and cached take nearly nothing.



When I stop Zimbra, there is still 3.5Gb taken:



# ps -A --sort -rss -o comm,pmem | head -n 12
COMMAND %MEM
bash 0.0
bash 0.0
bash 0.0
sudo 0.0
rsyslogd 0.0
http 0.0
http 0.0
htop 0.0
init 0.0
ps 0.0


After a reboot, less than 200Mb was used.



Server was up for 139 days and memory use was growing bit by bit each day.



My question is then: what could have taken all the memory?



EDIT1, add some infos :



$ ls -l /dev/shm
lrwxrwxrwx 1 root root 8 mai 2 12:46 /dev/shm -> /run/shm

$ ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status

------ Semaphore Arrays --------
key semid owner perms nsems

------ Message Queues --------
key msqid owner perms used-bytes messages


$ df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 3051744 4 3051740 1% /dev
tmpfs 611260 496 610764 1% /run
/dev/sda2 14287344 2765996 10772548 21% /
none 4 0 4 0% /sys/fs/cgroup
none 5120 0 5120 0% /run/lock
none 3056288 0 3056288 0% /run/shm
none 102400 0 102400 0% /run/user


After reboot, (Zimbra started) :



$ free
total used free shared buffers cached
Mem: 6112576 5712908 399668 832 237892 1829424
-/+ buffers/cache: 3645592 2466984
Swap: 3905532 0 3905532


Some graphs of the RAM (I restarted the server around 12:30) :



RAM usage



Second graph shows results of :



ps aux |awk 's+=$4 END print s'


And third, results of :



smem -tw |grep -v Area | sed 's/ //;s/ //'






linux memory






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited May 2 '16 at 15:41







ouzmoutous

















asked May 2 '16 at 10:54









ouzmoutousouzmoutous

1213




1213












  • Any shared memory (or similar) used? (ipcs, ls -l /dev/shm, size of tmpfs file systems, ...)

    – Mat
    May 2 '16 at 12:18











  • Could you please provide free output in a couple of minutes after the moment when Zimbra is stopped and system is still using a log of memory?

    – rush
    May 2 '16 at 12:31












  • @Mat, I added some infos.

    – ouzmoutous
    May 2 '16 at 15:42











  • @rush, I did not save this info, but my htop was green for 3.5Go. It's like some process doesn't "unallocate" the memory

    – ouzmoutous
    May 2 '16 at 15:44

















  • Any shared memory (or similar) used? (ipcs, ls -l /dev/shm, size of tmpfs file systems, ...)

    – Mat
    May 2 '16 at 12:18











  • Could you please provide free output in a couple of minutes after the moment when Zimbra is stopped and system is still using a log of memory?

    – rush
    May 2 '16 at 12:31












  • @Mat, I added some infos.

    – ouzmoutous
    May 2 '16 at 15:42











  • @rush, I did not save this info, but my htop was green for 3.5Go. It's like some process doesn't "unallocate" the memory

    – ouzmoutous
    May 2 '16 at 15:44
















Any shared memory (or similar) used? (ipcs, ls -l /dev/shm, size of tmpfs file systems, ...)

– Mat
May 2 '16 at 12:18





Any shared memory (or similar) used? (ipcs, ls -l /dev/shm, size of tmpfs file systems, ...)

– Mat
May 2 '16 at 12:18













Could you please provide free output in a couple of minutes after the moment when Zimbra is stopped and system is still using a log of memory?

– rush
May 2 '16 at 12:31






Could you please provide free output in a couple of minutes after the moment when Zimbra is stopped and system is still using a log of memory?

– rush
May 2 '16 at 12:31














@Mat, I added some infos.

– ouzmoutous
May 2 '16 at 15:42





@Mat, I added some infos.

– ouzmoutous
May 2 '16 at 15:42













@rush, I did not save this info, but my htop was green for 3.5Go. It's like some process doesn't "unallocate" the memory

– ouzmoutous
May 2 '16 at 15:44





@rush, I did not save this info, but my htop was green for 3.5Go. It's like some process doesn't "unallocate" the memory

– ouzmoutous
May 2 '16 at 15:44










1 Answer
1






active

oldest

votes


















1














Cache.



A good summary at http://www.linuxatemyram.com/.




Linux is borrowing unused memory for disk caching. This makes it looks
like you are low on memory, but you are not! Everything is fine!




To clear the caches use this command, as root, and then observe resulting memory usage.



echo 3 > /proc/sys/vm/drop_caches





share|improve this answer


















  • 1





    Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

    – Stephen Kitt
    May 2 '16 at 11:35











  • I clear cache (1,2 and 3). So it was not the reason :S

    – ouzmoutous
    May 2 '16 at 11:52











Your Answer








StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f280553%2fmemory-not-used-any-more-but-still-allocated%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1














Cache.



A good summary at http://www.linuxatemyram.com/.




Linux is borrowing unused memory for disk caching. This makes it looks
like you are low on memory, but you are not! Everything is fine!




To clear the caches use this command, as root, and then observe resulting memory usage.



echo 3 > /proc/sys/vm/drop_caches





share|improve this answer


















  • 1





    Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

    – Stephen Kitt
    May 2 '16 at 11:35











  • I clear cache (1,2 and 3). So it was not the reason :S

    – ouzmoutous
    May 2 '16 at 11:52
















1














Cache.



A good summary at http://www.linuxatemyram.com/.




Linux is borrowing unused memory for disk caching. This makes it looks
like you are low on memory, but you are not! Everything is fine!




To clear the caches use this command, as root, and then observe resulting memory usage.



echo 3 > /proc/sys/vm/drop_caches





share|improve this answer


















  • 1





    Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

    – Stephen Kitt
    May 2 '16 at 11:35











  • I clear cache (1,2 and 3). So it was not the reason :S

    – ouzmoutous
    May 2 '16 at 11:52














1












1








1







Cache.



A good summary at http://www.linuxatemyram.com/.




Linux is borrowing unused memory for disk caching. This makes it looks
like you are low on memory, but you are not! Everything is fine!




To clear the caches use this command, as root, and then observe resulting memory usage.



echo 3 > /proc/sys/vm/drop_caches





share|improve this answer













Cache.



A good summary at http://www.linuxatemyram.com/.




Linux is borrowing unused memory for disk caching. This makes it looks
like you are low on memory, but you are not! Everything is fine!




To clear the caches use this command, as root, and then observe resulting memory usage.



echo 3 > /proc/sys/vm/drop_caches






share|improve this answer












share|improve this answer



share|improve this answer










answered May 2 '16 at 11:16









stevesteve

14k22452




14k22452







  • 1





    Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

    – Stephen Kitt
    May 2 '16 at 11:35











  • I clear cache (1,2 and 3). So it was not the reason :S

    – ouzmoutous
    May 2 '16 at 11:52













  • 1





    Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

    – Stephen Kitt
    May 2 '16 at 11:35











  • I clear cache (1,2 and 3). So it was not the reason :S

    – ouzmoutous
    May 2 '16 at 11:52








1




1





Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

– Stephen Kitt
May 2 '16 at 11:35





Look at the output of free given in the question: it only shows ~80MB in the cache and disk buffers.

– Stephen Kitt
May 2 '16 at 11:35













I clear cache (1,2 and 3). So it was not the reason :S

– ouzmoutous
May 2 '16 at 11:52






I clear cache (1,2 and 3). So it was not the reason :S

– ouzmoutous
May 2 '16 at 11:52


















draft saved

draft discarded
















































Thanks for contributing an answer to Unix & Linux Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f280553%2fmemory-not-used-any-more-but-still-allocated%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown






Popular posts from this blog

How to check contact read email or not when send email to Individual?

Bahrain

Postfix configuration issue with fips on centos 7; mailgun relay