05-13-2008
**************Thread Closed *****************************
8 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I want to search the file /etc/passwd for all lines containing 'csh' but exlude all those lines that have '/usr' in them and dump the results into the file result.
IMPORTANT: I need to do this in one command line.
The following does not work:
grep -v \(\/usr\) \(csh\) /etc/passwd >... (4 Replies)
Discussion started by: sdemba
4 Replies
2. News, Links, Events and Announcements
See this article:
http://story.news.yahoo.com/news?tmpl=story&cid=74&ncid=738&e=9&u=/cmp/20030809/tc_cmp/13000487 (3 Replies)
Discussion started by: Neo
3 Replies
3. Shell Programming and Scripting
I am aware that Perl has a lot of features that originally came from sed and awk. I have a pattern that I am using like this:
sed -n '/|Y|/p'
I want to do the same thing in Perl and be able to either save that value in some kind of variable or array or potentially write it out to a file.
... (11 Replies)
Discussion started by: masinick
11 Replies
4. UNIX and Linux Applications
I just configured my ldap server in Alpine, but every search hangs indefinitely (or so it seems) and I have to end up killing Alpine and starting back up. The LDAP server runs over SSL on port 636, so I have specified port 636, but there doesn't seem to be an SSL option available so I turned on... (0 Replies)
Discussion started by: retrovertigo
0 Replies
5. Shell Programming and Scripting
Here is my code. What it does is it reads an input file (input.txt which contains roughly 2,000 search phrases) and searches a directory for files that contains the search phrase. The directory contains roughly 1900 files and 84 subdirectories. The output is a file (output.txt) that shows only the... (23 Replies)
Discussion started by: jl487
23 Replies
6. Shell Programming and Scripting
I have a below file
RCS File name : abc.txt
something
something
....
symbolic names:
implemented : 1.1
ssssssumthing
Revision 1.2
date : 12/12/12 author : abc
Revision 1.1
date : 11/11/11 author xyz
So now , in this file i have to first look for the implemented... (1 Reply)
Discussion started by: ashishagg2005
1 Replies
7. UNIX for Dummies Questions & Answers
I have a file that looks like this:
>Sample 539
GCCCAGCGCGCGILTGCCGCCGTCTCCGCCTGTCJOHNCCGCCATTGCCCCCGGTTAC
I am using the following code to search specific patterns:
awk '/^>/ { print $0 } NR==2 {if (/GIL/) { print "\t" "1" } else { print "\t" "0" }} NR==2 {if (/JOHN/) { print "\t""\t"... (7 Replies)
Discussion started by: Xterra
7 Replies
8. Shell Programming and Scripting
I tried to ease text searches so made a customized grep:
g () {
if
then
i=
for s in $2
do
i="$i --include=*.$s"
done
else
i='--include=*.txt --include=*.ini --include=*.*sh --include=*.c* --include=*.h --include=*.js --include=*.reg'
fi
grep -P -e \'$1\' -r "$i"
}
but I... (3 Replies)
Discussion started by: abdulbadii
3 Replies
LEARN ABOUT DEBIAN
p_candebug
P_CANDEBUG(9) BSD Kernel Developer's Manual P_CANDEBUG(9)
NAME
p_candebug -- determine debuggability of a process
SYNOPSIS
#include <sys/param.h>
#include <sys/proc.h>
int
p_candebug(struct thread *td, struct proc *p);
DESCRIPTION
This function can be used to determine if a given process p is debuggable by the thread td.
SYSCTL VARIABLES
The following sysctl(8) variables directly influence the behaviour of p_candebug():
kern.securelevel
Debugging of the init process is not allowed if this variable is 1 or greater.
security.bsd.unprivileged_proc_debug
Must be set to a non-zero value to allow unprivileged processes access to the kernel's debug facilities.
RETURN VALUES
The p_candebug() function returns 0 if the process denoted by p is debuggable by thread td, or a non-zero error return value otherwise.
ERRORS
[EACCESS] The MAC subsystem denied debuggability.
[EAGAIN] Process p is in the process of being exec()'ed.
[EPERM] Thread td lacks super-user credentials and process p is executing a set-user-ID or set-group-ID executable.
[EPERM] Thread td lacks super-user credentials and process p's group set is not a subset of td's effective group set.
[EPERM] Thread td lacks super-user credentials and process p's user IDs do not match thread td's effective user ID.
[EPERM] Process p denotes the initial process initproc() and the sysctl(8) variable kern.securelevel is greater than zero.
[ESRCH] Process p is not visible to thread td as determined by cr_seeotheruids(9) or cr_seeothergids(9).
[ESRCH] Thread td has been jailed and process p does not belong to the same jail as td.
[ESRCH] The MAC subsystem denied debuggability.
SEE ALSO
jail(2), sysctl(8), cr_seeothergids(9), cr_seeotheruids(9), mac(9), p_cansee(9), prison_check(9)
BSD
November 19, 2006 BSD