Sponsored Content
Operating Systems Linux Red Hat Does it make sense to reduce the total shared memory Post 302992198 by gandolf989 on Wednesday 22nd of February 2017 03:19:09 PM
Old 02-22-2017
Does it make sense to reduce the total shared memory

We have several dozen Redhat 5, 6 and 7 servers that are running Oracle databases. On some databases we are using automatic memory management, which uses shared memory. On other databases we are use manual memory management, which does not use shared memory.

When I see that a server is swapping and not using that much shared memory, does it make sense to shrink the amount of shared memory allocated to reduce the swap usage? I have read that setting /dev/shm does not allocate memory. But I wonder if it is still preventing non shared memory from staying in physical memory.

Thanks.

Code:
$ ~ > df -h /dev/shm
Filesystem            Size  Used Avail Use% Mounted on
tmpfs                  26G  5.4G   20G  22% /dev/shm
$ ~ > free -m
             total       used       free     shared    buffers     cached
Mem:         32186      27556       4629          0         30      23724
-/+ buffers/cache:       3801      28384
Swap:        20474       4375      16098

 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Shared memory shortage but lots of unused memory

I am running HP-UX B.11.11. I'm increasing a parameter for a database engine so that it uses more memory to buffer the disk drive (to speed up performance). I have over 5GB of memory not being used. But when I try to start the DB with the increased buffer parameter I get told. "Not... (1 Reply)
Discussion started by: cjcamaro
1 Replies

2. UNIX for Advanced & Expert Users

How to reduce GZIP memory usage

