Could someone from the list help me to understand the memory usage by SMB process?. I have a samba production server with about 50-70 SMB process. Initially we had 2gb of RAM and the top command showed almost all memory had been used. There were delays in the file access and listing directories from user side. Yesterday evening we had increased the memory to 4 GB and it showed around 3GB free. But this morning when all users started accessing the files it went back to almost near to old figure. (about 1mb free space). Before we upgrade to further (say 8gb) I would like to know how much memory each SMB process will take. ' Rajeev R. Veedu
On Tue, Aug 21, 2007 at 10:59:01AM +0400, Rajeev R Veedu wrote:> Could someone from the list help me to understand the memory usage by SMB > process?. I have a samba production server with about 50-70 SMB process. > Initially we had 2gb of RAM and the top command showed almost all memory had > been used. There were delays in the file access and listing directories from > user side. > > Yesterday evening we had increased the memory to 4 GB and it showed around > 3GB free. But this morning when all users started accessing the files it > went back to almost near to old figure. (about 1mb free space). Before we > upgrade to further (say 8gb) I would like to know how much memory each SMB > process will take. 'The thumb rule for smbd is 2-3MB of real memory per connected client. So with 2GB of RAM you definitely have enough RAM. The slowdown you see is almost 100% due to other things. The fact that you only see very little memory free is a good thing and it won't change if you put 16gig into your box: All non-used memory is used as cache. Volker -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: not available Url : http://lists.samba.org/archive/samba/attachments/20070821/be48398e/attachment.bin
> Yesterday evening we had increased the memory to 4 GB and it showed around > 3GB free. But this morning when all users started accessing the files it > went back to almost near to old figure. (about 1mb free space). Before we > upgrade to further (say 8gb) I would like to know how much memory each SMB > process will take. ' > >You do know that file cache is counted in the amount of free memory on a linux system. So any linux box that is on for long enough will show only a few MB free? Unless you are seeing swap being used there should be no problem with this and you probably do not need any more memory. My home computer has 4GB of memory and from the free command I have 33MB free but 3.15GB of my memory is file cache. I rebooted yesterday so I would expect the 33MB to go down some more. # free total used free shared buffers cached Mem: 4048432 4015412 33020 0 177512 2942980 -/+ buffers/cache: 894920 3153512 Swap: 7823632 696 7822936 John
---------- Forwarded message ---------- From: John Drescher <drescherjm@gmail.com> Date: Aug 21, 2007 10:00 AM Subject: Re: [Samba] Memory usage To: rajeev@cracknell.com> What else does it make the machine slow.Possibly permissions. Maybe the filesystem choice. It could also be filename case handling as linux is case sensitive and windows is not. Are you using ldap or ADS?> Is it the raid. I have 8 WD SATADoubtful.> HDD with raid ready (3mbps) hard disks on a 8 port 3ware controller.I have seen complaints of poor performance with 3ware controllers although I don't have any on my linux systems so I do not know. Do you have write back cache on?> Does > anyone have a comparison on SATA raid and SAS raid disk. As you know SAS > disk are very expensive I would like to know from experts in the list who > can tell me which of the following is best. > > 1) 2 servers each having 2.0TB raid disk with SAS drives, 2GB ram and > standard other features. > 2) 4 No servers with 1TB each with 2GB ram and standard other features. >I can't compare that as I have never had a SAS. My servers are home built machines with 1.2 to 3TB of software raid (mostly 6) with 2GB to 4GB of ram all running 64 bit gentoo and have 1 or 2 Opteron processors.> > If the projects are distributed in the 2 option do you think it would be > better than 1 sty?. as you know the price of SATA disk is much cheaper than > the SAS disk and we could nearly by 4 servers for that money. >I have 10TB of linux software raid5 and raid6 using dozens of SATA disks on a nearly 100% gigabit network with about 100 machines and most of this data is accessed via samba. I have seen a few speed problems but for the most part all works smoothly. One case of a speed problem is a DICOM scrubbing application that reads up to 100,000 512KB files off one server, removes patient info from the headers and stores this data on a second server. In normal conditions this operation is about 5 to 10 of these files per second but at times this slows to 1 per second. When this happens I see on the samba server that the samba process is taking > 25% of the CPU time (which it never does when it is working) so after stopping this scrubbing process and kill the offending smbd process all is well again. John -- John M. Drescher