*New 12.1 series Release:
2019-11-08: XigmaNAS 12.1.0.4.7091 - released!

*New 11.3 series Release:
2019-10-19: XigmaNAS 11.3.0.4.7014 - released


We really need "Your" help on XigmaNAS https://translations.launchpad.net/xigmanas translations. Please help today!

Producing and hosting XigmaNAS costs money. Please consider donating for our project so that we can continue to offer you the best.
We need your support! eg: PAYPAL

High Memory Usage

XigmaNAS Basic Tune-up
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
lawrencezarb
NewUser
NewUser
Posts: 11
Joined: 24 Dec 2014 11:31
Status: Offline

High Memory Usage

#1

Post by lawrencezarb » 23 Jan 2017 12:45

I am currently running 11.0.0.4 rev 3460 and notices that my memory useage at idle is always at around 94%. I do use ZFS and use the sytem as a Nas server for a media playback device.

TOP seems to indicated high memory useage for php-cgi processes as below:

last pid: 11296; load averages: 0.55, 0.52, 0.36
34 processes: 3 running, 31 sleeping
CPU: 8.3% user, 0.0% nice, 17.9% system, 0.0% interrupt, 73.8% idle
Mem: 30M Active, 39M Inact, 736M Wired, 12M Buf, 12M Free
Swap: 1024M Total, 53M Used, 971M Free, 5% Inuse

PID USERNAME THR PRI NICE SIZE RES STATE C TIME WCPU COMMAND
4070 root 1 20 0 20120K 2832K CPU0 0 0:04 19.28% top
2438 root 1 52 0 393M 15112K RUN 1 0:10 3.27% php-cgi
3165 root 1 20 0 51436K 4828K select 2 0:01 1.20% sshd
1991 root 1 20 0 10436K 1180K select 3 0:01 0.33% powerd
2442 root 1 52 0 391M 11764K accept 0 0:06 0.00% php-cgi
2421 root 1 52 0 391M 12584K accept 0 0:01 0.00% php-cgi
2418 root 1 20 0 47472K 3760K kqread 2 0:01 0.00% lighttpd
2422 root 1 21 0 391M 9636K accept 2 0:01 0.00% php-cgi
3177 root 1 20 0 21732K 3276K pause 1 0:00 0.00% csh
2420 root 1 52 0 391M 0K wait 2 0:00 0.00% <php-cgi>
2069 root 1 20 0 233M 4496K select 0 0:00 0.00% nmbd
2517 root 1 52 0 13688K 2252K wait 0 0:00 0.00% bash
2258 root 1 24 0 12564K 796K nanslp 1 0:00 0.00% cron
2419 root 1 52 0 391M 0K wait 0 0:00 0.00% <php-cgi>
1801 root 7 52 0 8304K 1340K rpcsvc 2 0:00 0.00% nfsd
2018 root 1 20 0 32308K 2516K select 0 0:00 0.00% proftpd
2444 root 2 20 0 10792K 1764K nanslp 0 0:00 0.00% inadyn
2071 root 1 52 0 298M 9460K select 1 0:00 0.00% smbd
1800 root 1 20 0 8304K 1580K select 3 0:00 0.00% nfsd
1660 root 1 20 0 10492K 1456K select 1 0:00 0.00% syslogd
2721 root 1 52 0 21732K 2884K pause 0 0:00 0.00% csh
1498 root 1 20 0 9512K 1140K select 2 0:00 0.00% devd
1682 root 1 20 0 10424K 1384K select 1 0:00 0.00% rpcbind
2718 root 1 52 0 43732K 2200K wait 0 0:00 0.00% login
1807 root 1 52 0 10452K 1320K rpcsvc 1 0:00 0.00% rpc.lockd
2760 root 1 52 0 13224K 2380K ttyin 1 0:00 0.00% sh
2076 root 1 20 0 295M 6292K select 1 0:00 0.00% smbd
2719 root 1 46 0 10460K 1532K ttyin 2 0:00 0.00% getty
11296 root 1 72 0 8308K 1536K CPU3 3 0:00 0.00% sysctl
2720 root 1 46 0 10460K 1532K ttyin 1 0:00 0.00% getty
2167 root 1 20 0 26596K 2352K select 3 0:00 0.00% sshd
1804 root 1 20 0 266M 1340K select 2 0:00 0.00% rpc.statd
1784 root 1 52 0 10468K 1620K select 3 0:00 0.00% mountd
10789 root 1 52 0 6244K 1476K nanslp 3 0:00 0.00% sleep

