6.0.0-beta1
7/4/25

[#3676] public_to_horde_share script hangs
Summary public_to_horde_share script hangs
Queue Turba
Queue Version 2.1
Type Bug
State Resolved
Priority 1. Low
Owners mrubinsk (at) horde (dot) org
Requester bjoern.koester (at) mediata (dot) net
Created 03/23/2006 (7043 days ago)
Due
Updated 11/29/2006 (6792 days ago)
Assigned 11/28/2006 (6793 days ago)
Resolved 11/29/2006 (6792 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
11/29/2006 12:32:09 AM Chuck Hagenbuch State ⇒ Resolved
 
11/28/2006 11:26:07 PM Michael Rubinsky Comment #23 Reply to this comment
I don't see any problem with that patch - does the call really need
to be silenced though?
No, I guess not...I was just being a lemming since previous call was.   
I removed it from both calls and commited...
11/28/2006 07:44:11 PM Chuck Hagenbuch Comment #22 Reply to this comment
I don't see any problem with that patch - does the call really need to 
be silenced though?
11/28/2006 06:56:38 PM Michael Rubinsky Comment #21
New Attachment: cli.patch Download
Reply to this comment
Not really convinced this is a problem with the public_to_horde_share 
script.  Adding a ob_flush() call for when we are not using a $choices 
array (as in the attached patch against HEAD) in the 
Horde_CLI::prompt() method seems to fix this issue....would like 
someone to verify this before I commit though...
11/28/2006 10:08:52 AM Jan Schneider State ⇒ Assigned
 
11/28/2006 07:37:48 AM yvon (dot) lafaille (at) limousin (dot) iufm (dot) fr Comment #20 Reply to this comment
This bug disappears with horde-3.1.1, turba-2.1.1.

It is here again with horde-3.1.3 and turba-2.1.3.

It is why this bug has to be re-opened.

The bad behavior of  the script "public_to_horde_share.php" is the 
same than before.



root@****:/usr/share/horde/turba/scripts/upgrades# ./public_to_horde_share.php

This script will turn all entries in the SQL address book into a 
globally shared address book.

Make sure you read the script comments and be sure you know what you 
are doing.

Are you sure you want to do this?

     (0) no

     (1) yes



Type your choice: 1



It hangs here ....



I have tested with the same command on the same machine with 
horde-3.1.1 and turba-2.1.1, the script does not hang.








04/13/2006 02:15:44 PM Michael Rubinsky State ⇒ Resolved
 
04/12/2006 09:24:04 AM bjoern (dot) koester (at) mediata (dot) net Comment #19 Reply to this comment
I've fixed a few other bugs with this script, can someone who had
this problem verify that it is still happening?

A diff from Turba 2.1:
http://cvs.horde.org/diff.php/turba/scripts/upgrades/public_to_horde_share.php?r1=1.3.2.2&r2=1.3.2.4&ty=u
This works for me, thanks:-)

Björn
04/12/2006 04:49:07 AM Michael Rubinsky Comment #18 Reply to this comment
I've fixed a few other bugs with this script, can someone who had this 
problem verify that it is still happening?



A diff from Turba 2.1:

http://cvs.horde.org/diff.php/turba/scripts/upgrades/public_to_horde_share.php?r1=1.3.2.2&r2=1.3.2.4&ty=u
04/12/2006 01:39:17 AM Michael Rubinsky Comment #17 Reply to this comment
Here's another version posting from the turba list - guess it's not a 
4.3.x error.  Any chance this can be some kind of platform specific or 
Zend accelerator error?  Try as I might, I cannot get this script to 
hang on a number of seperate as well as virtual machine setups.
output of "/usr/local/bin/php -v" or "php -v"?
PHP 4.4.1 (cli) (built: Dec 10 2005 01:25:23)

Copyright (c) 1997-2004 The PHP Group

Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
04/12/2006 01:39:02 AM Michael Rubinsky Comment #16 Reply to this comment
Here's another version posting from the turba list - guess it's not a 
4.3.x error.  Any chance this can be some kind of platform specific or 
Zend accelerator error?  Try as I might, I cannot get this script to 
hang on a number of seperate as well as virtual machine setups.
04/01/2006 07:07:01 AM mseltser (at) soroki (dot) com Comment #15 Reply to this comment
Are you saying that there might be a bug in 4.3.10 version?



PHP 4.3.10 (cli) (built: Mar 29 2005 11:41:05)

Copyright (c) 1997-2004 The PHP Group

Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies


04/01/2006 01:05:27 AM Michael Rubinsky Comment #14 Reply to this comment
Works fine here on the following 3 machines/configurations



PHP 4.4.3-dev (cli) (built: Jan 26 2006 10:31:03)

Copyright (c) 1997-2006 The PHP Group

Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies



----



PHP 5.1.2 (cli) (built: Jan 25 2006 20:09:48)

Copyright (c) 1997-2006 The PHP Group

Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies



---



PHP 4.4.2 (cli) (built: Jan 24 2006 08:54:00)

Copyright (c) 1997-2006 The PHP Group

Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies

     with Zend Extension Manager v1.0.8, Copyright (c) 2003-2005, by 
Zend Technologies

     with Zend Optimizer v2.5.10, Copyright (c) 1998-2005, by Zend Technologies
03/31/2006 03:45:28 PM mseltser (at) soroki (dot) com Comment #13 Reply to this comment
All, hopefully I have a little bit more useful info on this issue.   
After disabling a few lines of code discussed earlier and rerunning 
the script, after the very first question the script is waiting for 
your input on 3 following questions:



Username of the user you would like to own the new public source.

Enter the title you would like to give to the new public source

What is the internal name of the share we are converting? [localsql]');



It appears to me that timing is somehow wrong, so if you provide 3 
answers to the questions right after the first question, the script 
will do its job of converting your shared source.



Here is a sample of that:



[root@dev upgrades]# php public_to_horde_share.php

This script will turn all entries in the SQL address book into a 
globally shared address book.

Make sure you read the script comments and be sure you know what you 
are doing.

Are you sure you want to do this?

     (0) no

     (1) yes



Type your choice: 1

horde_user

Test AddressBook

abc123



Username of the user you would like to own the new public source.

Enter the title you would like to give to the new public source.

What is the internal name of the share we are converting? [localsql] [ 
   OK   ] Created new Horde_Share object for the shared address book.



Michael
03/31/2006 08:43:50 AM bjoern (dot) koester (at) mediata (dot) net Comment #12 Reply to this comment
System 1

medserv04:# /usr/local/php/bin/php -v" or "php -v

PHP 4.3.11 (cli) (built: Feb 14 2006 16:06:09)

Copyright (c) 1997-2004 The PHP Group

Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies

     with Zend Extension Manager v1.0.9, Copyright (c) 2003-2006, by 
Zend Technologies

     with Zend Optimizer v2.6.2, Copyright (c) 1998-2006, by Zend Technologies

     with <b>DISABLED</b> Zend Performance Suite v4.0.2, Copyright (c) 
1999-2004, by The Accelerator presently supports only Apache, ISAPI 
and FastCGI SAPIs





System 2

medserv05:# /usr/local/php/bin/php -v" or "php -v

PHP 4.4.2 (cli) (built: Mar 13 2006 11:21:46)

Copyright (c) 1997-2006 The PHP Group

Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies

     with Zend Extension Manager v1.0.9, Copyright (c) 2003-2006, by 
Zend Technologies

     with Zend Optimizer v2.6.2, Copyright (c) 1998-2006, by Zend Technologies

     with <b>DISABLED</b> Zend Download Server v1.0.6, Copyright (c) 
2003-2005, by Zend Technologies

     with <b>DISABLED</b> Zend Platform v2.1.2, Copyright (c) 
1999-2006, by The Zend Platform presently supports only Apache, ISAPI 
and FastCGI SAPIs

     with Zend Debugger v5.1.0, Copyright (c) 1999-2006, by Zend Technologies

     with java wrapper v1.0, Copyright (c) 2004-2005, by Zend Technologies

     with mod_cluster wrapper v1.0, Copyright (c) 2004-2005, by Zend 
Technologies


03/31/2006 08:23:49 AM Jan Schneider Comment #11
State ⇒ Feedback
Reply to this comment
Which PHP SAPI versions do you have, i.e. what is the output of 
"/usr/local/bin/php -v" or "php -v"?
03/31/2006 07:04:16 AM bjoern (dot) koester (at) mediata (dot) net Comment #10 Reply to this comment
I have the same problems. I tried the patcched version of the script 
but beside of the php errors there is no difference. It hangs.



I use the internal application imp as user backend.



comment out the the does not help either:-(
03/30/2006 07:23:36 PM Michael Rubinsky Comment #9 Reply to this comment
No changes in behavior...
Michael
I'm at a loss here.  With those lines commented out, there is nothing 
happening between the time that you answer the first question and 
being asked the second.  Please try getting a fresh, up-to-date copy 
of the file and try again.



http://cvs.horde.org/co.php?r=1.3.2.3&p=1&f=turba%2Fscripts%2Fupgrades%2Fpublic_to_horde_share.php



If this still does not work, you will have to set some breakpoints / 
var_dumps to find out where it hangs...


03/30/2006 06:46:37 PM mseltser (at) soroki (dot) com Comment #8 Reply to this comment
The patch has been applied using the following command:



[root@dev upgrades]# patch -p0 < patch_public_to_horde_share

patching file public_to_horde_share.php

Hunk #3 succeeded at 30 with fuzz 2.



Then, I've disabled the following lines:



// Find out what our Auth driver will let us do and

// get the list of all users if we can.

//$authDriver = $conf['auth']['driver'];

//#$auth = &Auth::singleton($authDriver);

//if ($auth->hasCapability('list')) {

//    $users = $auth->listUsers();

//}



No changes in behavior...

Michael
03/30/2006 05:37:29 PM Michael Rubinsky Comment #7 Reply to this comment
Michael,
I have disabled lines 51-55 which included the following 3 lines:

if (!$sure) {
     exit;
}
Those are not correct. Did you apply the patch mentioned earlier in 
the ticket?  I'm asking to comment out the lines that grab the 
userlist  - it is the block right after the code *you* commented out.   
The comments say something like - "See what are Auth driver can do and 
grab the userlist..."

[Show Quoted Text - 14 lines]
03/30/2006 04:59:53 PM mseltser (at) soroki (dot) com Comment #6 Reply to this comment
Michael,

I have disabled lines 51-55 which included the following 3 lines:



if (!$sure) {

     exit;

}



then, I reran the script but see no difference:



[root@dev upgrades]# php public_to_horde_share.php

This script will turn all entries in the SQL address book into a 
globally shared address book.

Make sure you read the script comments and be sure you know what you 
are doing.

Are you sure you want to do this?

     (0) no

     (1) yes



Type your choice: 1



hangs....
03/30/2006 03:45:38 PM Michael Rubinsky Comment #5 Reply to this comment
I am using MySQL authentication backend.  Please let me know if you
need me to provide you with any config files

Thanks,
Michael
Try commenting out lines 51-55 - the stanza that grabs the 
userlist...it's only there to verify you enter a correct username in 
the following question....




03/30/2006 03:37:17 PM mseltser (at) soroki (dot) com Comment #4 Reply to this comment
I am using MySQL authentication backend.  Please let me know if you 
need me to provide you with any config files



Thanks,

Michael
03/30/2006 03:29:23 PM Michael Rubinsky Comment #3 Reply to this comment
public_to_horde_share script hangs after answering the first question.
maybe it hangs on getting the whole userlist from the horde application.

there is a patch fopr getting rid of the php errors while first
starting the script:
http://cvs.horde.org/diff.php/turba/scripts/upgrades/public_to_horde_share.php?r1=1.3.2.2&r2=1.3.2.3&ty=u
I am unable to reproduce this....what authentication backend are you using?


03/29/2006 07:01:22 AM mseltser (at) soroki (dot) com Comment #2 Reply to this comment
Hello, I was wondering if there is any work around while this bug is 
being worked on that someone could suggest?



Thanks,

Regards,

Michael
03/23/2006 09:27:31 PM Chuck Hagenbuch Assigned to Michael Rubinsky
State ⇒ Assigned
 
03/23/2006 11:57:02 AM bjoern (dot) koester (at) mediata (dot) net Comment #1
Priority ⇒ 1. Low
State ⇒ Unconfirmed
Queue ⇒ Turba
Type ⇒ Bug
Summary ⇒ public_to_horde_share script hangs
Reply to this comment
public_to_horde_share script hangs after answering the first question.

maybe it hangs on getting the whole userlist from the horde application.



there is a patch fopr getting rid of the php errors while first 
starting the script:

http://cvs.horde.org/diff.php/turba/scripts/upgrades/public_to_horde_share.php?r1=1.3.2.2&r2=1.3.2.3&ty=u

Saved Queries