Virtual Users And Domains With Postfix,

Discussion in 'HOWTO-Related Questions' started by FredZ, Feb 20, 2007.

  1. FredZ

    FredZ Member

    I have decided to give this howto a try after much trouble with the fedora version. Now I have an even more elementry problem.

    How do I get putty to copy/paste?

    Currently I can copy from local (fedora machine) but when I goto right click to copy to remote (putty) nothing happens. The remote machine is a debian sarge box.

    Regards

    Fred
     
  2. FredZ

    FredZ Member

    I pulled out the very old windows laptop and installed putty on that, so I have managed to get putty working so I can continue. I would like to get putty working properly on my fedora machine though.

    I have a problem with the very first line of the howto.
    apt-get install postfix postfix-mysql postfix-doc mysql-client mysql-server courier-authdaemon courier-authmysql courier-pop courier-pop-ssl courier-imap courier-imap-ssl postfix-tls libsasl2 libsasl2-modules libsasl2-modules-sql sasl2-bin libpam-mysql openssl phpmyadmin

    The error I get is:

    Reading Package Lists... Done
    Building Dependency Tree... Done
    Package postfix-mysql is not available, but is referred to by another package.
    This may mean that the package is missing, has been obsoleted, or
    is only available from another source
    E: Package postfix-mysql has no installation candidate


    Does anyone have any thoughts.

    Regards

    Fred
     
  3. iverson0881

    iverson0881 New Member

  4. FredZ

    FredZ Member

  5. FredZ

    FredZ Member

    Well it took a fair bit of sorting out, but I worked out what I hadn't done.

    You MUST do a apt-get update before you start to install anything.

    Regards

    Fred
     
  6. FredZ

    FredZ Member

    Well I got as far as page 4 before I got an error.

    I modified the /etc/spamassassin/local.cf as shown.

    Ran /etc/init.d/amavis restart

    Error:

    Stopping amavisd: (not running).
    Starting amavisd: Error in config file /etc/amavis/amavisd.conf: syntax error at /etc/amavis/amavisd.conf line 836, near "'SELECT "Y" as local FROM domains WHERE CONCAT("@",domain) IN (%k)';"
    (failed).

    I re-checked the line and it is as per the instructions.

    Does anyone have any thoughts.

    Regards

    Fred
     
  7. martinfst

    martinfst Member Moderator

    You have switched the ; and ' at the end of the statement. The ; is part of the MySQL syntax and should be within the quotes.
     
  8. FredZ

    FredZ Member

    I have altered the line to read as follows:

    $sql_select_policy = 'SELECT "Y" as local FROM domains WHERE CONCAT("@",domain) IN (%k);'


    I now get the following error:

    Stopping amavisd: (not running).
    Starting amavisd: Scalar found where operator expected at /etc/amavis/amavisd.conf line 849, near "$sql_select_white_black_list"
    (Missing semicolon on previous line?)
    Error in config file /etc/amavis/amavisd.conf: syntax error at /etc/amavis/amavisd.conf line 849, near "$sql_select_white_black_list "
    (failed).

    The line at 849 reads:

    $sql_select_white_black_list = undef; # undef disables SQL white/blacklisting


    It would have been easier if this howto could have been cut and paste via putty properly. If I pasted from the howto into the remote (putty) it puts it all on one very long line. So it took me some 3 hours to go through it line be line between the howto and what was on the server for that one file.

    Anyways, hopefully someone can help further with my problem.

    Regards

    Fred
     
  9. martinfst

    martinfst Member Moderator

    You should add another ; at the end of the line (836?). Every command should be terminated with a semicolon also. Sorry, I should have been more careful with my initial response.
     
  10. FredZ

    FredZ Member

    I have now altered the line to read:

    $sql_select_policy = 'SELECT "Y" as local FROM domains WHERE CONCAT("@",domain) IN (%k);';

    The error I how get is:

    Stopping amavisd: (not running).
    Starting amavisd: Error in config file /etc/amavis/amavisd.conf: syntax error at /etc/amavis/amavisd.conf line 836, near "'SELECT "Y" as local FROM domains WHERE CONCAT("@",domain) IN (%k);';"
    (failed).


    Regards

    Fred
     
  11. FredZ

    FredZ Member

    Well I have managed to get it all up and running.

    I copied and pasted the contents of the new /etc/amavis/amavisd.conf to a file on another machine and copied it over the file on the debian server. It would appear that I had a number of typos in that file.

    Many thanks to those whom offer their assistance.

    Thanks for the howto in the first place.

    Now to go play, backing up the system first of course.

    Regards

    Fred
     

Share This Page