Sponsored Content
Top Forums UNIX for Advanced & Expert Users Linux Virtual Memory Question Post 302559634 by jlliagre on Tuesday 27th of September 2011 06:16:26 PM
Old 09-27-2011
Quote:
Originally Posted by Corona688
Virtual memory is virtual. If the application doesn't actually use it, it doesn't get stored anywhere at all.
You might be confusing with allocated memory.
Virtual memory as reported by top is the sum of memory present either on disk (mostly SWAP) or on RAM (RES).
 

10 More Discussions You Might Find Interesting

1. News, Links, Events and Announcements

Linux Virtual Memory Book

. (0 Replies)
Discussion started by: Driver
0 Replies

2. Shell Programming and Scripting

get physical and virtual memory

What command can i use to get the physical and virtual memory of a database? (7 Replies)
Discussion started by: tads98
7 Replies

3. UNIX for Dummies Questions & Answers

virtual memory

Hi, can anyone explain me what virtual memory is ( for which we use vmstat commande line ) comparing with RAM ? many thanks before. (2 Replies)
Discussion started by: big123456
2 Replies

4. Programming

about virtual memory and memory leak

Hi, First of all I appreciate this group very much for its informative discussions and posts. Here is my question. I have one process whose virtual memory size increases linearly from 6MB to 12MB in 20 minutes. Does that mean my process has memory leaks? In what cases does the... (4 Replies)
Discussion started by: shriashishpatil
4 Replies

5. HP-UX

Virtual Memory

Hi! I work with HP-UX and I have to monitorize the use of virtual memory for different processes. (java processes for Tibco Adapter) And if these processes exceed a limit send a message to the syslog. I donīt know how to monitorize this... Should I do a script? or use an aplication, for example... (3 Replies)
Discussion started by: Kurohana
3 Replies

6. AIX

ulimits max locked memory virtual memory

Hi, Would any one be so kind to explain me : are ulimits defined for each user seperately ? When ? Specialy what is the impact of : max locked memory and virtual memory on performance of applications for a user. Many thanks. PS : this is what I can see in MAN : ulimit ] ... (5 Replies)
Discussion started by: big123456
5 Replies

7. UNIX for Dummies Questions & Answers

cpu, memory and virtual memory usage

Hi All, Does anyone know what the best commands in the UNIX command line are for obtaining this info: current CPU usage memory usage virtual memory usage preferably with date and time parameters too? thanks ocelot (4 Replies)
Discussion started by: ocelot
4 Replies

8. UNIX for Dummies Questions & Answers

Virtual Memory

Hi, Can anyone please help me workout how much virtual memory I have running on a T2000 running Solaris 10. Thanks # df -h swap 3.5G 1.0M 3.5G 1% /etc/svc/volatile swap 3.5G 208K 3.5G 1% /tmp swap 3.5G 56K ... (2 Replies)
Discussion started by: jamba1
2 Replies

9. UNIX for Advanced & Expert Users

What is the function to get address of the virtual memory block in linux??

I want address of current virtual memory block? i am using fedora10:wall::wall: (1 Reply)
Discussion started by: powyama
1 Replies

10. UNIX for Beginners Questions & Answers

Virtual Memory in UNIX

So, I would ask you a piece of advice about which books or titles could give me comprehensive information about virtual memory in UNIX. Especially, I would found out that virtual address translation corresponds structures of kernel! Thanks! (2 Replies)
Discussion started by: Fadedfate
2 Replies
ddi_umem_lock(9F)					   Kernel Functions for Drivers 					 ddi_umem_lock(9F)

NAME
ddi_umem_lock, ddi_umem_unlock - lock and unlock memory pages SYNOPSIS
#include <sys/ddi.h> #include <sys/sunddi.h> int ddi_umem_lock(caddr_t addr, size_t len, int flags, ddi_umem_cookie_t *cookiep); void ddi_umem_unlock(ddi_umem_cookie_t cookie); INTERFACE LEVEL
Solaris DDI specific (Solaris DDI) PARAMETERS
ddi_umem_lock addr Virtual address of memory object len Length of memory object in bytes flags Valid flags include: DDI_UMEMLOCK_READ Memory pages are locked to be read from. (Disk write or a network send.) DDI_UMEMLOCK_WRITE Memory pages are locked to be written to. (Disk read or a network receive.) cookiep Pointer to a kernel memory cookie. ddi_umem_unlock cookie Kernel memory cookie allocated by ddi_umem_lock(). DESCRIPTION
The ddi_umem_lock(9F) function locks down the physical pages (including I/O pages) that correspond to the current process' virtual address range [addr, addr + size) and fills in a cookie representing the locked pages. This cookie can be used to create a buf(9S) structure that can be used to perform I/O (see ddi_umem_iosetup(9F) and ddi_dma_buf_bind_handle(9F)), or it can be used with devmap_umem_setup(9F) to export the memory to an application. The virtual address and length specified must be at a page boundary and the mapping performed in terms of the system page size. See page- size(1). The flags argument indicates the intended use of the locked memory. Set flags to DDI_UMEMLOCK_READ if the memory pages will be read (for example, in a disk write or a network send.) Set flags to DDI_UMEMLOCK_WRITE if the memory pages will be written (for example, in a disk read or a network receive). You must choose one (and only one) of these values. To unlock the locked pages, the drivers call ddi_umem_unlock(9F) with the cookie obtained from ddi_umem_lock(9F). The process is not allowed to exec(2) or fork(2) while its physical pages are locked down by the device driver. The device driver must ensure that the physical pages have been unlocked after the application has called close(2). RETURN VALUES
On success, a 0 is returned. Otherwise, one of the following errno values is returned. EFAULT User process has no mapping at that address range or does not support locking EACCES User process does not have the required permission. ENOMEM The system does not have sufficient resources to lock memory. EAGAIN Could not allocate system resources required to lock the pages. The ddi_umem_lock() could succeed at a later time. EINVAL Requested memory is not aligned on a system page boundary. CONTEXT
The ddi_umem_lock() function can only be called from user context; ddi_umem_unlock() from user, kernel, and interrupt contexts. SEE ALSO
ddi_umem_iosetup(9F), ddi_dma_buf_bind_handle(9F), devmap_umem_setup(9F), ddi_umem_alloc(9F) NOTES
The ddi_umem_lock(9F) function consumes physical memory. The driver is responsible for a speedy unlock to free up the resources. ddi_umem_unlock() can defer unlocking of the pages to a later time depending on the implementation. SunOS 5.10 4 Feb 2003 ddi_umem_lock(9F)
All times are GMT -4. The time now is 01:53 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy