02-15-2006
Open file descriptors should, by default, remain open. They will be closed only if the FD_CLOEXEC flag was set, which is generally rare. Having file descriptors open across an exec() is how the shell implements stuff like:
program < inputfile > outputfile
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
With so many diffrent flavors out there, how is a person soposed to know what to go with? I'm not asking for specific discussion here in this forum, but I would like to see various pages and articles dicsussing the pluses and minuses of various unix/linux OS's. I have been searching various... (1 Reply)
Discussion started by: MorderKartoffel
1 Replies
2. UNIX for Advanced & Expert Users
Hi guys,
We have different IP ranges in our LAN, for instance my system IP Add. is in 163.183.37.x range, in the meantime i wish to connect to our printer/plotter which is 163.183.4.x & our LAN in another location with 163.183.38.x.
What shoul i do except defining pesudo IP Add's? as a... (1 Reply)
Discussion started by: nikk
1 Replies
3. UNIX for Dummies Questions & Answers
Can sed be used to take a existing record and reverse the order of defined character placement if there is no delimeters?
existing record:
0123456789CO
expected result:
9876543210CO
if there were delimeters I could define the delimeter and each placement would have an id which I... (1 Reply)
Discussion started by: r1500
1 Replies
4. Shell Programming and Scripting
When I type a command at the command line it supplies one result and the exact same command in a script
egrep '^01|^02|^03|^04' file > fileout
count = 29353
same count in the script yields a count of 23492
is there any reason this could be happening. (1 Reply)
Discussion started by: r1500
1 Replies
5. Shell Programming and Scripting
i have serverA and serverB and i have a folder with same name an location in both servers.... Now i want to compare files in folder(serverA) with folder (serverB) if there are files missing in folderB then copy those files from folder(serverA) to folder(serverB) (1 Reply)
Discussion started by: ashahzad
1 Replies
6. Red Hat
Hi
im trying to configure samba on linux server so win client can access the shared files but my win client is on diffrent domain , we recently changed our domain name but not for certain servers...
i guess the samba linux server is still part of our sub domain which is why i still can access... (4 Replies)
Discussion started by: halacil
4 Replies
7. Solaris
Hi,
I have issue with cron.
When i run script manually output is fine but when i add it to cron output file is not as same.
both file attach some junk charecter comming in cron output.
thanx
Jignesh (5 Replies)
Discussion started by: jkmistry
5 Replies
8. Shell Programming and Scripting
I couldn't find the answer anywhere, so I hope you could help me.
I need to change something like the following:
something/bla/aaaa
anything/bbb
to:
something
--bla
----aaaa
anything
--bbb
How do I do this?
Is it possible with sed?
I tried various patterns, but don't know how to... (5 Replies)
Discussion started by: Patwan
5 Replies
9. Shell Programming and Scripting
Heyas
I'm currently attempting to apply the code of tui-select to tui-list.
That is because tui-list simply made a 1 string list, while tui-select uses dynamicly up to 3 strings per line.
Anyway, so i copy pasted the code, and just made the changes marked with red....
Know that both scripts... (2 Replies)
Discussion started by: sea
2 Replies
10. UNIX for Beginners Questions & Answers
hi,
would you help me?
i have file total.csv
"a","e23","f"
"b,"34d","g"
"c","45f","f"
"d","45s","f"
count.csv
3
i do this :
paste -d',",' total.csv count.csv
but the result like this:
"a,"e23","f" 3
"b,"34d","g" (1 Reply)
Discussion started by: kivale
1 Replies
LEARN ABOUT OPENSOLARIS
getpgrp
getpid(2) System Calls getpid(2)
NAME
getpid, getpgrp, getppid, getpgid - get process, process group, and parent process IDs
SYNOPSIS
#include <unistd.h>
pid_t getpid(void);
pid_t getpgrp(void);
pid_t getppid(void);
pid_t getpgid(pid_t pid);
DESCRIPTION
The getpid() function returns the process ID of the calling process.
The getpgrp() function returns the process group ID of the calling process.
The getppid() function returns the parent process ID of the calling process.
The getpgid() function returns the process group ID of the process whose process ID is equal to pid, or the process group ID of the calling
process, if pid is equal to 0.
RETURN VALUES
The getpid(), getpgrp(), and getppid() functions are always successful and no return value is reserved to indicate an error.
Upon successful completion, getpgid() returns the process group ID. Otherwise, getpgid() returns (pid_t)-1 and sets errno to indicate the
error.
ERRORS
The getpgid() function will fail if:
EPERM The process whose process ID is equal to pid is not in the same session as the calling process, and the implementation does not
allow access to the process group ID of that process from the calling process.
ESRCH There is no process with a process ID equal to pid.
The getpgid() function may fail if:
EINVAL The value of the pid argument is invalid.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Committed |
+-----------------------------+-----------------------------+
|MT-Level |Async-Signal-Safe |
+-----------------------------+-----------------------------+
|Standard |See standards(5). |
+-----------------------------+-----------------------------+
SEE ALSO
Intro(2), exec(2), fork(2), getsid(2), setpgid(2), setpgrp(2), setsid(2), signal(3C), attributes(5), standards(5)
SunOS 5.11 27 Jan 2009 getpid(2)