[SOLVED] Impossible to send message: Bad file descriptor

Moderator: crythias

Post Reply
HervE
OTRS wizard
Posts: 391
Joined: 03 Jan 2011, 17:15
OTRS Version?: 3.3.8
Location: France

[SOLVED] Impossible to send message: Bad file descriptor

Post by HervE »

Hello forum,

Replying to a mail in a ticket, I got the following error:
Backend ERROR: OTRS-CGI-10 Perl: 5.16.3 OS: MSWin32 Time: Tue Nov 25 18:01:18 2014 Message: Impossible to send message to: whoever@whereever.com . RemoteAddress: XX.XX.XX.XX RequestURI: /otrs/index.pl Traceback (4360): Module: Kernel::System::Ticket::Article::ArticleSend (OTRS 3.3.8 ) Line: 2083 Module: Kernel::Modules::AgentTicketCompose::Run (OTRS 3.3.8 ) Line: 784 Module: Kernel::System::Web::InterfaceAgent::Run (OTRS 3.3.8 ) Line: 871 Module: PerlEx::Precompiler::d_::otrs::otrs::bin::cgi2dbin::index_pl::__ANON__ (unknown version) Line: 41 Module: (eval) (unknown version) Line: 458 Module: PerlEx::Precompiler::Execute (unknown version) Line: 458

The logfile looks like this:
[Tue Nov 25 18:01:18 2014][Error][Kernel::System::Email::SMTP::Send][109] Can't connect to smtp.mycompany.com: Bad file descriptor!
[Tue Nov 25 18:01:18 2014][Info][Kernel::System::Email::Send] Error sending message
[Tue Nov 25 18:01:18 2014][Error][Kernel::System::Ticket::Article::ArticleSend][2083] Impossible to send message to: whoever@whereever.com .

And here is an extract of SysConfig export:
delete $Self->{'SendmailBcc'};
$Self->{'SendmailModule::Port'} = '25';
$Self->{'SendmailModule::Host'} = 'smtp.mycompany.com';
$Self->{'SendmailModule'} = 'Kernel::System::Email::SMTP';

Any idea?
I went through the web but couldn't find something that could solve the problem.

Regards,
HervE
Last edited by HervE on 09 Dec 2014, 11:26, edited 1 time in total.
OTRS 3.3.8 - Windows 7 - IIS7 - SQL Server - Firefox 30

crythias
Moderator
Posts: 10126
Joined: 04 May 2010, 18:38
OTRS Version?: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Impossible to send message: Bad file descriptor

Post by crythias »

Bad file descriptor in email is possibly attempting to mismatch plain SMTP with an SMTP server that requires encryption or authentication.
OTRS 5.0.x (private/testing/public) on Linux with MySQL database. Also on github.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask

HervE
OTRS wizard
Posts: 391
Joined: 03 Jan 2011, 17:15
OTRS Version?: 3.3.8
Location: France

Re: Impossible to send message: Bad file descriptor

Post by HervE »

Thank you for your answer but this wasn't the solution.

I had a look into SMTP.pm, and noticed that $Self->{'FQDN'} was used for some reason.
We corrected the value of FQDN in SysConfig and it looks fine now.

Only one drawback: The direct URL at the end of notifications doesn't work now. So I had to add the port (8080, which is the port used for our OTRS site) just after the FQDN variable.
I.e. <OTRS_CONFIG_HttpType>://<OTRS_CONFIG_FQDN>:8080/<OTRS_CONFIG_ScriptAlias>index.pl?Action=AgentTicketZoom;TicketID=<OTRS_TICKET_TicketID>
I know this is dirty, but it works.
Is there a variable containing the port?

Regards,
HervE
OTRS 3.3.8 - Windows 7 - IIS7 - SQL Server - Firefox 30

Post Reply