02-19-2002
bad file descriptor?
Ok, I'm sure this is a total newbie question, but I think I'm in the right place, no?
I'm trying to call a perl module from a cgi script - Mail::Sendmail - and my web host installed the module in a directory that doesn't seem to be accessible, at least not the way I'm trying. But I thought you could call a module just about anywhere as long as you include a 'use lib' statement so perl can find it...
Anyway, I guess my question is this: does 'bad file descriptor' indicate that a file pathname I've written is bunk? That basically the pathname is not correct?
Thanks in advance for any light shed for a Unix rookie...
Chris
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
What is a file descriptor in Unix??
How to find a file descriptor of a file in Unix??
Does it have anything to do with the Inode numbers?? (3 Replies)
Discussion started by: rahulrathod
3 Replies
2. UNIX for Advanced & Expert Users
I need to write a script that can find a bad record (for example: there is date field colom but value provided in the file for this field is N/A) then script shoud searches this pattern and then insert the whole record into the bad file.
Example:
File1
Name designation dateOfJoining... (1 Reply)
Discussion started by: shilendrajadon
1 Replies
3. Shell Programming and Scripting
I need to write a script that can find a bad record (for example: there is date field colom but value provided in the file for this field is N/A) then script shoud searches this pattern and then insert the whole record into the bad file.
Example:
File1
Name designation dateOfJoining... (2 Replies)
Discussion started by: shilendrajadon
2 Replies
4. Shell Programming and Scripting
Hello All,
Im opening a file desciptor in perl and sending data using print CMD "$xyz".
is there a limit to the length of the string that I can give to this CMD at a time. (3 Replies)
Discussion started by: rimser9
3 Replies
5. UNIX for Dummies Questions & Answers
Hi
What the below path contains?
/proc/<pid>/fd (1 Reply)
Discussion started by: siba.s.nayak
1 Replies
6. Programming
Hi All,
First of all thanks for reading this post.
In my application, I am trying to create a new message queue . I am attaching the code below.
mqd_t mqopen2(const char * pName,
unsigned long Flags,
long maxMsg,
long msgSz)
{... (15 Replies)
Discussion started by: parusasi
15 Replies
7. Ubuntu
Hi All
I have a dedicated backup server running ubuntu 10.04, which has recently been rebuilt (same OS, just different h/w)
This is used to receive ufsdump output from a number of Solaris servers, using the following syntax:
ufsdump 1uf :/path/to/backup/file /fs/to/be/backed/up
This has... (1 Reply)
Discussion started by: in2deep
1 Replies
8. Shell Programming and Scripting
grt=`sort -nr line_count.txt|head -1`
while read $dline
do
if $grt" -eq "`wc -l combo_operncount.$dline|awk '{print $1}'`" ]
then
awk -F, '{print $1}' combo_operncount.$dline > FULLD7
else
echo combo_operncount.$dline >> filecoll.txt
fname=`cat filecoll.txt|tr -s "\n" " "`
echo $fname... (6 Replies)
Discussion started by: nikhil jain
6 Replies
9. Solaris
Hi ,
One of my zone went down and when i booted it up i could see the pool in degraded state with some check sum errors . we have brought the pool online after scrubbing. But few files are showing this error
Bad exchange descriptor
Please let me know how to remove these files (2 Replies)
Discussion started by: chidori
2 Replies
10. UNIX for Beginners Questions & Answers
I'm learning SED command. And while doing that i got to this place where i'm taking a copy of my existing file. The code i used is -
sed -n '/Storm/ w Storm.txt' books.txt
As expected, the file 'books.txt' is read , and lines with 'Storm' is put in to the new file 'Storm.txt'. However, it also... (4 Replies)
Discussion started by: justo
4 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)