08-05-2008
Quote:
get process SpectroSERVER current size if it exceed 3850 MB then
What do you mean by that?
That if the process's resident set size, or virtual size, of it alone,
or including all its children, or those belonging to the same process group etc. exceed this threshold of memory.
What about memory mapped pages or shared memory,
reserved or even used pages on swap?
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hello,
Please help me to know, How to find out the how much amount of process addres space is required/is used for/by a process.
Tnx & Regards
Vishwa. (1 Reply)
Discussion started by: S.Vishwanath
1 Replies
2. Programming
Hi,
In Linux how to find out what will be the stack size allocated for a process?
Actually i have to fork n number of processess, and will call exec. I will be execing an executable which is already multithreaded and each thread size is defined. My doubt is how to know if the size of the... (2 Replies)
Discussion started by: rvan
2 Replies
3. Shell Programming and Scripting
Hi,
I am writing a script which takes the input file name and concat as a new file by appending a "1" to the file name. However i am not able to get the size of this new file. I am not sure where i am going wrong. Please check the script and help me get this working.
#!/bin/sh ... (1 Reply)
Discussion started by: ragsnovel
1 Replies
4. UNIX for Dummies Questions & Answers
Hi, I have a directory PRIVATE in which I have several directories and each of these have several files. Therefore, I need to find those files by size and date to back up those files in another directory.
I don't know how to implement this shell script using ''find''.
appreciate any... (1 Reply)
Discussion started by: dadadc
1 Replies
5. Shell Programming and Scripting
Please could anyone provide me the Command/script to find the size and usage of Unix box ASAP ? (6 Replies)
Discussion started by: sakthifire
6 Replies
6. Shell Programming and Scripting
Hi,
I need to execute a script to find the tablespace size in oracle.But i get an error.:confused:
Script Executed:-
#!/bin/ksh
ORACLE_SID= oracelinstance
ORACLE_HOME= oracle path
PATH=$ORACLE_HOME/bin
export ORACLE_SID ORACLE_HOME PATH
sqlplus... (4 Replies)
Discussion started by: vighna
4 Replies
7. Programming
Hi,
I am looking to work on unix systems which include (hp-ux, ibm aix, solaris and linux). I want to get the total virtual address space of a process, the used virtual memory i am able to get without any problem. I have tried using getrlimit and getrlimit64, but that gives only ... (4 Replies)
Discussion started by: uiqbal
4 Replies
8. Shell Programming and Scripting
Hi
I have to find size of subdirectory and automate it in CRON.
Eg: parent directory name is NVBKP inside it there are several subdirectories
I want to get the size of recent two subdirectories.
I have tried ls -ltr diretory path | tail -2
But it is providing only size of the folder not... (8 Replies)
Discussion started by: ankit2012
8 Replies
9. Shell Programming and Scripting
Hi All, Looking for a quick LINUX shell script which can continuously monitors the flle size, report the process which is creating a file greater than certain limit and also kill that process. Can someone please help me on this? (4 Replies)
Discussion started by: vasavimacherla
4 Replies
10. UNIX for Beginners Questions & Answers
I wish to by pass a process if the file is over a certain size?
not sure this makes sense
current bit of the script below
#if we are bypAssing the OCR
if ; then
echo Bypassing HOTFOLDER OCR
HOT_FOLDER_DIR=$BATCH_POST_OCR_DIR;
potential change below? would this work would I need... (1 Reply)
Discussion started by: worky
1 Replies
MLOCK(2) BSD System Calls Manual MLOCK(2)
NAME
mlock, munlock -- lock (unlock) physical pages in memory
SYNOPSIS
#include <sys/mman.h>
int
mlock(const void *addr, size_t len);
int
munlock(const void *addr, size_t len);
DESCRIPTION
The mlock system call locks a set of physical pages into memory. The pages are associated with a virtual address range that starts at addr
and extends for len bytes. The munlock call unlocks pages that were previously locked by one or more mlock calls. For both calls, the addr
parameter should be aligned to a multiple of the page size. If the len parameter is not a multiple of the page size, it will be rounded up
to be so. The entire range must be allocated.
After an mlock call, the indicated pages will cause neither a non-resident page nor address-translation fault until they are unlocked. They
may still cause protection-violation faults or TLB-miss faults on architectures with software-managed TLBs. The physical pages remain in
memory until all locked mappings for the pages are removed.
Multiple processes may have the same physical pages locked via their own virtual address mappings. Similarly, a single process may have
pages multiply-locked via different virtual mappings of the same pages or via nested mlock calls on the same address range. Unlocking is
performed explicitly by munlock or implicitly by a call to munmap, which deallocates the unmapped address range. Locked mappings are not
inherited by the child process after a fork(2).
Because physical memory is a potentially scarce resource, processes are limited in how much memory they can lock down. A single process can
mlock the minimum of a system-wide ``wired pages'' limit and the per-process RLIMIT_MEMLOCK resource limit.
RETURN VALUES
A return value of 0 indicates that the call succeeded and all pages in the range have either been locked or unlocked, as requested. A return
value of -1 indicates an error occurred and the locked status of all pages in the range remains unchanged. In this case, the global location
errno is set to indicate the error.
ERRORS
mlock() and munlock() will fail if:
[EINVAL] The address given is not page-aligned or the length is negative.
[ENOMEM] Part or all of the specified address range is not mapped to the process.
mlock() will fail if:
[EAGAIN] Locking the indicated range would exceed either the system or per-process limit for locked memory.
[ENOMEM] Some portion of the indicated address range is not allocated. There was an error faulting/mapping a page.
munlock() will fail if:
[ENOMEM] Some portion of the indicated address range is not allocated. Some portion of the indicated address range is not locked.
LEGACY SYNOPSIS
#include <sys/types.h>
#include <sys/mman.h>
The include file <sys/types.h> is necessary.
int
mlock(caddr_t addr, size_t len);
int
munlock(caddr_t addr, size_t len);
The variable type of addr has changed.
SEE ALSO
fork(2), mincore(2), minherit(2), mmap(2), munmap(2), setrlimit(2), getpagesize(3), compat(5)
BUGS
Unlike The Sun implementation, multiple mlock calls on the same address range require the corresponding number of munlock calls to actually
unlock the pages, i.e. mlock nests. This should be considered a consequence of the implementation and not a feature.
The per-process resource limit is a limit on the amount of virtual memory locked, while the system-wide limit is for the number of locked
physical pages. Hence a process with two distinct locked mappings of the same physical page counts as 2 pages against the per-process limit
and as only a single page in the system limit.
HISTORY
The mlock() and munlock() functions first appeared in 4.4BSD.
BSD
June 2, 1993 BSD