02-14-2006
10 More Discussions You Might Find Interesting
1. Programming
ok, im somewhat of an advanced programmer for the windows-side of C/C++, and the system command to pause the console is 'system("pause");'.... i just recently transfered over to Slackware 3.3 (yes, its old, but i <3 text), and pause is not the command for pausing the command line. is there any... (3 Replies)
Discussion started by: 01000101
3 Replies
2. UNIX for Dummies Questions & Answers
I need a user pause for a script file, like the pause command in dos. please help I thought it was the corn shell it is csh. (7 Replies)
Discussion started by: dennysavard
7 Replies
3. Shell Programming and Scripting
Hello,
I am writing a shell script to search an active log file. If an "error" or "aborted" found, echo an acknowledgment message and wait until the user presses ENTER key.
tail -f log.file |nawk '
{print $0}
$0 ~ /error/ {
print "Error found. Press ENTER to acknowledge."
getline i < "-"... (3 Replies)
Discussion started by: gxdanh
3 Replies
4. UNIX for Dummies Questions & Answers
well is gets stuck and i dont know why.......
pid=fork();
if(pid==0)
{
pause();
write(1,"child",5);
exit(0);
}
else
{
sleep(1);
kill(pid,SIGCONT);
write(1,"parent",5);
wait(0);
}
all=1; (1 Reply)
Discussion started by: IdleProc
1 Replies
5. Shell Programming and Scripting
Alright, I have this script that pulls files from a few locations, process those files, creates a zip file, rsync's it and then removes everything.
The problem that I'm having is that I do not know how large the rsync'ed zip file is going to be. Right now I'm using a sleep command before I... (4 Replies)
Discussion started by: droppedonjapan
4 Replies
6. AIX
Hi,
I am building a script to grep for a string in all the files from a folder and display the results.
I am reading the files one by one by placing the names in other file using while loop
my code is as below
while read inp
do
chk=`grep -c "$str" $pth/$inp`
... (2 Replies)
Discussion started by: sekhar gajjala
2 Replies
7. Shell Programming and Scripting
Hi,
I've written a shell script to take photos with my camera.
After every picture taken, the picture is transmitted to the computer via usb and then deleted on the camera.
But sometimes there's an error and the picture is not deleted and so, after a certain time, the camera chip will be... (4 Replies)
Discussion started by: McLennon
4 Replies
8. UNIX for Dummies Questions & Answers
Possibly a dumb question, but I'm deciding how I'm going to do this. I'm currently rsyncing a 25TB directory (with several layers of sub directories most of which have video files ranging from 500 megs to 4-5 gigs), from one NAS to another using rsync -av. By the time I need to act ~15TB should... (3 Replies)
Discussion started by: DeCoTwc
3 Replies
9. Shell Programming and Scripting
Hi ALL,
Is there any way to pause a running process under nohup ?
I have fired a build commands with required flags under nohup as below. now how can
I pause the started build process.
nohup make DEVICE=ap DEBUG=1 &
I understand we can use ctrl + z to pause a foreground process... (3 Replies)
Discussion started by: useless79
3 Replies
10. Shell Programming and Scripting
6) printf "\n GoodBye! \n\n"; exit ;;
I am trying modify the above command to pause a couple of seconds before exiting, so a message can be displayed. Thank you :). (8 Replies)
Discussion started by: cmccabe
8 Replies
LEARN ABOUT NETBSD
pthread_getname_np
PTHREAD_GETNAME_NP(3) BSD Library Functions Manual PTHREAD_GETNAME_NP(3)
NAME
pthread_getname_np -- get and set descriptive name of a thread
LIBRARY
POSIX Threads Library (libpthread, -lpthread)
SYNOPSIS
#include <pthread.h>
int
pthread_getname_np(pthread_t thread, char *name, size_t len);
int
pthread_setname_np(pthread_t thread, const char *name, void *arg);
DESCRIPTION
The pthread_getname_np() function obtains the descriptive name of a thread. It takes the following arguments:
thread The thread whose descriptive name will be obtained.
name The buffer to be filled with the descriptive name of the thread.
len The size of the buffer name in bytes.
The pthread_setname_np() function sets the descriptive name of a thread. It takes the following arguments:
thread The thread whose descriptive name will be set.
name The printf(3) format string to be used to construct the descriptive name of the thread. The resulted descriptive name should
be shorter than PTHREAD_MAX_NAMELEN_NP.
arg The printf(3) argument used with name.
RETURN VALUES
Both functions return 0 on success. Otherwise, an error number is returned to indicate the error.
COMPATIBILITY
Both functions are non-standard extensions.
ERRORS
Both functions may fail if:
[EINVAL] Invalid parameter.
[ESRCH] Non-existent thread.
The pthread_setname_np() function may also fail if:
[ENOMEM] There was insufficient memory for the operation.
SEE ALSO
pthread_attr_get_np(3), pthread_attr_getname_np(3)
BSD
July 9, 2010 BSD