Thank you so much for your reply. I am working with your approach but I'm getting errors when I call free(), I allocated a portion of memory with malloc() and when I call free() I get a error , if I comment out the free() instruction the program runs without this error.
Does you or anyone knows the cause?
For example if i have the piece of code as follows:
CountryName = (char *)malloc((strlen(CountryName)+1)*sizeof(char));
memset(CountryName, 0, strlen(CountryName)+1);
CountryName = SOME VALUE
Now how do i free the memory after use of this code???? :confused: (3 Replies)
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)
Hi all,
Could please let me know how to get the more memory free space (not added the RAM) in local zone.
-bash-3.00# vmstat 2 5
kthr memory page disk faults cpu
r b w swap free re mf pi po fr de sr s0 s1 s1 s1 in sy cs us sy... (3 Replies)
hi, I have done the below, but am confused as to how much memory is "free"
please help
thanks
$ free
total used free shared buffers cached
Mem: 132033488 48827536 83205952 0 1007696 45404632
-/+ buffers/cache: 2415208 ... (7 Replies)
I was running a program and it stopped and showed "Out of Memory!". at that time, the RAM used by this process is around 4G and the free memory size of the machine is around 30G. Does anybody know what maybe the reason? this program is written with Perl. the OS of the machine is Solaris U8. And I... (1 Reply)
All,
AIX: 6.1 64 bits
How to find out Free memory available on AIX 6.1 64 bits
When I used :
svmon -G
size inuse free pin virtual mmode
memory 1048576 612109 191151 215969 549824 Ded-E
pg space 4325376 ... (1 Reply)
Hi,
I am wondering if there is a way to free up memory in Solaris manually ? the way we can do it in Linux for example :
echo `/bin/date` "************* Memory Info Before *************"
free -m
sync
echo 1 > /proc/sys/vm/drop_caches
echo 2 > /proc/sys/vm/drop_caches
echo 3 >... (13 Replies)
If I understand your question correctly, you are asking for an explanation of Solaris memory manager. You'd better ask Oracle that question because you are talking about Solaris kernel internals.
The operating system kernel has no reason to kick a process's memory set out of real memory until... (4 Replies)
Discussion started by: hicksd8
4 Replies
LEARN ABOUT OSX
libpthread
libpthread(3LIB) Interface Libraries libpthread(3LIB)NAME
libpthread - POSIX threads library
SYNOPSIS
cc -mt [ flag... ] file... -lpthread [ -lrt library... ]
DESCRIPTION
Historically, functions in this library provided POSIX threading support. See standards(5). This functionality now resides in libc(3LIB).
This library is maintained to provide backward compatibility for both runtime and compilation environments. The shared object is imple-
mented as a filter on libc.so.1. New application development needs to specify -lpthread only to obtain POSIX semantics for fork(2) that
assumes the behavior of fork1(2) rather than the default behavior that forks all threads.
INTERFACES
The shared object libpthread.so.1 provides the public interfaces defined below. See intro(3) for additional information on shared object
interfaces.
__pthread_cleanup_pop __pthread_cleanup_push
pthread_attr_destroy pthread_attr_getdetachstate
pthread_attr_getguardsize pthread_attr_getinheritsched
pthread_attr_getschedparam pthread_attr_getschedpolicy
pthread_attr_getscope pthread_attr_getstackaddr
pthread_attr_getstacksize pthread_attr_init
pthread_attr_setdetachstate pthread_attr_setguardsize
pthread_attr_setinheritsched pthread_attr_setschedparam
pthread_attr_setschedpolicy pthread_attr_setscope
pthread_attr_setstackaddr pthread_attr_setstacksize
pthread_cancel pthread_cond_broadcast
pthread_cond_destroy pthread_cond_init
pthread_cond_reltimedwait_np pthread_cond_signal
pthread_cond_timedwait pthread_cond_wait
pthread_condattr_destroy pthread_condattr_getpshared
pthread_condattr_init pthread_condattr_setpshared
pthread_create pthread_detach
pthread_equal pthread_exit
pthread_getconcurrency pthread_getschedparam
pthread_getspecific pthread_join
pthread_key_create pthread_key_delete
pthread_kill pthread_mutex_consistent_np
pthread_mutex_destroy pthread_mutex_getprioceiling
pthread_mutex_init pthread_mutex_lock
pthread_mutex_setprioceiling pthread_mutex_trylock
pthread_mutex_unlock pthread_mutexattr_destroy
pthread_mutexattr_getprioceiling pthread_mutexattr_getprotocol
pthread_mutexattr_getpshared pthread_mutexattr_getrobust_np
pthread_mutexattr_gettype pthread_mutexattr_init
pthread_mutexattr_setprioceiling pthread_mutexattr_setprotocol
pthread_mutexattr_setpshared pthread_mutexattr_setrobust_np
pthread_mutexattr_settype pthread_once
pthread_rwlock_destroy pthread_rwlock_init
pthread_rwlock_rdlock pthread_rwlock_tryrdlock
pthread_rwlock_trywrlock pthread_rwlock_unlock
pthread_rwlock_wrlock pthread_rwlockattr_destroy
pthread_rwlockattr_getpshared pthread_rwlockattr_init
pthread_rwlockattr_setpshared pthread_self
pthread_setcancelstate pthread_setcanceltype
pthread_setconcurrency pthread_setschedparam
pthread_setspecific pthread_sigmask
pthread_testcancel
FILES
/lib/libpthread.so.1 a filter on /lib/libc.so.1
/lib/64/libpthread.so.1 a filter on /lib/64/libc.so.1
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsl (32-bit) |
+-----------------------------+-----------------------------+
| |SUNWcslx (64-bit) |
+-----------------------------+-----------------------------+
|MT-Level |Safe |
+-----------------------------+-----------------------------+
SEE ALSO pvs(1), intro(2), intro(3), libc(3LIB), libc_db(3LIB), libthread(3LIB), attributes(5), standards(5), threads(5)SunOS 5.10 24 Mar 2004 libpthread(3LIB)