02-01-2007
I was told to run a cron job every 2 minutes and once it found the file I could have it transfer it. It seems like overkill to have a process running every 2 minutes looking for a file that may be added only once a day.
Thanks to all who answered
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
From within a directory, how do I determine whether I have write permission for it.
test -w pwd ; echo ?
This doesn't work as it returns false, even though I have write permission. (4 Replies)
Discussion started by: Sniper Pixie
4 Replies
2. UNIX for Advanced & Expert Users
Hi,
when I execute some simple commands on my solaris system, I am getting the following warning message:
Could anybody tell me what could be the reason
Ex:- If I give the command,
which ls
Warning: cannot determine current directory
... (15 Replies)
Discussion started by: axes
15 Replies
3. UNIX for Dummies Questions & Answers
I am uploading files that need to be processed prior to uploading. I will put the files in a directory. My question is how can I write an easy process to kick off a script once a file has been added? Is there an easy way to determine if a file has been added to a directory?
Thanks (1 Reply)
Discussion started by: goodmis
1 Replies
4. Shell Programming and Scripting
Hi there,
I wonder if it is possible the determine a name of a directory which is different on various hosts.
Let me try to explain.
I have the directory /tmp/dir1/dir2/canchangedir.
This directory name is different on various hosts.
I need to use the directory name, independent from the... (2 Replies)
Discussion started by: ejdv
2 Replies
5. Solaris
Hi,
When I include a user to the secondary group "sys" GID=3 in Solaris 9 OS I'm not able to login. I get these error. The user home directory and the shell exists. Is this because of any security hardening.
# su - agent
No directory!
# su agent
su: No shell
# grep taddm /etc/passwd... (14 Replies)
Discussion started by: agent001
14 Replies
6. Solaris
Currently have an issue were we use a script to load a security .dat key. The script was failing to load stating "Unable to open directory". I ssh'd into the server and performed an ls -la on the /cdrom directory. I show the usual cdrom0 but the directory on the cd should be key but is showing... (0 Replies)
Discussion started by: hypp1e
0 Replies
7. Shell Programming and Scripting
Hi All,
I'm just wondering how can i determined if there's a file in directory and put it in a logs?
dir="/home/test/"
Please advise,
Thanks,
Use code tags, thanks. (1 Reply)
Discussion started by: nikki1200
1 Replies
8. Shell Programming and Scripting
Possible filenames:
CDD_Whatever.txt
DDD_Whatever.txt
If the file prefix = CDD, I'd like to prefix every person ID (second column in my examples below) on the file with "c-"
If the file prefix = DDD, I'd like to prefix ever person ID with "d-"
Input:
Desired Output:
Any help... (2 Replies)
Discussion started by: lrluis
2 Replies
9. Shell Programming and Scripting
Hey everyone,
I need to select all files that were added to a specific directory in the past 5 mins and copy them over to a different directory. I am using HP-UX OS which does not have support for amin, cmin, and mmin. B/c of this, I am creating a temp file and will use the find -newer command... (7 Replies)
Discussion started by: mattkoz
7 Replies
10. Shell Programming and Scripting
Hello,
I am attempting to find and copy the two most recently added files to a specific directory, that fit a specific format.
I was able to find the command to list the two most recently added files in directory: ls -1t | head -n 2 The command lists the two files names in a vertical list,... (11 Replies)
Discussion started by: mattkoz
11 Replies
LEARN ABOUT CENTOS
thr_min_stack
thr_min_stack(3C) Standard C Library Functions thr_min_stack(3C)
NAME
thr_min_stack - return the minimum-allowable size for a thread's stack
SYNOPSIS
cc -mt [ flag... ] file...[ library... ]
#include <thread.h>
size_t thr_min_stack(void);
DESCRIPTION
When a thread is created with a user-supplied stack, the user must reserve enough space to run this thread. In a dynamically linked execu-
tion environment, it is very hard to know what the minimum stack requirments are for a thread. The function thr_min_stack() returns the
amount of space needed to execute a null thread. This is a thread that was created to execute a null procedure. A thread that does some-
thing useful should have a stack size that is thr_min_stack() + <some increment>.
Most users should not be creating threads with user-supplied stacks. This functionality was provided to support applications that wanted
complete control over their execution environment.
Typically, users should let the threads library manage stack allocation. The threads library provides default stacks which should meet the
requirements of any created thread.
thr_min_stack() will return the unsigned int THR_MIN_STACK, which is the minimum-allowable size for a thread's stack.
In this implementation the default size for a user-thread's stack is one mega-byte. If the second argument to thr_create(3C) is NULL, then
the default stack size for the newly-created thread will be used. Otherwise, you may specify a stack-size that is at least THR_MIN_STACK,
yet less than the size of your machine's virtual memory.
It is recommended that the default stack size be used.
To determine the smallest-allowable size for a thread's stack, execute the following:
/* cc thisfile.c -lthread */
#define _REENTRANT
#include <thread.h>
#include <stdio.h>
main() {
printf("thr_min_stack() returns %u
",thr_min_stack());
}
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|MT-Level |MT-Safe |
+-----------------------------+-----------------------------+
SEE ALSO
attributes(5), standards(5)
SunOS 5.10 12 May 1998 thr_min_stack(3C)