spy0r
Advanced User
Advanced User
Posts: 161
Joined: 18 Jun 2015 12:24
Location: Munich, Germany
Status: Offline

Re: High Memory Usage

#2

Post by spy0r » 23 Jan 2017 13:10

Hi,

you should read: viewtopic.php?f=15&t=9536
I'm sure this can answer your questions.

Greetings
NAS4Free 11.0.0.4 x64-embedded - Lian Li Q25b - AsRock Rack C2550D4I - 4x8Gb ECC Ram - 128Gb SSD Swap/Log/Extensions - RaidZ1: 3x3Tb Western Digital Red (WD30EFRX) - Backup: 1x8Tb Seagate Archive (ST8000AS0002) - APC Back UPS PRO (550VA)

lawrencezarb
NewUser
NewUser
Posts: 11
Joined: 24 Dec 2014 11:31
Status: Offline

Re: High Memory Usage

#3

Post by lawrencezarb » 23 Jan 2017 14:25

Hi spy0r, Thanks.

I read the thread and changing the vfs.zfs.arc_max seems in loader.conf to make no difference what so ever.

When I run sysctl vfs.zfs.arc_max the result is always the same:

vfs.zfs.arc_max: 536153600

spy0r
Advanced User
Advanced User
Posts: 161
Joined: 18 Jun 2015 12:24
Location: Munich, Germany
Status: Offline

Re: High Memory Usage

#4

Post by spy0r » 24 Jan 2017 09:34

i'm not sure, but i think you have to activate that line in the loader.conf if you did this via GUI, there should be a small checkbox or something like that...
NAS4Free 11.0.0.4 x64-embedded - Lian Li Q25b - AsRock Rack C2550D4I - 4x8Gb ECC Ram - 128Gb SSD Swap/Log/Extensions - RaidZ1: 3x3Tb Western Digital Red (WD30EFRX) - Backup: 1x8Tb Seagate Archive (ST8000AS0002) - APC Back UPS PRO (550VA)

lawrencezarb
NewUser
NewUser
Posts: 11
Joined: 24 Dec 2014 11:31
Status: Offline

Re: High Memory Usage

#5

Post by lawrencezarb » 24 Jan 2017 10:33

yes I did that and notice the the line was activated in loader.conf.local. I also tried to add the line in loader.conf from the ssh shell, but after a reboot I still get the same results.

spy0r
Advanced User
Advanced User
Posts: 161
Joined: 18 Jun 2015 12:24
Location: Munich, Germany
Status: Offline

Re: High Memory Usage

#6

Post by spy0r » 24 Jan 2017 13:38

okay, in this case anybody else need to help.

My question is - why do you want to reduce the RAM for zfs usage? You have that less memory, you should give zfs every byte you got. It's not a bug that you have high ram usage... Does you swap fill up over ~1Gb?
NAS4Free 11.0.0.4 x64-embedded - Lian Li Q25b - AsRock Rack C2550D4I - 4x8Gb ECC Ram - 128Gb SSD Swap/Log/Extensions - RaidZ1: 3x3Tb Western Digital Red (WD30EFRX) - Backup: 1x8Tb Seagate Archive (ST8000AS0002) - APC Back UPS PRO (550VA)

lawrencezarb
NewUser
NewUser
Posts: 11
Joined: 24 Dec 2014 11:31
Status: Offline

Re: High Memory Usage

#7

Post by lawrencezarb » 24 Jan 2017 14:01

