Simple Invoices logo
    • CommentAuthordcwd
    • CommentTimeSep 23rd 2007 edited
     permalink
    I've tried emailing an invoice and was given this error:

    Warning: fsockopen() [function.fsockopen]: unable to connect to localhost:25 in /home/domain/public_html/accounting/modules/include/mail/class.smtp.php on line 105
    Message could not be sent.

    Mailer Error: Language string failed to load: connect_host



    Please help!
    • CommentAuthorjustin
    • CommentTimeSep 24th 2007 edited
     permalink
    Hey,

    do you have a email server (sendmail, etc.) on your server?

    what server are you using and what operating system?
    - your own, a webhosts, linux, etc..

    also port 25 might not be open on your server

    you normally get this error when theres no email server available

    Cheers

    Justin
    • CommentAuthorcpankonien
    • CommentTimeOct 27th 2007 edited
     permalink
    hello Justin,
    i'm getting the same error, trying to use my existing mail server which is hosted outside my network (mail.ccpip.com). si (v20071002) is on an ubuntu 6.06.1 fresh install. sendmail is not installed on si server, is that a requirement? (ugh...last time i messed with sendmail it took a week!) i can ping my mail server from the si server, so dns is working ok...so i guess the question is - can si send mail to an existing mail server, or do i need sendmail installed to relay? thanks!
    • CommentAuthorjustin
    • CommentTimeOct 28th 2007 edited
     permalink
    Hey Cpankonien,

    if your on ubuntu just try setting the mail server to localhost and see what happens

    else try using postfix as the smtp server - seems to work ok with minimal effort

    ive never used the remote email server option - might have to give it a go

    Cheers

    Justin
    • CommentAuthorcpankonien
    • CommentTimeOct 28th 2007 edited
     permalink
    Hey Justin,
    Yea, it was set to local host originally, so i tried setting to my mail server info, no go. i'll give postfix a try today and see how it goes.


    thanks

    cliff
    • CommentAuthorcpankonien
    • CommentTimeOct 28th 2007 edited
     permalink
    i installed postfix as a satelite, which i assume (yea, i know!) means that it will forward to mail.ccpip.com. i don't get an error now, (in fact it says "invoice sent as pdf" but the mail never shows up, so time to research postfix...
    • CommentAuthorcpankonien
    • CommentTimeOct 28th 2007 edited
     permalink
    woohoo! it works! i installed postfix as previously stated, but wasn't receiving the emails. i went into config.php and set mail server name, mail username and password, restarted apache and it now works! i was pretty sure i had inserted the email server info before, but maybe it wasn't in config.php but somewhere else...at any rate, postfix does not appear to be necessary, as i removed postfix and it still works. very cool!
    • CommentAuthorjustin
    • CommentTimeOct 28th 2007 edited
     permalink
    Hey Cliff,

    great to hear emails working now!

    Cheers

    Justin