SLES 9 running postfix, apache, mysql, php, how can I add webmail

Whats the easiest way to get webmail of some sort?
LVL 6
wirthrAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

steve918Commented:
You might download and install squirrelmail, it's what I've alway's used and it's simple to install and easy to configure.
0
wesly_chenCommented:
For Webmail, you can use Squirrel:
http://www.squirrelmail.org/download.php
--------------------
1. Uncompress and extract squirrel mail into a directory that is accessible by the apache web server:
# cd /var/www/html    <=== (your Apache webpage root, it may varys)
# mkdir squirrel
# cd squirrel
# bzcat squirrelmail*bz2 | tar xvf -

2.Create directories to be used for attachments and user data:
# mkdir -p /export/squirrel/data
# mkdir -p /export/squirrel/attachments
# cd /export/squirrel
# chgrp -R apache attachments data
# chmod 730 attachments

3. Edit the config/config.php file, and set the $data_dir and $attachment_dir to the same as the squirrel directory:
...
$data_dir                 = '/export/squirrel/data/';
$attachment_dir           = '/export/squirrel/attachments/';

4. Enable file_uploads in the php.ini file:
...
file_uploads = On
 
5. Create a file named /var/www/html/squirrel/.htaccess with the following contents:
AddType application/php4script .php
Action application/php4script /cgi-bin/php

6. From a browser, access squirrelmail with a URL similar to: http://yourservername/squirrelmail
------------------------------

For more details about
http://www.linuxmigration.com/quickref/admin/email.html

Regards,

Wesly
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
wirthrAuthor Commented:
Error opening ../data/default_pref
Could not create initial preference file!
../data/ should be writable by user wwwrun
Please contact your system administrator and report this


when I went to webmail/index.php
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

wirthrAuthor Commented:
I chmod data to 733, now I get

ERROR:  
ERROR : Could not complete request.
Query: SELECT "INBOX"
Reason Given: Mailbox does not exist
 
0
wirthrAuthor Commented:
ERROR:  
ERROR : Could not complete request.
Query: CREATE "INBOX.Sent"
Reason Given: Permission denied
 
0
wesly_chenCommented:
You need to "su root". I mean do it ad "root".

Wesly
0
wirthrAuthor Commented:
no, I got that when I tried to login on the webpage
0
wirthrAuthor Commented:
It creates bryan.pref in the maildata directory, but something isnt letting it create inbox.sent, wherever that is supposed to happen.
0
wirthrAuthor Commented:
mail:/srv/www/htdocs/webmail # dir
total 117
drwxr-xr-x  18   1005 users   728 Nov  9 07:10 .
drwxr-xr-x   9 root   root   1616 Nov  9 06:48 ..
-rw-r--r--   1 root   root     80 Nov  9 06:59 .htaccess
-rw-r--r--   1   1005 users  5906 May 19 08:57 AUTHORS
-rw-r--r--   1   1005 users 15131 Dec 16  1999 COPYING
-rw-r--r--   1   1005 users 45347 Jun  2 22:42 ChangeLog
-rw-r--r--   1   1005 users  6827 Apr 26  2004 INSTALL
-rw-r--r--   1   1005 users  2625 Apr  3  2003 README
-rw-r--r--   1   1005 users  3319 Jun  2 22:42 ReleaseNotes
-rw-r--r--   1   1005 users  4708 Jun 12  2003 UPGRADE
drwx-wx---   2 root   www      80 Nov  9 07:04 attachments
drwxr-xr-x   5   1005 users   216 Jun  2 23:06 class
drwxrwxr-x   2   1005 users   208 Nov  9 06:53 config
-rwxr-xr-x   1   1005 users    92 Dec 26  2001 configure
drwxr-xr-x   3   1005 users    72 Jun  2 23:06 contrib
drwxr-xr-x   2   1005 users   176 Nov  9 06:55 data
drwxr-xr-x   3   1005 users   544 Jun  2 23:06 doc
drwxr-xr-x   3   1005 users  1176 Jun  2 23:06 functions
drwxr-xr-x  29   1005 users   728 Jun  2 23:06 help
drwxr-xr-x   2   1005 users  1304 Jun  2 23:06 images
drwxr-xr-x   3   1005 users   168 Jun  2 23:06 include
-rw-r--r--   1   1005 users   338 Feb 24  2004 index.php
drwxr-xr-x  44   1005 users  1120 Jun  2 23:06 locale
drwxr-xr-x   2 wwwrun root     80 Nov  9 07:11 maildata
drwxr-xr-x  18   1005 users   608 Jun  2 23:06 plugins
drwxr-xr-x   2   1005 users   272 Jun  2 23:06 po
drwxr-xr-x   2   1005 users  1344 Jun  2 23:06 src
drwxr-xr-x   3   1005 users  1496 Jun  2 23:06 themes
mail:/srv/www/htdocs/webmail #
0
wesly_chenCommented:
The ownership of /srv/www/htdocs/webmail should be the same as the one own /srv/www/htdocs.

