PDA

View Full Version : E-mail send not true!??


baby_ghost
8th July 2009, 12:09
Hi everybody, I'm using CentOS 5.3 with ISPconfig 2.2.32. Installing progess has not any error and ISPconfig run perfect! But I have a problem in e-mail services, I'm using squirremail webmail and when login webmail to send any e-mail, sender disaplay is not my domain!

I added a site with domain abc.com, and creat an e-mail for it: info@abc.com. Then i logged in webmail and send a test e-mail to my gmail, sending successfully, but when I receive e-mail in Gmail, sender is not my domain

http://img160.imageshack.us/img160/6439/mail1.jpg

http://img188.imageshack.us/img188/8350/mail2m.jpg

What's step which I wrong?

Mark_NL
8th July 2009, 12:26
it's saying "@example.com" so i think you rushed through the config files a bit to fast :P

the default config is saying:
$domain = 'example.com';

so i think there's your problem?

baby_ghost
8th July 2009, 12:34
it's saying "@example.com" so i think you rushed through the config files a bit to fast :P

the default config is saying:
$domain = 'example.com';

so i think there's your problem?
Before I look at config file, I run this command to add my own hostname
postconf -e 'myhostname = server1.example.com'
then
service postfix restart
ok, retry, hix T__T has nothing change :(

Then I looked at my config file
vi /etc/postfix/main.cf
but I can't found:
the default config is saying:
$domain = 'example.com';

Mark_NL
8th July 2009, 12:53
I'm using squirremail webmail...

I was referring to your squirrelmail configuration ;)

baby_ghost
8th July 2009, 13:45
I was referring to your squirrelmail configuration ;)
Yeah, that's my problem, I modified my squirrelmail configuration and now it sent email with true domain, but user was wrong!?

When creat e-mail user in ispconfig, we have two choice:
E-mail: abc@domain.com
and user: Prefix_user

We use e-mail and password to log in squirrelmail, but when send, it use username to send mail: prefix_user@domain.com but the true e-mail is: abc@domain.com

Another problem, I fixed wrong domain error, but now, an error occur from that. I have some sites hosted on my server runing ispconfig. Each site have e-mail with site's domain. But any user from any site using webmail were sent mail with only one domain which define in configuration file! So what should I do? :(

Mark_NL
8th July 2009, 15:07
hehe i understand your problem .. what you _could_ do, is patch the php config file, so it reads the hostname, strips of the "www." part and uses that as $domain = ''; (this will only work if all clients can use: www.client_domain.com/webmail .. so set as alias for all websites, i've put instructions on that here before, it's (it's the same way but then for roundcube webmail): http://www.howtoforge.com/forums/showthread.php?p=197583#post197583 )

i think something like this should work:

preg_match('/.*?\.(.*)/', $_SERVER['SERVER_NAME'], $aMatch);
$domain = $aMatch[1];

baby_ghost
9th July 2009, 14:33
hehe i understand your problem .. what you _could_ do, is patch the php config file, so it reads the hostname, strips of the "www." part and uses that as $domain = ''; (this will only work if all clients can use: www.client_domain.com/webmail .. so set as alias for all websites, i've put instructions on that here before, it's (it's the same way but then for roundcube webmail): http://www.howtoforge.com/forums/showthread.php?p=197583#post197583 )

i think something like this should work:

preg_match('/.*?\.(.*)/', $_SERVER['SERVER_NAME'], $aMatch);
$domain = $aMatch[1];

Maybe I have to install webmail for each site when creat :(

I have problem seem as thread owner: http://www.howtoforge.com/forums/showthread.php?p=197583#post197583

Keep getting 404 error although config alias in httpd

falko
9th July 2009, 17:12
You must set the correct sender address in your email client (e.g. Squirrelmail or Uebimiau).

baby_ghost
9th July 2009, 21:00
You must set the correct sender address in your email client (e.g. Squirrelmail or Uebimiau).
Yeah, if I manula config my name, my e-mail in options page of squirrelmail, e-mail was sent with true value, maybe we won't have an automatic system :D Thanks for any response of you :)