08-20-2007
How to get the size of process in Bytes
Hi All,
We have the commands top and ps through which we can find out the size of the running process.
These commnds are giving the size of my process in MB after rounding of the size.
Is there any way by which I can get the size of my process in Bytes or KBytes.
Any help would be greatly apppreciated.
Thanks
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I want to create a script that emails a file created by Informix Ace if the file size is > 0. It is a list of exceptions. No exceptions...no message
This does not work:
THESIZE=`ls -lA /tmp/ds_treo.txt | awk -F' ' '{print $5}'`
if
then
(cat $DSDIR/ds_treo.txt) | mail -s "Treo... (1 Reply)
Discussion started by: poste_d_ordure
1 Replies
2. UNIX for Dummies Questions & Answers
Hi
how can it be that say i have text (xls) file that is 661 bytes when i upload it to Solaris ftp its becomes 650 byes
and when i downloading it back its again 661 bytes
both in my local pc and Solaris ftp the file remains not corrupted and valid (2 Replies)
Discussion started by: umen
2 Replies
3. UNIX for Dummies Questions & Answers
Hi,
i need to know regarding the size type of the files in unix environment..
whether a files or directory will store in which format? kb or bytes ?
please answer to my question...
thanks & regards,
kamal (1 Reply)
Discussion started by: G.K.K
1 Replies
4. Shell Programming and Scripting
hi all
plz help in listing the files with size in bytes.
thnks
-Bali (4 Replies)
Discussion started by: balireddy_77
4 Replies
5. Shell Programming and Scripting
Hi
I need to find and delete 0-4 bytes size files in a folder.
How can I achieve that? (1 Reply)
Discussion started by: kapilk
1 Replies
6. Web Development
Any clues on how to get rid of this PHP error?
PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 71 bytes) in /website/www/includes/functions_manpages.php on line 58
PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 71... (4 Replies)
Discussion started by: Neo
4 Replies
7. Shell Programming and Scripting
While running script I am getting an error like
Few lines in data are not being processed.
After googling it I came to know that adding such line would give some memory to it
ini_set("memory_limit","64M");
my input file size is 1 GB.
Is that memory limit is based on RAM we have on... (1 Reply)
Discussion started by: elamurugu
1 Replies
8. Shell Programming and Scripting
Hey guys I'm new to unix and need help printing files in a specified directory according to size in bytes as well as files with equal bites in alphabetical order
the part i have done so far prints out all files in the directory as well as setting a time limit in which they have been modified
... (2 Replies)
Discussion started by: wessy
2 Replies
9. UNIX for Dummies Questions & Answers
Hello guys. I really hope someone will help me with this one..
So, I have to write this script who:
- creates a file home/student/vmdisk of 10 mb
- formats that file to ext3
- mounts that partition to /mnt/partition
- creates a file /mnt/partition/data. In this file, there will... (1 Reply)
Discussion started by: razolo13
1 Replies
LEARN ABOUT OPENSOLARIS
ps_pdread
ps_pread(3PROC) Process Control Library Functions ps_pread(3PROC)
NAME
ps_pread, ps_pwrite, ps_pdread, ps_pdwrite, ps_ptread, ps_ptwrite - interfaces in libthread_db that target process memory access
SYNOPSIS
#include <proc_service.h>
ps_err_e ps_pread(struct ps_prochandle *ph, psaddr_t addr,
void *buf, size_t size);
ps_err_e ps_pwrite(struct ps_prochandle *ph, psaddr_t addr,
const void *buf, size_t size);
ps_err_e ps_pdread(struct ps_prochandle *ph, psaddr_t addr,
void *buf, size_t size);
ps_err_e ps_pdwrite(struct ps_prochandle *ph, psaddr_t addr,
const void *buf, size_t size);
ps_err_e ps_ptread(struct ps_prochandle *ph, psaddr_t addr,
void *buf, size_t size);
ps_err_e ps_ptwrite(struct ps_prochandle *ph, psaddr_t addr,
const void *buf, size_t size);
DESCRIPTION
These routines copy data between the target process's address space and the controlling process. ps_pread() copies size bytes from address
addr in the target process into buf in the controlling process. pr_pwrite() is like ps_pread() except that the direction of the copy is
reversed; data is copied from the controlling process to the target process.
ps_pdread() and ps_ptread() behave identically to ps_pread(). ps_pdwrite() and ps_ptwrite() behave identically to ps_pwrite(). These func-
tions can be implemented as simple aliases for the corresponding primary functions. They are artifacts of history that must be maintained.
RETURN VALUES
PS_OK The call returned successfully. size bytes were copied.
PS_BADADDR Some part of the address range from addr through addr+size-1 is not part of the target process's address space.
PS_ERR The function did not return successfully.
ATTRIBUTES
See attributes(5) for description of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|MT Level |Safe |
+-----------------------------+-----------------------------+
SEE ALSO
libc_db(3LIB), librtld_db(3LIB), proc_service(3PROC), rtld_db(3EXT), attributes(5), threads(5)
SunOS 5.11 12 Oct 2007 ps_pread(3PROC)