I dont use ZFS, so I have no need for it use up the memory. The swap file does not fill up but it does get used. The system seems sluggish when access files, which I assume is due to the memory availability.

spy0r
Advanced User
Advanced User
Posts: 161
Joined: 18 Jun 2015 12:24
Location: Munich, Germany
Status: Offline

Re: High Memory Usage

#8

Post by spy0r » 24 Jan 2017 15:21

lawrencezarb wrote:
23 Jan 2017 12:45
I am currently running 11.0.0.4 rev 3460 and notices that my memory useage at idle is always at around 94%. I do use ZFS and use the sytem as a Nas server for a media playback device.

I think there was missing a "NOT". In that case you don't need to tweak zfs parameters...
NAS4Free 11.0.0.4 x64-embedded - Lian Li Q25b - AsRock Rack C2550D4I - 4x8Gb ECC Ram - 128Gb SSD Swap/Log/Extensions - RaidZ1: 3x3Tb Western Digital Red (WD30EFRX) - Backup: 1x8Tb Seagate Archive (ST8000AS0002) - APC Back UPS PRO (550VA)

lawrencezarb
NewUser
NewUser
Posts: 11
Joined: 24 Dec 2014 11:31
Status: Offline

Re: High Memory Usage

#9

Post by lawrencezarb » 25 Jan 2017 09:24

Sorry for the Typo, yes the NOT is missing and I can understand that it sheds a different light on my problem.

awebster
NewUser
NewUser
Posts: 2
Joined: 14 Sep 2016 02:15
Status: Offline

Re: High Memory Usage

#10

Post by awebster » 05 Feb 2017 20:11

I've got something very similar going on. Maybe 8 or 9 <php-cgi> processes that top says have SIZE 391M. I'm using 11.0.0.4 r3460. I've got some home devices that stream http from the nas4free webserver. I AM using ZFS.
I haven't noticed any issues with the high memory usage. It just shows that 80% is used of 8gig memory. I may see if I have another 8 gig stick to throw in there.

lawrencezarb
NewUser
NewUser
Posts: 11
Joined: 24 Dec 2014 11:31
Status: Offline

Re: High Memory Usage

#11

Post by lawrencezarb » 06 Feb 2017 12:03

I have increased my ram form 1G to 2 G and now the memory useage is down to 50%

User avatar
zoon01
Developer
Developer
Posts: 771
Joined: 20 Jun 2012 21:06
Location: Netherlands
Contact:
Status: Offline

Re: High Memory Usage

#12

Post by zoon01 » 11 Feb 2017 16:19

lawrencezarb wrote:
06 Feb 2017 12:03
I have increased my ram form 1G to 2 G and now the memory useage is down to 50%
You should add more ram if you can.
The system you do use is really on it's minimum specification.
System specs: XigmaNAS 11.2.0.4 -embedded on Samsung 860 EVO 256GB and Supermicro X10SL7-F w / Bios v3.2, IPMI v.03.84 / CPU E3-1241 v3 @ 3.50GHz - 32GB Crucial DDR3L 1600mhz ECC 1.35v , LSI 2308 on PH20.00.07.00 IT mode, Storage: 5x Western Digital Red (WD30EFRX) raidz

Development system is same system in virtualbox.

leo1986pc
Starter
Starter
Posts: 24
Joined: 05 May 2014 13:43
Location: Reggio Emilia, Italy
Status: Offline

Re: High Memory Usage

#13

Post by leo1986pc » 20 Feb 2017 17:53

zoon01 wrote:
lawrencezarb wrote:
06 Feb 2017 12:03
I have increased my ram form 1G to 2 G and now the memory useage is down to 50%
You should add more ram if you can.
The system you do use is really on it's minimum specification.

