View Full Version : SquirrelMail 1.3.1 assistance....
SmackDaddy
09-03-2002, 07:28 PM
SquirrelMail......cannot get it working properly.....Steven tells me some of you have this installed and functioning.....
Anyone care to help me out? Please?
I get the following error when logging in:
Fatal error: Failed opening required 'DB.php' (include_path='') in /home/gopherho/public_html/squirrelmail/functions/db_prefs.php on line 35
I think I may just start again.....but the SM mailing list assumes I know all there is to know about IMAP, Linux, and anything else needing to make this work. With no install script or good instructions, I have fudged my way to this point.
I *was* able to SSH in and run conf.pl to get the general settings up and running....but cannot get the darn thing working....*sigh* I mean, getting up and running is going to be one thing....but then how do I make sure preferences and address books and external POP data is saved via mySQL??!?!??! Arrrrggggg......
Any help would be appreciated......thanks!
CrimsonScythe
09-03-2002, 08:57 PM
SmackDaddy:
I faced this problem myself, and the reason for this issue is a misconfigured php.ini file. There is a simple fix for it, though :)
This is my response to someone with the exact same problem in the Squirrelmail forums:
My experience is that the include_path in php.ini MUST include the "/usr/local/lib/php/". By default php.ini is not set to anything, but still shows up correctly in phpinfo()! I have had the excact same problem.
If you have root privileges, add the above path to php.ini, if not, you can add this in the beginning of your config.php file:
ini_set("include_path",ini_get("include_path").":"."/usr/local/lib/php/");
I hope this was of any help!
-- Thomas
You should add the string
ini_set("include_path",ini_get("include_path").":"."/usr/local/lib/php/");
to the beginning of your squirrelmail config/config.php file so that it looks like this:
<?php
ini_set("include_path",ini_get("include_path").":"."/usr/local/lib/php/");
/**
* BEFORE EDITING THIS FILE!
*
.....
Sorry if this is a little "too detailed", but I figured more people might want to install SM. If you have any more questions: shoot :)
-- Thomas
harmonic
09-04-2002, 10:55 AM
that's odd, i am able to include files... are you sure there isn't a place in the 'config' of squirrelmail that lets you set the path to where squirrelmail is?
SmackDaddy
09-04-2002, 02:51 PM
So, Crimson, is this a misconfiguration on IH's part? Or is there a php.ini for all users and this is something I can fix?
But if I understand you correctly, all I have to do is add that line listed above *before* the credits section and right after the "<?php" line? And that should fix that? Thanks for your response!!!
Steven
09-04-2002, 04:28 PM
We have installed Squirrel mail for ourselves on both servers without any problems. We even installed one for a client today. We have done this on both ferrari and porsche servers.
How are you installing it?
-Steven
CrimsonScythe
09-04-2002, 04:59 PM
I have to say I find this whole Pear module (in which we find the DB.php file) problem strange! I'm not sure why some of us have these problems, and I've only seen a couple of "theories". One is that the php.ini file is misconfigured and the other theory is that the problem occurs when there are two installations of Pear on the same computer. (In either case php have problems locating the module.)
What the reason is here is unclear to me, since some of us have been able to install SM, and others not. I will assume that it is the php.ini file. You see, the default include_path string is blank in php.ini, and relies on php itself "understanding" where it is, whereas setting the path fixed to "/usr/local/lib/php/" will remove the "guess-work". The fix I proposed, will just force the correct path for Squirrelmail upon loading the page. This means that if you use other scripts that rely on Pear you will also have to include the fix there too.
Anyway, the solution I posted above, will solve the problem.
SmackDaddy: I just placed the string in the beginning for two reasons:Conveniency (First thing you get to ;)) and making sure that it appears before it is used further down in the config.php file. If you place it there, you will be certain that the DB.php file will indeed be loaded :)
-- Thomas
Hello Thomas,
I just got squirrelmail installed today and also have a very minor, yet annoying problem. For some reason it lists some odd time and date of an email. For example, my advisor sent me an email yesterday (tuesday) at 4:36pm....squirrelmail reads this as Wed. at 12:34 am for some reason. I have the time zone set to US/Eastern in personal preferences and the clock above my folders is correct, yet it doesn't have the correct time or date for when the email arrived.
Do you know how to fix this?
Thanks!
Eric
ps I have SM 1.2.7 by the way...
CrimsonScythe
09-04-2002, 09:49 PM
Hmm... That sounds weird, my SM shows the correct date/time. To be totally honest, I have no idea as of now. Which server are you on? Maybe other people on that server get the same error if they set their time zone to the USA/Eastern?
-- Thomas
Steven
09-05-2002, 01:33 AM
Originally posted by Eric
Hello Thomas,
I just got squirrelmail installed today and also have a very minor, yet annoying problem. For some reason it lists some odd time and date of an email. For example, my advisor sent me an email yesterday (tuesday) at 4:36pm....squirrelmail reads this as Wed. at 12:34 am for some reason. I have the time zone set to US/Eastern in personal preferences and the clock above my folders is correct, yet it doesn't have the correct time or date for when the email arrived.
Do you know how to fix this?
Thanks!
Eric
ps I have SM 1.2.7 by the way...
Eric,
That is a wierd error, can you send us an e-mail with squirrelmail and check what time the message was sent. We will also send you a reply and you can check that time. Also login to SM and check under the options tab there is a Personal Information link. Check to make sure that you have the correct timezone.
-Steven
Steven... just sent an email to support@IH and according to squirrel mail it was sent at 4:21pm when in actually it was sent at 8:21 am so its 8 hours ahead.
I have the time zone options set to US/Eastern since Im in NY State. I played around with that a bit and tried a few other time zones...if I set to US/Eastern-Indiana then its only an hour ahead which is odd.
I'm on the Ferarri server, but when I set it to "time on server" it also gives me odd times.
-Eric
Edit..... I got an auto reply from support@ih that said 4:21pm as well. Is anyone else on Ferarri with Squirrelmail having this weird little problem?
Steven
09-05-2002, 09:23 AM
Eric,
Looks like an incorrect variable was set in the config files. Check now, as it should be fixed as I have replaced the incorrect variable with the correct one.
-Steven
Steven,
I just sent myself an email from another account to my squirrelmail account and the time appears to be back to normal. Thanks so much for spending so much time on this wierd little issue.
I did reply to your email that you sent, however, something got returned to me...it said something like relaying to XXX denied. Though it wasn't the whole message.
But wanted to let you know that it appears to be a fixed now! :)
Eric
Steven
09-05-2002, 02:14 PM
Eric,
Great news, I knew that was the problem, just had a feeling about it. Anyways, all email to support[at]insiderhosting.com will have an autoresponder because we have
tickets[at]insiderhosting.com setup for all support issues.
-Steven
SmackDaddy
09-06-2002, 04:13 PM
Well, getting back on topic.....I will try to re-install SquirrelMail from scratch this weekend and report back what happens......
Or maybe just do the fix suggested above first.... :D
Steven
09-06-2002, 05:06 PM
Smackers,
At what point are you getting that error? Let us know.
-Steven
SmackDaddy
09-07-2002, 03:43 AM
When logging in (as stated).....I log in....and then BLAM, that error listed above.....but will trying the submitted "fix" today or tomorrow.....
CrimsonScythe
09-07-2002, 10:35 AM
The fix I suggested will take care of this. The reason you get the error when loging in, is that SM tries to load the database interface file DB.php, so that it can get your user preferences from MySQL. :)
-- Thomas
SmackDaddy
09-07-2002, 04:14 PM
But.....how in the world can I get mySQL set up to save my preferences? Or will they be saved via a config file or something? I mainly want SquirrelMail so I can setup access to check other POP3 mails (which I see can be done)....while I am away from home.....
THanks.
CrimsonScythe
09-07-2002, 10:08 PM
Here is a step-by-step list of what you do to use a database backend for preferences and:
Log in to CPanel, click "Manage Mysql".
Create a database called "squirreldb", and a user called "squirreluser". Add the user to the database. You should now have a database f.ex. called "pctoolbin_squirreldb" and a user called "pctoolbin_squirreluser".
Go back to the main CPanel and click "phpMyAdmin". In phpMyAdmin, click on the database you just created, in the left menu. In this example called "pctoolbin_squirreldb". Now you will see a textbox with the caption "Run SQL query/queries on database pctoolbin_squirreldb". In this box paste the code from Codebox 1, and click "Go".
Codebox 1:
CREATE TABLE address (
owner varchar(128) DEFAULT '' NOT NULL,
nickname varchar(16) DEFAULT '' NOT NULL,
firstname varchar(128) DEFAULT '' NOT NULL,
lastname varchar(128) DEFAULT '' NOT NULL,
email varchar(128) DEFAULT '' NOT NULL,
label varchar(255),
PRIMARY KEY (owner,nickname),
KEY firstname (firstname,lastname)
);
CREATE TABLE userprefs (
user varchar(128) DEFAULT '' NOT NULL,
prefkey varchar(64) DEFAULT '' NOT NULL,
prefval BLOB DEFAULT '' NOT NULL,
PRIMARY KEY (user,prefkey)
);
This is the last step :) Use the filemanager and find your SquirrelMail config.php file. (Assuming you have set up the rest and applied the fix mentioned earlier in this thred.) In this file, towards the end, you will find this:
Codebox 2:
/**
* Database-driven private addressbooks
* DSN (Data Source Name) for a database where the private
* addressbooks are stored. See doc/db-backend.txt for more info.
* If it is not set, the addressbooks are stored in files
* in the data dir.
* The DSN is in the format: mysql://user: pass@hostname/dbname
* The table is the name of the table to use within the
* specified database.
*/
global $addrbook_dsn, $addrbook_table;
$addrbook_dsn = '';
$addrbook_table = 'address';
global $prefs_dsn, $prefs_table;
$prefs_dsn = '';
$prefs_table = 'userprefs';
Here you only need to change two values to this:
Codebox 3:
$addrbook_dsn = 'mysql://pctoolbin_squirreluser:yourpassword@localhost/pctoolbin_squirreldb';
$prefs_dsn = 'mysql://pctoolbin_squirreluser:yourpassword@localhost/pctoolbin_squirreldb';
Save the file, and you're set to go :D[/list=1]
If you want to use the old fasion way, using flatfiles, you leave the config entries as shown in Codebox 2.
Now you may be asking: "Why use the database for this?"
There are two compelling reasons to use MySQL:[list]
You can write other applications that can use the same addressbook or preferences.
You can easily use phpMyAdmin to make backups of your addressbook or preferences. It is NOT possible to make a backup of your preferences using the file manager.
Databases are cooler than flat-files ;) Good luck!
If anyone want me to write a complete tutorial for installing Squirrelmail, with various plugins, let me know...
-- Thomas
Hey thomas, thanks for helping out so much, we appreciate :)
SmackDaddy
09-13-2002, 09:54 PM
Well.....as per Steven's suggestion, I went with the 1.2.7 version (latest Stable release) instead of doing the 1.3.1 (beta).....
And I have things installed and working. One problem I am now having is the built in "Fetch" mod.....
When I try and access mail from accounts on the ferrari server (other domains I have), I get the following error when checking POP mail:
Oops, POP3: premature NOOP OK, NOT an RFC 1939 Compliant server
Although I am in my GopherHosting.com account in Squirrel mail, it will not let me fetch other POP accounts using mail.gopherhosting.com -- very strange.....
How do I get around this? I would like to check all of my accounts from within my ONE account using "Fetch".....thanks.
CrimsonScythe
09-13-2002, 11:55 PM
OK, after a little digging, here is how you can solve your problem. In your plugins/mail_fetch folder you should have a file called class.POP3.php. On line 109 and down, you should find this:
if($this->RFC1939) {
$this->ERROR = _("POP3: premature NOOP OK, NOT an RFC 1939 Compliant server");
$this->quit();
return false;
} else
return true;
}
What you should do, is to comment out the warning, as it doesn't really do anything important. You should comment it so that it says:
// if($this->RFC1939) {
// $this->ERROR = _("POP3: premature NOOP OK, NOT an RFC 1939 Compliant server");
// $this->quit();
// return false;
// } else
return true;
}
I hope this helps :)
-- Thomas
SmackDaddy
09-14-2002, 05:42 AM
Thanks Crimson, I'll try that out this weekend...
SmackDaddy
11-20-2002, 09:58 AM
I know this is resurrecting an old thread, but I just NOT got around to fixing this issue. Crimson, that worked like a charm......
Sorry for the delay in responding, but......it now works.
Thanks all (even *IF* it was a bit late)....
lucas
11-20-2002, 08:26 PM
whats the advantage of using squirrelmail?
SmackDaddy
11-20-2002, 09:28 PM
Lucas, the advantage for me personally was that i could check external POP accounts with it.......along with the account I am using to log in.
So....when I am not at home, I log in.....and when I do, the set up POP accounts are checked (all 7 of them) and viola.....I can keep in touch with my clients and or friends/family while on the road.
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.