Where is your mail spool? (/var/spool/mail ?)
You need to go into the config directory and configure the remaining steps with the included perl script:
--------------------------------
cd /srv/www/htdocs/webmail/config
perl conf.pl
When running conf.pl, follow the instructions.
tips:

ORGANIZATION PREFERENCES
Change name to whatever you'd like.
SERVER SETTINGS
Change Domain to your domain
Change IMAP server to your server.
Change SMTP server to your server.
GENERAL OPTIONS
Change Data Directory, (optional BUT preferred).
Change Attachment Directory
------
Wesly
0
wirthrAuthor Commented:
/var/spool/mail is correct

I ran conf.pl, and made the appropriate changes already, I went to the squirrelmail website and read the faq's.    

Changed owner of webmail to root, which was owner of htdocs

now get

 Preference file, ../maildata/bryan.pref, could not be opened. Contact your system administrator to resolve this issue.
0
wirthrAuthor Commented:
in httpd.conf, it has webuser is wwwrun and group is www

I change permissions on webmail directory to owner wwwrun and group www and I am back to

ERROR : Could not complete request.
Query: CREATE "INBOX.Sent"
Reason Given: Permission denied
0
wesly_chenCommented:
Is /srv/www/htdocs/maildata/bryan.pref or use
# find / -name "bryan.ref" -print
to find out where bryan.ref and change the permission 744 on it.

Wesly
0
wirthrAuthor Commented:
I chmod the whole freakin webmail directory  to 777 and still get this in the left frame

ERROR : Could not complete request.
Query: CREATE "INBOX.Sent"
Reason Given: Permission denied

and

ERROR:  
ERROR : Could not complete request.
Query: SELECT "INBOX"
Reason Given: Mailbox does not exist
 

in the main frame, same as before
 
 
 
0
wirthrAuthor Commented:
oh yeah, and I can telnet to server:143 and login with username/password and works fine
0
wirthrAuthor Commented:
tried to set it up in outlook, and when I do a send recieve I get



Task 'Checking for new mail in subscribed folders on www.myservername.com.' reported error (0x800CCC0E) : 'Outlook is unable to download folder (null) from the IMAP e-mail server for account www.myservername.com. Error: Unable to connect to the server. If you continue to receive this message, contact your server administrator or Internet service provider (ISP).'


so maybe its a problem with cyrus
0
wirthrAuthor Commented:
nevermind, got that to go away by using my ip instead of fqdn, but when I send a testmessage to myself, i dont recieve it.  I created Inbox through outlook, and now squirrelmail gives me this in the left hand frame

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 358

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 371

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 358

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 371

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 358

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 371

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 358

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/functions/imap_mailbox.php on line 371
Folders

Last Refresh: Tue, 9:02 am
(refresh folder list)


Warning: explode(): Empty delimiter. in /srv/www/htdocs/webmail/src/left_main.php on line 275

Warning: array_pop(): The argument should be an array in /srv/www/htdocs/webmail/src/left_main.php on line 276

Warning: implode(): Bad arguments. in /srv/www/htdocs/webmail/src/left_main.php on line 277

Warning: explode(): Empty delimiter. in /srv/www/htdocs/webmail/src/left_main.php on line 275

Warning: array_pop(): The argument should be an array in /srv/www/htdocs/webmail/src/left_main.php on line 276

Warning: implode(): Bad arguments. in /srv/www/htdocs/webmail/src/left_main.php on line 277

Warning: explode(): Empty delimiter. in /srv/www/htdocs/webmail/src/left_main.php on line 275

Warning: array_pop(): The argument should be an array in /srv/www/htdocs/webmail/src/left_main.php on line 276

Warning: implode(): Bad arguments. in /srv/www/htdocs/webmail/src/left_main.php on line 277

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/src/left_main.php on line 923
  INBOX

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/src/left_main.php on line 923
  INBOX.Drafts

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/src/left_main.php on line 923
  INBOX.Sent

Warning: substr_count(): Empty substring. in /srv/www/htdocs/webmail/src/left_main.php on line 923
  INBOX.Trash
 
0
wirthrAuthor Commented:
ok, seems like evereything on the page loads right now, no errors, but it wont display new messages.  I send myself a test, but it doesnt ever show up.  If I pop to my mail server, then I recieve it.
0
wesly_chenCommented:
> wont display new messages
You mean there are some old mails showing up?

Wesly
0
wirthrAuthor Commented:
no mail at all, items will appear in the sent items if I use squirrelmail to send out a message, and if I delete something, it moves to trash, but there is nothing in the inbox.
0
wesly_chenCommented:
That means the SMTP and IMAP setting are incorrect.

Wesly
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.