I am using the ZLIB_VERSION "1.2.3" . The memory requirement for Zlib/GZIP compression is stated as /* The memory requirements for deflate are (in bytes): (1 << (windowBits+2)) + (1 << (memLevel+9)) that is: 128K for windowBits=15 + 128K for memLevel = 8 (default values) ... (0 Replies)
Discussion started by: Parmod Garg
0 Replies

3. High Performance Computing

Rocks clusters make sense for educational environments

08-18-2008 11:00 AM Cluster computing has played a pivotal role in the way research is conducted in educational environments. Because the amount of available money and hardware varies between university researchers, often it's necessary to find a clustering solution that can work well on a small... (0 Replies)
Discussion started by: Linux Bot
0 Replies

4. UNIX for Dummies Questions & Answers

a for loop that doesn't make sense

I've been referring bash info for processes and came across a structure for a process which is defined like typedef struct process { struct process *next; char ** argv . . . }process; What I don't understand is that in the program there's a for loop which goes like this job... (2 Replies)
Discussion started by: sdsd
2 Replies

5. Solaris

How to find Total and Free Physical Memory and Logical Memory in SOLARIS 9

Hi, Im working on Solaris 9 on SPARC-32 bit running on an Ultra-80, and I have to find out the following:- 1. Total Physical Memory in the system(total RAM). 2. Available Physical Memory(i.e. RAM Usage) 3. Total (Logical) Memory in the system 4. Available (Logical) Memory. I know... (4 Replies)
Discussion started by: 0ktalmagik
4 Replies

6. UNIX for Dummies Questions & Answers

trying to make sense of rsync output...

I'm running the following rsync command to sync a directory between the 2 servers: rsync -az --delete --stats /some_dir/ server_name:/some_dir I'm getting the following output: Number of files: 655174 Number of files transferred: 14221 Total file size: 1138531979331 bytes Total... (0 Replies)
Discussion started by: GKnight
0 Replies

7. UNIX for Advanced & Expert Users

sar -d output... does not make sense

Can someone explain the correlation between how sar names the disk drives and how the rest of the OS names the disk drives? sar lists my disk drives as sd0, sd1, sd2, etc..... while format lists my disk drives as c1t0d0, c1t1d0, c1t2d0,etc... And also why sar shows 8 disks but format... (2 Replies)
Discussion started by: s ladd
2 Replies

8. Programming

Shared library with acces to shared memory.

Hello. I am new to this forum and I would like to ask for advice about low level POSIX programming. I have to implement a POSIX compliant C shared library. A file will have some variables and the shared library will have some functions which need those variables. There is one special... (5 Replies)
Discussion started by: iamjag
5 Replies

9. Cybersecurity

Root login in Linux - does it make sense?

I stumbled upon this thread and one aspect of it got me thinking. As i am building a small Linux network right now for a friend i would like to hear your opinion on this. I'd like to respectfully disagree. I think the Linux habit of disabling root login per default is wrong (not entirely... (6 Replies)
Discussion started by: bakunin
6 Replies

10. AIX

AIX flag to reduce size of shared file

I am using xlC (Version: 11.01.0000.0011). While build i am using "-g" to have debug information in build. there are many object files (>500) due to which resultant shared file (.so) will have huge size. I can't reduce optimization level. Is there any way or flag is present by using which i... (2 Replies)
Discussion started by: Abhi04
2 Replies
shmget(2)							   System Calls 							 shmget(2)

NAME
shmget - get shared memory segment identifier SYNOPSIS
#include <sys/types.h> #include <sys/ipc.h> #include <sys/shm.h> int shmget(key_t key, size_t size, int shmflg); DESCRIPTION
The shmget() function returns the shared memory identifier associated with key. A shared memory identifier and associated data structure and shared memory segment of at least size bytes (see Intro(2)) are created for key if one of the following are true: o The key argument is equal to IPC_PRIVATE. o The key argument does not already have a shared memory identifier associated with it, and (shmflg&IPC_CREAT) is true. Upon creation, the data structure associated with the new shared memory identifier is initialized as follows: o The values of shm_perm.cuid, shm_perm.uid, shm_perm.cgid, and shm_perm.gid are set equal to the effective user ID and effective group ID, respectively, of the calling process. o The access permission bits of shm_perm.mode are set equal to the access permission bits of shmflg. shm_segsz is set equal to the value of size. o The values of shm_lpid, shm_nattch shm_atime, and shm_dtime are set equal to 0. o The shm_ctime is set equal to the current time. Shared memory segments must be explicitly removed after the last reference to them has been removed. RETURN VALUES
Upon successful completion, a non-negative integer representing a shared memory identifier is returned. Otherwise, -1 is returned and errno is set to indicate the error. ERRORS
The shmget() function will fail if: EACCES A shared memory identifier exists for key but operation permission (see Intro(2)) as specified by the low-order 9 bits of shmflg would not be granted. EEXIST A shared memory identifier exists for key but both (shmflg&IPC_CREAT) and (shmflg&IPC_EXCL) are true. EINVAL The size argument is less than the system-imposed minimum or greater than the system-imposed maximum. See NOTES. A shared memory identifier exists for key but the size of the segment associated with it is less than size and size is not equal to 0. ENOENT A shared memory identifier does not exist for key and (shmflg&IPC_CREAT) is false. ENOMEM A shared memory identifier and associated shared memory segment are to be created but the amount of available memory is not suf- ficient to fill the request. ENOSPC A shared memory identifier is to be created but the system-imposed limit on the maximum number of allowed shared memory identi- fiers system-wide would be exceeded. See NOTES. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ SEE ALSO
rctladm(1M), Intro(2), setrctl(2), shmctl(2), shmop(2), ftok(3C), getpagesize(3C), attributes(5), standards(5) NOTES
The project.max-shm-memory resource control restricts the total amount of shared memory a project can allocate. The zone.max-shm-memory resource control restricts the total amount of shared memory that can be allocated by a zone. The system-imposed maximum on the size of a shared memory segment is therefore a function of the sizes of any other shared memory segments the calling project might have allocated that are still in use, as well as any other shared memory segments allocated and still in use by processes in the zone. For accounting purposes, segment sizes are rounded up to the nearest multiple of the system page size. See getpagesize(3C). The system-imposed limit on the number of shared memory identifiers is maintained on a per-project basis using the project.max-shm-ids resource control. The zone.max-shm-ids resource control restricts the total number of shared memory identifiers that can be allocated by a zone. See rctladm(1M) and setrctl(2) for information about using resource controls. SunOS 5.11 14 Aug 2006 shmget(2)
All times are GMT -4. The time now is 05:49 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy