Hi everybody:
I try to print in new file selected lines from another file wich depends on the first column.
I have done a script like this:
lines=( "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "21" "31" "41" "51" "55" "57" "58" )
${lines}
for lines in ${lines}
do
awk -v ... (6 Replies)
Hi,
I am looking to copy selected lines from a file using the vim editor. I have looked up a few resources and they have suggested to use this-
Type mk
Type: "ay'k (double quotes, <register name from a-z>, <y-yank single quote, k
You can paste those lines wherever you want with "ap
I tried... (7 Replies)
I have an if statement where I state that if there are more than one records (lines) found containing a string in a file, then it enters into a while loop to use each line for as many lines as there are and then stop.
Trouble is, I can't figure out how to move to the next instance of each line. ... (2 Replies)
I am trying to print 1st, 2nd, 13th and 14th fields of a file of line numbers from 29 to 10029. I dont know how to put this in one code. Currently I am removing the selected lines by
awk 'NR==29,NR==10029' File1 > File2
and then doing
awk '{print $1, $2, $13, $14}' File2 > File3
Can... (3 Replies)
Hello,
I have a file, which looks like:
I want to print the row containg "PRO" in second column after comparing and finding the minimum value of fifth column present in all "PRO". and likewise for every other string present in second column.
I am using :
filename=list... (2 Replies)
Hi, I have text file:
Name: xyz
Gender: M
Address: "120_B_C; ksilskdj; lsudlfw"
Zip: 20392
Name: KLM
Gender: F
Address: "65_D_F; wnmlsi;lsuod;,...."
Zip:90233I want to insert 2 new lines before the 'Address: ' line deriving value from this Address line value
The Address value in quotes... (1 Reply)
Hello,
I have two files file 1 and file 2 each having result of a query on certain database tables and need to compare for Col1 in file1 with Col3 in file2, compare Col2 with Col4 and output the value of Col1 from File1 which is a) not present in Col3 of File2 b) value of Col2 is different from... (2 Replies)
hi Gurus,
I have a source file with more than 10 columns ( not fixed )
I want to delete all the lines on the following condition
1) where i have first column as "UPDATE PLAN ADD RATE SCHEDULE" and fourth column as null
awk '($1=="UPDATE PLAN ADD RATE SCHEDULE" && $4=="") {print $0}'... (5 Replies)
Hi Guys ,
I have two files say a1 and a2 having following contents
a1
dag
wfd
a2
dag
wfd
chire
hcm
I want to delete only the lines in a2 which are in a1 and final output of a2 should be
a2
chire
hcm (6 Replies)
In the below portion of a bash script the user selects a file from a directory.
select file in $(cd /home/cmccabe/Desktop/NGS/API/5-14-2016/bedtools;ls);do break;done
files in directory
123_base_counts.txt
456_base_counts.txt
789_base_counts.txt
second portion of bash currently (user... (4 Replies)
Discussion started by: cmccabe
4 Replies
LEARN ABOUT DEBIAN
snntpd
snntpd,v0.3.8(8) System Manager's Manual snntpd,v0.3.8(8)NAME
snntpd - small news server
SYNOPSIS
snntpd [-t timeout] [-P] [-S] [logger...]
DESCRIPTION
snntpd is a small news server. It needs to be run under inetd or tcpserver, as root or as the owner of /var/spool/sn. snntpd does not
fork into the background. It expects to read and write from and to the network on descriptors 0 and 1.
ARGUMENTS
logger... (usually /usr/bin/logger) is taken to be a logging program, and all log output is piped to it. If logger... is not specified,
log messages are directed to descriptor 2.
OPTIONS -t timeout
specifies how long snntpd should wait for input before it gives up and exits. timeout is in seconds and defaults to 600.
-P snntpd includes it's pid in log output.
-S Suppress NNTP greeting on startup. This is useful if you want to perform authentication before running snntpd, or want to provide
your own greeting, from a wrapper.
POSTING AND POSTING PERMISSIONS
Posts are usually handled externally by the /usr/sbin/SNPOST script, which is responsible for fine-grain posting control; handling of con-
trol messages; and the ultimate distribution of the posted article.
snntpd permits or denies posting in a very simple manner:
If /var/spool/sn/.nopost exists, posting is not allowed.
Otherwise, if the environment variable POSTING_OK is not set, posting is not allowed.
Otherwise if POSTING_OK is set (to the empty string), posting is generally allowed, and all POSTed articles are piped to the SNPOST script,
which has the final say in the matter. The value of $POSTING_OK is not currently used, but is reserved.
FILES
/var/spool/sn/.fifo
If this file exists, and is a fifo, snntpd will write the name of a newsgroup into it as that newsgroup becomes the current one. If
the fifo does not exist snntpd will not create it.
/var/spool/sn/.noservice
If this file exists, snntpd will display its first line and exit. If the file can't be read or is empty, a default message is dis-
played. This is useful for temporarily disabling the news server while you perform any maintenance.
/var/spool/sn/.nopost
See POSTING PERMISSIONS above.
/var/spool/sn/.SNPOST
If this script or program exists, it is invoked instead of SNPOST to accept a posted article.
/var/spool/sn/news.group.name/.nopost
These files really belong to SNPOST, and it is unfortunate that snntpd has to check for their existence to determine the posting
flag for the LIST command. See /usr/sbin/SNPOST.
/var/spool/sn/news.group.name/.info
If this file exists, its first line is taken as the description of that group for use with the LIST NEWSGROUPS command.
/var/spool/sn/news.group.name/.times
is a binary file containing entry times, to support the NEWNEWS command.
/var/spool/sn/news.group.name/.created
is an empty file retained for it's timestamp, to support the NEWGROUPS command.
SIGNALS
If snntpd catches SIGHUP, the files /var/spool/sn/{.fifo,.noservice,.nopost} (see below) are checked again, as they are during startup.
Other signals have default behaviour.
ENVIRONMENT VARIABLES
See also /usr/sbin/SNPOST for a list of environment variables exported by snntpd.
PATH The PATH must be set such that snntpd can find SNPOST in order to accept postings. If PATH does not include /usr/sbin, /usr/sbin
will be appended to it.
POSTING_OK
This variable helps determine the site-wide posting policy. See POSTING PERMISSIONS above.
TCPREMOTEIP
If this value is set, it is taken to be the dotted-quad IP address of the connecting client. If it is not set, snntpd attempts to
derive it for itself, and then set its value.
TCPLOCALIP
as above, but for the server's dotted-quad IP.
SNROOT If this is set and is not empty, the value is used everywhere in place of /var/spool/sn, the default news spool directory.
SEE ALSO snsend(8), /usr/sbin/SNPOST
N.B. Harold Tay snntpd,v0.3.8(8)