Koozali.org: home of the SME Server

need help WebMail problem

Peter S

need help WebMail problem
« on: July 01, 2002, 09:11:12 PM »
Hi All
When accessing webmail with remote dialup using https I get this message
Warning: Access denied for user: 'hordemgr@localhost' (Using password: YES) in /home/httpd/horde-phplib/db_mysql.inc on line 73

any ideas would be welcome

thanks in advance

Tim Hogan

Re: need help WebMail problem
« Reply #1 on: July 09, 2002, 07:53:50 PM »
Did you figure this one out?  I am having a similar problem.  Whenever a user tries to get to their email via webmail (from the local network) they receive a fatal error:

object(db_error)(7) {
  ["error_message_prefix"]=>
  string(0) ""
  ["mode"]=>
  int(1)
  ["level"]=>
  int(1024)
  ["code"]=>
  int(-24)
  ["message"]=>
  string(24) "DB Error: connect failed"
  ["userinfo"]=>
  string(86) " [nativecode=Access denied for user: 'horde@localhost' (Using password: YES)] ** Array"
  ["callback"]=>
  NULL
}
[/home/httpd/html/horde/lib/Prefs/sql.php : 102]

Dan Brown

Re: need help WebMail problem
« Reply #2 on: July 09, 2002, 08:00:48 PM »
Is this in SME 5.5?  If so, it should probably be reported to bugs@e-smith.com.

Peter S

Re: need help WebMail problem
« Reply #3 on: July 09, 2002, 08:12:17 PM »
SME 5.1.2 and I still can't get into the webmail

Tim Hogan

Re: need help WebMail problem
« Reply #4 on: July 09, 2002, 08:22:27 PM »
My problem is on SME 5.5.  I reported it yesterday and am awaiting a response.  I was hoping it might not be a bug but a configuration problem someone else had figured out.  The problem began after upgrading to V 5.5 from V 5.12 yesterday.  It seemed odd that others seem to have upgraded and have not encountered this problem, so I have been searching through my customized templates looking for a clue but I either it is not there or I don't know enough to recognize it (a real possibility).  I must have installed something under 5.12 that others have not installed that is causing the problem.  The items I added that might affect this are:

From myezserver:
user-manager (includes procmail)
obtuse-smtpd-qmail-2.0-34.i386.rpm (solves problem identified by RAV antivirus)

From RAV:
RAV antivirus (latest version)

From Stephen Noble's site:
devinfo-mitel-procmail-imaprootpatch-0.1-2.noarch.rpm

Tim Hogan

Dan Brown

Re: need help WebMail problem
« Reply #5 on: July 09, 2002, 08:29:34 PM »
Sounds like you've upgraded IMP, then (would have been helpful to mention that initially).  Somehow the horde password didn't get set correctly.  Has it ever worked?  What errors, if any, did you get when you installed?

You should be able to fix this by logging in as root and running these commands:

# mysql
mysql> grant all on horde.* to horde@localhost identified by 'horde';
mysql> quit

Tim Hogan

Re: need help WebMail problem
« Reply #6 on: July 09, 2002, 10:01:37 PM »
IMP was upgraded in server upgrade from 5.12 to 5.5.  Webmail worked fine before the upgrade to 5.5 yesterday.  

On booting up after the upgrade I received the following message:

