Forum OpenACS Q&A: error at admin page during configuration

My configuration of openACS was smooth until
trying to "Make myself a Sysadmin" after
adding myself as a user successfully.

The admin page http://192.168.188.2:8080/admin/ gives:

Server Error
The server encountered a configuration or operating system error while
attempting to satisfy your request.

What have I done wrong? Looked at server.log (with debug on),
but can't have a clue.
Your help will be greatly appreciated.

John

Collapse
Posted by Dan Wickstrom on
There should be a more detailed error message in the log file when you try to access this page.  Please retry accessing /admin and post the error message from the log file here.
Collapse
Posted by John XING on
Here is the full error log (sorry for the length):
[28/Aug/2000:22:07:20][837.4101][-conn0-] Notice: starting: waiting for connecti
ons
[28/Aug/2000:22:07:22][837.4101][-conn0-] Notice: nsd.db: opening:  postgres:loc
alhost::openacs
[28/Aug/2000:22:07:22][837.4101][-conn0-] Notice: Opening openacs on localhost
[28/Aug/2000:22:07:22][837.4101][-conn0-] Notice: Ns_PgOpenDb(postgres):  Openne
d connection to localhost::openacs.
[28/Aug/2000:22:07:22][837.4101][-conn0-] Error: Ns_PgExec: result status: 7 mes
sage: ERROR:  More than one tuple returned by a subselect used as an expression.

[28/Aug/2000:22:07:22][837.4101][-conn0-] Error: nsd.db: error(localhost::openac
s, ERROR:  More than one tuple returned by a subselect used as an expression.
): 
    select p1.item_id, 
           p1.label, 
           p1.sort_key, 
           coalesce(p1.url,'#') as url,
           (select count(*)
            from   pdm_menu_items p2
            where  p2.sort_key like substr(p1.sort_key,0,length(p1.sort_key))||'
__') as number_of_children,
           (select p3.label
            from   pdm_menu_items p3
            where  menu_id = 1
            and    p3.sort_key like substr(p1.sort_key,0, length(p1.sort_key)-2)
) as parent_label
    from   pdm_menu_items p1 
    where  menu_id = 1 
    order by p1.sort_key
[28/Aug/2000:22:07:22][837.4101][-conn0-] Error: nsd.tcl: Database operation "se
lect" failed (exception NSDB, "Query was not a statement returning rows.")
Database operation "select" failed (exception NSDB, "Query was not a statement r
eturning rows.")
    while executing
"ns_db select $db "
    select p1.item_id, 
           p1.label, 
           p1.sort_key, 
           coalesce(p1.url,'#') as url,
           (select c..."
    (procedure "ad_pdm" line 96)
    invoked from within
"ad_pdm "admin" 5 5 $db"
    (procedure "ad_admin_header" line 4)
    invoked from within
"ad_admin_header "Admin Home for [ad_system_name]""
    invoked from within
"ns_return 200 text/html "
[ad_admin_header "Admin Home for [ad_system_name]"]

[ad_system_name] Administration

[ad_context_bar_ws "Admin Hom..." (file "/home/nsadmin/web/server1/www/admin/index.tcl" line 9) invoked from within "source $ad_conn(file)" (procedure "ad_handle_abstract_url" line 67) invoked from within "ad_handle_abstract_url cns0 {}"
Collapse
Posted by Dan Wickstrom on
Looks like a bug in the pull-down menus. Try setting the following in your config. file:
ns_section ns/server/${server}/acs/pdm

	# Flag to display the administration menu bar
	ns_param MenuOnAdminPagesP 0

	# Flag to display the default menu bar on non-/admin pages
	ns_param MenuOnUserPagesP 0

This should make the problem go away. If so, please make an entry in the sdm about this problem.
Collapse
Posted by John XING on
Hi, Dan, the problem is gone after applying your suggestion.
Thanks a lot. As for sdm, should I info the author of installation Guide or submit a patch?

John

Collapse
Posted by Dan Wickstrom on
John,

I went ahead and entered it into the SDM.  If you have a patch to fix the pull-down menu problem, go ahead and submit it.