I'm currently attempting to setup SquirrelMail 1.4.2 from ports in a
FreeBSD 4.9-RELEASE jail. PHP is at version 4.3.6. I've run into a little
problem with regards to uploading attachments. Before you say it, I've
scoured the wiki on squirrelmail.org and tried everything there to no
avail.

I followed the directions near the bottom on the QuickAndDirty wiki page
for setting up the attachments directory. When I try to upload an
attachment, I'm met with mostly-unhelpful "Could not move/copy file. File
not attached". I did actually find that a slightly older version of Lynx
wasn't able to upload files at all, but verified that a newer one worked
when I successfully uploaded an attachment to a known-working installation
of SquirrelMail.

The next thing I tried was hitting the SquirrelMail wiki for
troubleshooting help and found the DirectoryPermissionsProblem page, but
unfortunately none of the hints there helped. The config.php settings look
correct, the attachment directory permissions look correct and the PHP
settings look correct.

I'm truly at a loss to explain this. I'd hack at the PHP source to at
least print out some more informative errors, but I'm afraid my knowledge
of PHP is zilch. Following is a terminal session that should give you a
better picture of my system:

# cd /www/vhosts/webmail-test.domain-deleted.com/
# grep attach config/config.php
$attachment_dir           = SM_PATH . 'attach/';
# ls -ld attach
drwx-wx---  2 root  www  512 May 16 23:28 attach
# php -r 'phpinfo();' | grep file_uploads
file_uploads => On => On
# php -r 'phpinfo();' | grep session.auto_start
session.auto_start => On => On
# php -r 'phpinfo();' | grep safe_mode
safe_mode => Off => Off

(If I run ./configure, the attachment directory shows up as "../attach/"
as it should. Also, the webmail-test* directory above is actually a
symlink to /usr/local/www/squirrelmail, which is where ports installed it.
I verified that the symlink wasn't causing the error by pointing apache to
the original directory and that didn't help either.)

If there's any more useful information that I can provide, please let me
know. I'd be eternally grateful to anyone who offers help and suggestions.
I'll be sure to update the SM wiki when the solution presents itself.

Thanks for the thorough email. The only other thing I can think of is to move your attachments directory out of the SM tree (and out of the web servers htdocs tree entirely), which is something you should do anyway. After that, name the path explicitly in the SM config, not relatively. Try setting permissions recursively on that directory to 777 for starters to see if you can get it to work, but don't dare leave it like that.


 - Paul



-------------------------------------------------------
This SF.Net email is sponsored by: SourceForge.net Broadband
Sign-up now for SourceForge Broadband and get the fastest
6.0/768 connection for only $19.95/mo for the first 3 months!
http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click
--
squirrelmail-users mailing list
List Address: [EMAIL PROTECTED]
List Archives:  http://sourceforge.net/mailarchive/forum.php?forum_id=2995
List Info: https://lists.sourceforge.net/lists/listinfo/squirrelmail-users

Reply via email to