Jul  8 08:38:52 e-smith-server migrate-imp-to-turba: Migrating IMP 2.x address book to IMP 3.x (Turba)
Jul  8 08:38:52 e-smith-server migrate-imp-to-turba: Migrating database
Jul  8 08:38:57 e-smith-server migrate-imp-to-turba: loading /etc/e-smith/sql/init/30mysql.create.horde.sql into mysql
Jul  8 08:38:57 e-smith-server migrate-imp-to-turba: /etc/rc.d/init.d/mysql.init: /etc/e-smith/sql/init/30mysql.create.horde.sql: No such file or directory
Jul  8 08:38:58 e-smith-server migrate-imp-to-turba: Loading data into mysql
Jul  8 08:39:02 e-smith-server mysql.init: Loading data into mysql failed
Jul  8 08:39:02 e-smith-server migrate-imp-to-turba: ^[[60G
Jul  8 08:39:02 e-smith-server migrate-imp-to-turba: [
Jul  8 08:39:02 e-smith-server migrate-imp-to-turba: ^[[1;31m
Jul  8 08:39:02 e-smith-server migrate-imp-to-turba: FAILED
Jul  8 08:39:02 e-smith-server migrate-imp-to-turba:
Jul  8 08:39:02 e-smith-server migrate-imp-to-turba: Creating Turba objects table
Jul  8 08:39:05 e-smith-server migrate-imp-to-turba: DBI->connect(horde:localhost:3306) failed: Access denied for user: 'horde@localhost' (Using password: YES) at /etc/rc.d/init.d/migrate-imp-to-turba line 120
Jul  8 08:39:05 e-smith-server migrate-imp-to-turba: Converting book entries
Jul  8 08:39:05 e-smith-server rc: Starting migrate-imp-to-turba:  failed


I have run the mysql commands you suggested and seem to be making progress in that I now get different messages.  The first thing I did after running the mysql command was to reboot the server to give migrate-imp-to-turba a chance to run again.  This time it gave a status of ok while booting.  However, the script generated in boot.log reads:


Jul  9 10:43:16 e-smith-server migrate-imp-to-turba: Migrating IMP 2.x address book to IMP 3.x (Turba)
Jul  9 10:43:16 e-smith-server migrate-imp-to-turba: Migrating database
Jul  9 10:43:19 e-smith-server migrate-imp-to-turba: loading /etc/e-smith/sql/init/30mysql.create.horde.sql into mysql
Jul  9 10:43:19 e-smith-server migrate-imp-to-turba: /etc/rc.d/init.d/mysql.init: /etc/e-smith/sql/init/30mysql.create.horde.sql: No such file or directory
Jul  9 10:43:19 e-smith-server migrate-imp-to-turba: Loading data into mysql
Jul  9 10:43:19 e-smith-server mysql.init: Loading data into mysql failed
Jul  9 10:43:19 e-smith-server migrate-imp-to-turba: ^[[60G
Jul  9 10:43:19 e-smith-server migrate-imp-to-turba:
Jul  9 10:43:19 e-smith-server migrate-imp-to-turba: Creating Turba objects table
Jul  9 10:43:21 e-smith-server migrate-imp-to-turba: Converting book entries
Jul  9 10:43:21 e-smith-server migrate-imp-to-turba: Disabling migration script
Jul  9 10:43:21 e-smith-server migrate-imp-to-turba: Finished migration
Jul  9 10:43:21 e-smith-server rc: Starting migrate-imp-to-turba:  succeeded


The only funny thing in this script is that it says /etc/e-smith/sql/init/30mysql.create.horde.sql does not exist.  ls -la on /etc/e-smith/sql/init/ shows that 30mysql.create.horde.sql is a link to /home/httpd/horde/scripts/database/mysql_create.sql.  It turns out the file it points to does not exist but there is a file called mysql_create.sql.bootstrap in that directory.  I suspect this is the file the 30mysql.create.horde.sql should link to.  Should I try editing the link to point to 30mysql.create.horde.sql.bootstrap, re-enable migrate-imp-to-turba (it said it was disabled in the script above) and reboot?  If so, how do I edit the link? (I'm learning but still not a Linux expert).

I also tried to access e-mail via webmail.  I am now getting a different error message.  I tried using three different folder-prefix settings: "Mail/", "/" and "" - all without the quotes.  I did this because devinfo-mitel-procmail-imaprootpatch-0.1-2.noarch.rpm from Stephen Noble's site changed the location of mailboxes to $home/ from $home/Mail/ to allow Webmail and Outlook Express to see the same user folders.  The new error message Webmail now generates is:


IMP Maintenance Operations - Confirmation  
 
Warning! IMP is ready to perform the maintenance operations checked below.
Check the box for any operation(s) you want to perform at this time.  
 
A fatal error has occurred
object(db_error)(7) {
  ["error_message_prefix"]=>
  string(0) ""
  ["mode"]=>
  int(1)
  ["level"]=>
  int(1024)
  ["code"]=>
  int(-18)
  ["message"]=>
  string(23) "DB Error: no such table"
  ["userinfo"]=>
  string(470) "update horde_prefs set pref_value = 'a:1:{i:0;a:9:{s:2:\"id\";s:16:\"Default Identity\";s:8:\"fullname\";s:0:\"\";s:9:\"from_addr\";s:0:\"\";s:12:\"replyto_addr\";s:0:\"\";s:9:\"signature\";s:0:\"\";s:9:\"sig_first\";i:0;s:10:\"sig_dashes\";i:0;s:14:\"save_sent-mail\";N;s:16:\"sent_mail_folder\";s:9:\"sent-mail\";}}' where pref_uid = 'tchogan@castlewoodfdn.org' and pref_name = 'identities' and pref_scope = 'horde' [nativecode=Table 'horde.horde_prefs' doesn't exist]"
  ["callback"]=>
  NULL

Any advice would be greatly appreciated.

Dan Brown

Re: need help WebMail problem
« Reply #7 on: July 10, 2002, 06:43:18 PM »
Tim, not quite sure what's going on; looks like Mitel's done some odd things with the horde mysql scripts.  The problem is that the horde databases haven't been created.  To create them, log in as root and do this:

# cd /home/httpd/horde/scripts/database/
# mysql < mysql_create.sql.bootstrap
# mysqladmin reload

Tim Hogan

Re: need help WebMail problem
« Reply #8 on: July 11, 2002, 01:08:26 AM »
Dan Brown wrote:
>
> Tim, not quite sure what's going on; looks like Mitel's done
> some odd things with the horde mysql scripts.  The problem is
> that the horde databases haven't been created.  To create
> them, log in as root and do this:
>
> # cd /home/httpd/horde/scripts/database/
> # mysql < mysql_create.sql.bootstrap
> # mysqladmin reload

Directory is /home/httpd/html/horde/scripts/database/

It appears the database already exists but I still can't use webmail.
 # mysql < mysql_create.sql.bootstrap produced:
ERROR 1007 at line 4: Can't create database 'horde'. Database exists

Thanks,
Tim Hogan

Dan Brown

Re: need help WebMail problem
« Reply #9 on: July 11, 2002, 03:33:24 AM »
Curiouser and curiouser...

OK, try this:

# mysql horde
mysql> show tables;

what do you get?

Tim Hogan

Re: need help WebMail problem
« Reply #10 on: July 11, 2002, 08:54:28 AM »
Dan Brown wrote:
>
> Curiouser and curiouser...
>
> OK, try this:
>
> # mysql horde
> mysql> show tables;
>
> what do you get?

Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 989 to server version: 3.23.41

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> show tables;
+-----------------+
| Tables_in_horde |
+-----------------+
| active_sessions |
| imp_addr        |
| imp_pref        |
| turba_objects   |
+-----------------+
4 rows in set (0.00 sec)

Tim Hogan

Dan Brown

Re: need help WebMail problem
« Reply #11 on: July 11, 2002, 04:51:28 PM »
# cd /home/httpd/html/horde/scripts/db/
# mysql < mysql_create.sql

Tim Hogan

Re: need help WebMail problem
« Reply #12 on: July 11, 2002, 05:37:13 PM »
Dan Brown wrote:
>
> # cd /home/httpd/html/horde/scripts/db/
> # mysql < mysql_create.sql

That did it!

Thanks a million,
Tim Hogan

Mark Hazeleger

Re: need help WebMail problem
« Reply #13 on: July 13, 2002, 08:24:04 PM »
Hi all,

I just upgraded from 5.1.2 to 5.5 and I get the same problem as Tim, except  on "show tables" my list looks a bit different:

mysql> show tables;
+-----------------------------+
| Tables_in_horde             |
+-----------------------------+
| active_sessions             |
| horde_categories            |
| horde_categories_categories |
| horde_prefs                 |
| horde_users                 |
| imp_addr                    |
| imp_pref                    |
| turba_objects               |
+-----------------------------+
8 rows in set (0.01 sec)

Executing the suggested commands led to:

[root@styx database]# cd /home/httpd/html/horde/scripts/db/    
[root@styx db]# mysql < mysql_create.sql
ERROR 1061 at line 74: Duplicate key name 'category_category_name_idx'

And still no webmail! Does anyone have any further suggestions?

Thanks,

Mark Hazeleger

Mark Hazeleger

Re: need help WebMail problem
« Reply #14 on: July 15, 2002, 06:15:36 PM »
Hi all,

Here's a followup on my previous post. When I udated from 5.1.2 to 5.5 I used the 5.1.2. configuration diskette to boot, after which my system was updated to 5.5 and the Webmail error occurred. I just decide to do a clean 5.5 install, do the initial configuration manually (these basic settings remain unchanged from previous versions). Then I restored the fresh desktop backup (made with the 5.5 upgrae instalation) and rebooted. Et voila, webmail is back in business. On the reboot after restoring the backup, I noticed that "conversion from imp to turba" is now disabled.

I'm still not sure what has happened, but at least I got my system running again.

To me, it look as if the upgrade path still needs some tinkering to become as foolproof as the rest of the system.

Thanks,

Mark