Code: Select all

  PID USERNAME      THR PRI NICE   SIZE    RES STATE   C   TIME    WCPU COMMAND
 2590 root            9  20    0   260M 32664K nanslp  1 346:21  14.36% fuppesd
 2473 root            1  20    0   396M 44992K piperd  0   0:10   0.10% php-cgi
 2212 transmission    3  20    0 68752K  8272K kqread  0   2:20   0.00% transmission-daemon
 1881 root            1  20    0 10436K  2048K select  3   0:12   0.00% powerd
 2467 root            1  20    0 49520K  6972K kqread  2   0:12   0.00% lighttpd
 2472 root            1  52    0   396M 46364K accept  0   0:10   0.00% php-cgi
 1908 root            1  20    0 32308K  6704K select  1   0:07   0.00% proftpd
 2022 root            1  20    0   231M 15268K select  1   0:07   0.00% nmbd
 1667 root            1  20    0 10492K  2252K select  3   0:04   0.00% syslogd
 2493 root            2  20    0 10792K  2612K nanslp  0   0:04   0.00% inadyn
 2024 root            1  20    0   296M 24432K select  0   0:01   0.00% smbd
 2318 root            1  20    0 12564K  2384K nanslp  2   0:01   0.00% cron
 2029 root            2  20    0   295M 20180K select  0   0:01   0.00% smbd
 2267 root            1  20    0 26596K  5548K select  2   0:00   0.00% sshd
 2382 root            1  20    0  8784K  2520K select  0   0:00   0.00% mDNSResponderPosix
 1539 root            1  20    0  9512K  5464K select  1   0:00   0.00% devd
 2072 root            1  20    0 26744K  4472K nanslp  0   0:00   0.00% smartd
 2468 root            1  52    0   389M 40664K wait    0   0:00   0.00% php-cgi
 2471 root            1  52    0   389M 40664K wait    1   0:00   0.00% php-cgi
40184 root            1  22    0 20120K  3008K CPU2    2   0:00   0.00% top
 2699 root            1  52    0 21732K  3640K pause   0   0:00   0.00% csh
 2696 root            1  52    0 43732K  2916K wait    3   0:00   0.00% login
 2713 root            1  52    0 13224K  3180K ttyin   3   0:00   0.00% sh
 2698 root            1  52    0 10460K  2092K ttyin   0   0:00   0.00% getty
 2697 root            1  52    0 10460K  2092K ttyin   1   0:00   0.00% getty
I have the same problem but my system's memory is 4GB.

With N4F 10, the same configuration with and 2 VMs active (with low memory but active) I had an average usage of 85-90% in my system.

Do I have to increase the memory?

User avatar
zoon01
Developer
Developer
Posts: 771
Joined: 20 Jun 2012 21:06
Location: Netherlands
Contact:
Status: Offline

Re: High Memory Usage

#14

Post by zoon01 » 20 Feb 2017 18:22

The more ram you have, the better the system can run all it's services, and with zfs and 2 vm's active I think you need at least 8GB to 16GB te get in optimal performance.

But who am I to say so, I use 32Gb ram now after running for a while on 16GB.
ZFS loves RAM and so does my VM's
System specs: XigmaNAS 11.2.0.4 -embedded on Samsung 860 EVO 256GB and Supermicro X10SL7-F w / Bios v3.2, IPMI v.03.84 / CPU E3-1241 v3 @ 3.50GHz - 32GB Crucial DDR3L 1600mhz ECC 1.35v , LSI 2308 on PH20.00.07.00 IT mode, Storage: 5x Western Digital Red (WD30EFRX) raidz

Development system is same system in virtualbox.

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4940
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: High Memory Usage

#15

Post by raulfg3 » 20 Feb 2017 19:32

+1

I have 6GB on one NAS and need to revise VM not to discontrol, (ZFS+Transmission+minidlna+2 VM is too much for my only 6GB RAM NAS)
12.0.0.4 (revision 6766)+OBI on SUPERMICRO X8SIL-F 8GB of ECC RAM, 12x3TB disk in 3 vdev in RaidZ1 = 32TB Raw size only 22TB usable

Wiki
Last changes

Post Reply

Return to “XigmaNAS Basic Tune-up”