12-01-2012
Can you please give us more information on what kind of error are you observing while function calling?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have a log file with contents like
81.49.74.131 - -
81.49.74.131 - -
116.112.52.31 - -
116.112.52.31 - -
I need an output like this
81.49.74.131 14/Sep/2008 Time duration: 00:06:00
116.112.52.31 15/Sep/2008 Time duration: 00:00:01
Please anyone suggest a script for this.... (1 Reply)
Discussion started by: FuncMx
1 Replies
2. UNIX for Dummies Questions & Answers
Morning all
Im hoping you can help me. We have a nice new oracle server :( and are needing to move some files around for EDI and BACS. The server runs windows but has an app called MKS toolkit installed which give unix commands. (Needed for the oracle stuff) I have had a go using dos commands... (2 Replies)
Discussion started by: ltodd2
2 Replies
3. Shell Programming and Scripting
Hi guys,
I know that this topic has been discuss numerous times, and I have search the net and this forum for it.
However, non able to address the problem I faced so far.
I am on Solaris Platform and unable to install additional packages like the GNU date and gawk to make use of their... (5 Replies)
Discussion started by: DrivesMeCrazy
5 Replies
4. UNIX for Dummies Questions & Answers
I need to edit the file name with date and time while writing the script.
please help. (1 Reply)
Discussion started by: manish.s
1 Replies
5. Shell Programming and Scripting
Hi All,
i wanted to add date and time to the file names in the same directory so lets say a file in the directory is test.txt then after running the shell script it should be test-15-11-2010.txt.
So I used the following script which works,
#!/bin/bash
thetime=`date +%Y-%m-%d--%H:%M:%S`... (7 Replies)
Discussion started by: cc_at_work
7 Replies
6. UNIX for Dummies Questions & Answers
I'd like to convert a date string in the form of sun aug 19 09:03:10 EDT 2012, to unixtime timestamp using awk.
I tried
This is how each line of the file looks like, different date and time in this format
Sun Aug 19 08:33:45 EDT 2012, user1(108.6.217.236) all: test on the 17th
... (2 Replies)
Discussion started by: bkkid
2 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I want to add some hours and minutes to the current date. For example, if the current date is "July 16, 2012 15:20", i want to add 5 hours 30 minutes to "July 16, 2012 00:00" not to "July 16, 2012 15:20". Please help.
Thanks! (4 Replies)
Discussion started by: manojgarg
4 Replies
8. Solaris
I have a cluster of two Solaris server (veritas cluster). one working and the other is standby
I am going to change the date on them , and am looking for a secure solution as it is giving an important service.
my opinion is that the active one doesn't need to be restarted (if I don't change the... (1 Reply)
Discussion started by: barry1946
1 Replies
9. Shell Programming and Scripting
Hello All,
I have a Perl script I'm writing where I ask the user to enter a "start time" for something. The "$start_time" will be in the format of:
# The Time CLI Option Can be in the format of:
--start-time="1day"
--start-time="2hours"
--start-time="45min"
... (1 Reply)
Discussion started by: mrm5102
1 Replies
10. Shell Programming and Scripting
There are 2 dates,
Tue Oct 1 13:40:19 2013
Sun Sept 30 10:26:23 2013
I have multiple dates like the above one. How do I calculate the date time difference and display in another column in Shell script. Please help. (3 Replies)
Discussion started by: tanmoysays
3 Replies
LEARN ABOUT REDHAT
pthread_mutexattr_settype
PTHREAD_MUTEXATTR(3) Library Functions Manual PTHREAD_MUTEXATTR(3)
NAME
pthread_mutexattr_init, pthread_mutexattr_destroy, pthread_mutexattr_settype, pthread_mutexattr_gettype - mutex creation attributes
SYNOPSIS
#include <pthread.h>
int pthread_mutexattr_init(pthread_mutexattr_t *attr);
int pthread_mutexattr_destroy(pthread_mutexattr_t *attr);
int pthread_mutexattr_settype(pthread_mutexattr_t *attr, int kind);
int pthread_mutexattr_gettype(const pthread_mutexattr_t *attr, int *kind);
DESCRIPTION
Mutex attributes can be specified at mutex creation time, by passing a mutex attribute object as second argument to pthread_mutex_init(3).
Passing NULL is equivalent to passing a mutex attribute object with all attributes set to their default values.
pthread_mutexattr_init initializes the mutex attribute object attr and fills it with default values for the attributes.
pthread_mutexattr_destroy destroys a mutex attribute object, which must not be reused until it is reinitialized. pthread_mutexattr_destroy
does nothing in the LinuxThreads implementation.
LinuxThreads supports only one mutex attribute: the mutex kind, which is either PTHREAD_MUTEX_FAST_NP for ``fast'' mutexes,
PTHREAD_MUTEX_RECURSIVE_NP for ``recursive'' mutexes, or PTHREAD_MUTEX_ERRORCHECK_NP for ``error checking'' mutexes. As the NP suffix
indicates, this is a non-portable extension to the POSIX standard and should not be employed in portable programs.
The mutex kind determines what happens if a thread attempts to lock a mutex it already owns with pthread_mutex_lock(3). If the mutex is of
the ``fast'' kind, pthread_mutex_lock(3) simply suspends the calling thread forever. If the mutex is of the ``error checking'' kind,
pthread_mutex_lock(3) returns immediately with the error code EDEADLK. If the mutex is of the ``recursive'' kind, the call to
pthread_mutex_lock(3) returns immediately with a success return code. The number of times the thread owning the mutex has locked it is
recorded in the mutex. The owning thread must call pthread_mutex_unlock(3) the same number of times before the mutex returns to the
unlocked state.
The default mutex kind is ``fast'', that is, PTHREAD_MUTEX_FAST_NP.
pthread_mutexattr_settype sets the mutex kind attribute in attr to the value specified by kind.
pthread_mutexattr_gettype retrieves the current value of the mutex kind attribute in attr and stores it in the location pointed to by kind.
RETURN VALUE
pthread_mutexattr_init, pthread_mutexattr_destroy and pthread_mutexattr_gettype always return 0.
pthread_mutexattr_settype returns 0 on success and a non-zero error code on error.
ERRORS
On error, pthread_mutexattr_settype returns the following error code:
EINVAL kind is neither PTHREAD_MUTEX_FAST_NP nor PTHREAD_MUTEX_RECURSIVE_NP nor PTHREAD_MUTEX_ERRORCHECK_NP
AUTHOR
Xavier Leroy <Xavier.Leroy@inria.fr>
SEE ALSO
pthread_mutex_init(3), pthread_mutex_lock(3), pthread_mutex_unlock(3).
LinuxThreads PTHREAD_MUTEXATTR(3)