I have searched the forum for this - forgive me if I missed a previous post.
I have the following file:
blah blah blah
blah blah blah
blah blah blah
blah blah blah
blah blah blah
alter table "informix".esc_acct add constraint (foreign key (fi_id)
references "informix".fi ... (5 Replies)
I was just looking at this post: https://www.unix.com/shell-programming-scripting/22893-delete-multiple-empty-lines.html.
and I am looking to achieve the same with sed. So the idea is to delete lines from a file where a certain field has no value.
Inputfile:
EMID MMDDYY HOURS JOB EMNAME
0241... (4 Replies)
Can somebody explain why my sed command is not working.
I do the folloinwg:
Generates a binary file to /tmp/x1.out
/usr/lib/sa/sa2 -s 4:00 -e 8:00 -i 3600 -A -o /tmp/x1.out
decodes the file (no problem so far)
sar -f /tmp/x1.out
When I do this it does not appear to delete the... (4 Replies)
:confused:Hi All,
I need help on removing lines in a text file.
Sample file :
When there is a match ip for IPAddress in my `cat ip.out`, proceed delete line above until string "Comp" is found.
Thank you very much.
---------- Post updated at 12:56 AM ---------- Previous update was... (4 Replies)
Hi I have the following kind of line sin my file .
print ' this is first'.
print ' this is firs and next '
' line continuous '. -- this is entire print line.
print ' this is first and next '
' line continuous and'
'still there now over'. -- this 3lines together a single print line.
... (5 Replies)
Hi,
I am new to unix and i started some scripting recently. Please go through the following script i wrote.
#!/bin/sh
file='path../tfile'
file1='path../tfile1'
rmfile='path../test2'
C1=1
C2=1
exec 3< $file1
while read LINE1; do
read LINE2 <&3
a=$LINE1
b=`expr $LINE2 - 1`
... (1 Reply)
Team,
I am trying to use sed to delete 15 lines, after pattern patch, which includes the pattern as well in Solaris. I used the below command, as we do it Linux, but it's not working as expected in Solaris.
I am getting the error as "garbled".sed '/\/table/,+15d' status.html
sed: command... (8 Replies)
Hello,
My goal is the make all x times repeated lines into a single line.
I need to attain the expected output with sed -i , I need to overwrite the MyFile
MyFile:
Hello World
Welcome
Hello World
Welcome Back
This is my test
Expected output:
Hello World
Welcome
Welcome Back
This is... (6 Replies)
Discussion started by: baris35
6 Replies
LEARN ABOUT DEBIAN
mail::milter::module::connectmatcheshostname
Mail::Milter::Module::ConnectMatchesHostname(3pm) User Contributed Perl Documentation Mail::Milter::Module::ConnectMatchesHostname(3pm)NAME
Mail::Milter::Module::ConnectMatchesHostname - milter to accept/reject connecting hosts matching regex(es)
SYNOPSIS
use Mail::Milter::Module::ConnectMatchesHostname;
my $milter = new Mail::Milter::Module::ConnectMatchesHostname;
my $milter2 = &ConnectMatchesHostname; # convenience
$milter2->set_message('Connecting hostname %H looks like a dynamic address');
DESCRIPTION
This milter module rejects any connecting host whose hostname contains one of a group of built-in patterns that match the IP address of the
connecting host. This is normally used to detect dynamic pool addresses.
Currently the following patterns embedded in the hostname are considered matching, where 10.11.12.13 is the IPv4 address of the connecting
host. In the following cases, the string must be preceded by a non-digit character or otherwise must be at the start of the hostname.
010.011.012.013. (optionally without internal dots, or with - in place of .)
013.012.011.010. (optionally with - in place of .)
10.11.12.13. (optionally without internal dots, or with - in place of .)
13.12.11.10. (optionally with - in place of .)
0A0B0C0D (hexadecimal, ignoring case)
More specific patterns are anticipated to be added in the future. Because of this, if you use ConnectMatchesHostname, pay attention to
this perldoc manual page when updating to a newer version of Mail::Milter.
One final note. ISPs can and do use "dynamic-looking" reverse DNS entries for what they consider to be legitimate server addresses. This
is not ideal, and may require embedding this module in a Chain set to "accept_break" with regular expressions; for example:
my $milter = new Mail::Milter::Chain(
&ConnectRegex(
'.fooisp.com$',
)->accept_match(1);
&ConnectMatchesHostname,
)->accept_break(1);
METHODS
new()
Creates a ConnectMatchesHostname object.
set_message(MESSAGE)
Sets the message used when rejecting connections. This string may contain the substring %H, which will be replaced by the matching
hostname, and/or the substring %A, which will be replaced by the matching IP address.
This method returns a reference to the object itself, allowing this method call to be chained.
BUGS
In Sendmail 8.11 and 8.12, a milter rejection at "connect" stage does not allow the reply message to be set -- it simply becomes "not
accepting messages". However, this module still attempts to set the reply code and message in the hope that this will be fixed.
The implementation of this module could be much more efficient.
AUTHOR
Todd Vierling, <tv@duh.org> <tv@pobox.com>
SEE ALSO
Mail::Milter::Object
perl v5.8.8 2004-02-26 Mail::Milter::Module::ConnectMatchesHostname(3pm)