postfix/squirrelmail with plugin retreiveuserdata

Discussion in 'HOWTO-Related Questions' started by [email protected], Nov 30, 2009.

  1. lance@ottawaitservices.ca

    [email protected] New Member

    Hello all,

    I am new to Linux in general, and to this forum . Please bear with me, I apologize if this is not in the most appropiate section.

    I have installed CentOS with Postfix and Dovecot, managed with ISPConfig 2.2.32 , the latest versions.
    Everything is working very well - not bad for a first time Linux user .

    Here is the one issue I have, I really hope someone can help me.

    When I create a new email account in ISPConfig for a site, ISPConfig gives the username as "web12_<name>" . For example my username is "web13_lance" to login via Dovecot . Of course, Squirrelmail seems to be smarter, and lets me actually login with the email address; lance@(my domain) .

    I noticed that I had to fill in my email address in Squirrelmail (Options) manually. I didn't want to have to do this for all users in the future. So I installed a plugin to Squirrelmail called "retreiveuserdata" . The plugin is working just great - with one problem; the email address it automatically configures for the user is the "web13_lance@<mydomain>" rather than the actually email "lance@<mydomain>" . So if any user sends out an email, it will show the reply to address as "web13_....@<my domain>" .

    Again I am very very new to linux in general, could someone please help me out?!

    Lance Purcell
    [email protected]
     
  2. falko

    falko Super Moderator Howtoforge Staff

    I guess the only solution would be if you wrote your own SquirrelMail plugin that reads out the email address from the ISPConfig database based on the username.
     
  3. patman

    patman New Member

    Try to modify database

    First, sorry for my English :)

    I have similar issue. Try to modify your username with mysql:

    mysql -u root -p yourpassword
    connect dbispconfig
    show tables; (it shows you tables in db, users configuration in mail_user table)
    If you want to see the table's content:
    select * from mail;,
    and table's structure:
    desc mail_user;
    And at last:
    update mail_user set email="yourpreferedname" where email="web13_lance@<mydomain>"

    Good luck
     
    Last edited: Nov 30, 2009
  4. lance@ottawaitservices.ca

    [email protected] New Member

    Hi Patman,

    Thanks for your assistance. I followed your instructions but got an error when running "connect dbispconfig"

    ERROR 1049 (42000): Unknown database 'dbispconfig'

    Perhaps my database' name is dfiferent, is there another possible name or a way to see all the databases mysql is running?
     
  5. lance@ottawaitservices.ca

    [email protected] New Member

    Hi Patman,

    I figured out how to access the correct database name and your instructions worked perfectly. Is there any way to make it so that in the future, this is done automatically when the account is first created?
     
  6. patman

    patman New Member

    Hi. It's quite possible you have got different database name. In mysql use command show databases;, it should show correct db name.
    Honestly, I don't know how to do that :/
     
    Last edited: Dec 1, 2009

Share This Page