Forum OpenACS Development: Install error on head
...
Installed ACS Subsite, version 4.6.1b. Package enabled. Installed Skin, version 4.5. Skin instantiated as skin. Package enabled. Completing Install sequence. CREATE CREATE CREATE id ---- (0 rows) UPDATE 0 DROP DROP DROP ... [12/Jan/2003:08:34:48][9015.114696][-conn4-] Error: Error sourcing /web/dotlrn-test/packages/acs-bootstrap-installer/installer/packages-install.tcl: psql:acs-install.sql:279: ERROR: apm_packages_package_key_fk referential integrity violation - key referenced from apm_packages not found in apm_package_types psql:acs-install.sql:286: ERROR: ExecAppend: Fail to add null value in not null attribute object_id
<pre>
invoked from within
"db_source_sql_file -callback apm_ns_write_callback acs-install.sql"
invoked from within
"if { ![ad_acs_admin_node] } {
ns_write " <p><li> Completing Install sequence.<p>
<blockquote><pre>"
cd [file join [acs_root_dir] packages..."
(file "/web/dotlrn-test/packages/acs-bootstrap-installer/installer/packages-install.tcl" line 34)
invoked from within
"source $__file "
</pre>
I will post the error I got if this post will go through.
Anyway, here is the error that part throws:
Request Error can't read "1": no such variable (reading value of variable to increment) invoked from within "incr $output(blockquote) -1" (procedure "ad_html_to_text" line 203) invoked from within "ad_html_to_text $message(content)" (procedure "do_notifications" line 28) invoked from within "do_notifications -message_id $message_id" invoked from within "if {[info exists message(state)] && [string equal $message(state) approved]} { do_notifications -message_id $message_id }" ("uplevel" body line 5) invoked from within "uplevel 1 $transaction_code " (procedure "db_transaction" line 1) invoked from within "db_transaction { set message_id [package_instantiate_object -extra_vars $extra_vars forums_message] get -message_id $message_..." (procedure "forum::message::new" line 13) invoked from within "forum::message::new -forum_id $forum_id -message_id $message_id -parent_id $parent_id -subject $subject -content $content -html_p $html_p" invoked from within "if {[form is_valid message]} { form get_values message message_id forum_id parent_id subject content html_p confirm_p subscribe_p if {!$conf..." ("uplevel" body line 59) invoked from within "uplevel { ad_page_contract { Form to create message and insert it @author Ben Adida (ben@openforce.net) @creation-date 2002-0..." (procedure "code::tcl::/web/openacs.org-dev/packages/forums/www/message-..." line 2) invoked from within "code::tcl::$__adp_stub" invoked from within "if { [file exists $__adp_stub.tcl] } { # ensure that data source preparation procedure exists and is up-to-date adp_init tcl $__adp_stub ..." ("uplevel" body line 3) invoked from within "uplevel { if { [file exists $__adp_stub.tcl] } { # ensure that data source preparation procedure exists and is up-to-date adp_init t..." (procedure "adp_prepare" line 2) invoked from within "adp_prepare " (procedure "template::adp_parse" line 30) invoked from within "template::adp_parse [file root [ad_conn file]] {}" (procedure "adp_parse_ad_conn_file" line 7) invoked from within "$handler" ("uplevel" body line 2) invoked from within "uplevel $code" invoked from within "ad_try { $handler } ad_script_abort val { # do nothing }" invoked from within "rp_serve_concrete_file [ad_conn file]" (procedure "rp_serve_abstract_file" line 60) invoked from within "rp_serve_abstract_file "$root/$path"" ("uplevel" body line 2) invoked from within "uplevel $code" invoked from within "ad_try { rp_serve_abstract_file "$root/$path" set tcl_url2file([ad_conn url]) [ad_conn file] set tcl_url2path_info([ad_conn url]) [ad_conn path_inf..."
I tried 4.7 on 7.3.1 and it gives the same error the as on 7.2.3, of course, but it returns a slightly different error message (which it is too late at night for me to attempt to debug now).
Here is the new message:
ERROR: apm_packages_package_key_fk referential integrity violation - key referenced from apm_packages not found in apm_package_types ERROR: ExecInsert: Fail to add null value in not null attribute object_id WARNING: Error occurred while executing PL/pgSQL function acs_permission__grant_permission WARNING: line 17 at SQL statementCould this have to do with the infamous PG bug regarding foreign key constraints and transactions inside transactions (or somthing like that - can't remember exactly what it was)?
" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."acs_objects" x WHERE "object_id" = $1 FOR UPDATE OF x LOG: query: insert into acs_object_context_index (object_id, ancestor_id, n_generations) values ( $1 , $2 , 0) LOG: query: SELECT $1 is not null and $2 = 't' LOG: query: insert into acs_object_context_index (object_id, ancestor_id, n_generations) select $1 as object_id, ancestor_id, n_generations + 1 as n_generations from acs_object_context_index where object_id = $2 LOG: query: SELECT 1 FROM ONLY "public"."apm_packages" x WHERE "package_id" = $1 FOR UPDATE OF x LOG: query: SELECT $1 != 0 LOG: query: insert into acs_object_context_index (object_id, ancestor_id, n_generations) values ( $1 , 0, 1) LOG: query: SELECT 1 FROM ONLY "public"."acs_objects" x WHERE "object_id" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."apm_packages" x WHERE "package_id" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."apm_parameters" x WHERE "parameter_id" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."acs_objects" x WHERE "object_id" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."acs_objects" x WHERE "object_id" = $1 FOR UPDATE OF x FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."acs_objects" x WHERE "object_id" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."parties" x WHERE "party_id" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."acs_privileges" x WHERE "privilege" = $1 FOR UPDATE OF x LOG: query: SELECT 1 FROM ONLY "public"."site_nodes" x WHERE "node_id" = $1 FOR UPDATE OF x ERROR: apm_packages_package_key_fk referential integrity violation - key referenced from apm_packages not found in apm_package_types LOG: statement: select inline_0 (); DEBUG: AbortCurrentTransaction DEBUG: StartTransactionCommand LOG: statement: select id from inline_data where name = 'api_doc_id'; LOG: query: select id from inline_data where name = 'api_doc_id'; DEBUG: ProcessQuery LOG: statement: select id from inline_data where name = 'api_doc_id'; DEBUG: CommitTransactionCommand LOG: statement: select id from inline_data where name = 'api_doc_id'; DEBUG: StartTransactionCommand LOG: statement: update acs_objects set security_inherit_p = 'f' where object_id = (select id from inline_data where name = 'api_doc_id'); where object_id = (select id from inline_data where name = 'api_doc_id'); LOG: query: update acs_objects set security_inherit_p = 'f' where object_id = (select id from inline_data where name = 'api_doc_id'); DEBUG: ProcessQuery LOG: statement: update acs_objects set security_inherit_p = 'f' where object_id = (select id from inline_data where name = 'api_doc_id'); DEBUG: CommitTransactionCommand LOG: statement: update acs_objects set security_inherit_p = 'f' where object_id = (select id from inline_data where name = 'api_doc_id'); DEBUG: StartTransactionCommand LOG: statement: select inline_1 (); LOG: query: select inline_1 (); DEBUG: ProcessQuery LOG: statement: select inline_1 (); LOG: query: SELECT id from inline_data where name = 'api_doc_id' LOG: query: SELECT acs_permission__grant_permission ( $1 , acs__magic_object_id ('registered_users'), 'read' ) ERROR: ExecInsert: Fail to add null value in not null attribute object_id LOG: statement: select inline_1 (); WARNING: Error occurred while executing PL/pgSQL function acs_permission__grant_permission LOG: statement: select inline_1 (); WARNING: line 17 at SQL statement LOG: statement: select inline_1 (); DEBUG: AbortCurrentTransaction DEBUG: StartTransactionCommand LOG: statement: drop function inline_0 (); LOG: query: drop function inline_0 (); DEBUG: ProcessUtility LOG: statement: drop function inline_0 (); DEBUG: CommitTransactionCommand LOG: statement: drop function inline_0 (); DEBUG: StartTransactionCommand LOG: statement: drop function inline_1 (); LOG: query: drop function inline_1 (); DEBUG: ProcessUtility LOG: statement: drop function inline_1 (); DEBUG: CommitTransactionCommand LOG: statement: drop function inline_1 (); DEBUG: StartTransactionCommand LOG: statement: drop table inline_data; LOG: query: drop table inline_data; DEBUG: ProcessUtility LOG: statement: drop table inline_data; DEBUG: Drop auto-cascades to toast table pg_toast.pg_toast_28537 LOG: statement: drop table inline_data; DEBUG: Drop auto-cascades to type pg_toast.pg_toast_28537 LOG: statement: drop table inline_data; DEBUG: Drop auto-cascades to index pg_toast.pg_toast_28537_index LOG: statement: drop table inline_data; DEBUG: Drop auto-cascades to type inline_data LOG: statement: drop table inline_data; DEBUG: CommitTransactionCommand LOG: statement: drop table inline_data; DEBUG: proc_exit(0) DEBUG: shmem_exit(0) DEBUG: exit(0) DEBUG: reaping dead processes DEBUG: child process (pid 29804) exited with exit code 0 DEBUG: proc_exit(0) DEBUG: shmem_exit(0) DEBUG: exit(0) DEBUG: reaping dead processes DEBUG: child process (pid 29808) exited with exit code 0If someone can see what is wrong that's good, otherwise I will try some more in the weekend.
/Lars
After importing the latest OpenACS CVS HEAD to my local HEAD checkout I get an error when visiting /acs-admin/apm/packages-install
:
[15/Jan/2003:21:03:44][23605.49159][-conn3-] Error: GET http://localhost:8002/acs-admin/apm/packages-install? referred by "http://localhost:8002/acs-admin/apm/" Invalid file type "message_catalog" while executing "error "Invalid file type \"$type\""" (procedure "apm_read_package_info_file" line 151) invoked from within "apm_read_package_info_file $spec_file" ("foreach" body line 2) invoked from within "foreach spec_file $all_spec_files { array set version [apm_read_package_info_file $spec_file] set version_name $version(name) set package_..." ("uplevel" body line 37) invoked from within "uplevel { ad_page_contract { Select, dependency check, install and enable packages. @author Bryan Quinn (bquinn@arsdigita.com) @c..." (procedure "code::tcl::/home/efnisvaki/web/efnisvaki-dev/packages/acs-ad..." line 2) [snip]
To make sure this wasn't because of some local changes I decided to set up an instance with a clean CVS HEAD checkout, but in step 4 of the OpenACS installation process I get an error when clicking the "Set System Information ->" button:
[15/Jan/2003:20:48:54][1779.24580][-conn0-] Notice: ns_getform using encoding iso8859-1 for charset iso-8859-1 [15/Jan/2003:20:48:54][1779.24580][-conn0-] Error: Ns_PgExec: result status: 7 message: ERROR: -20000: The specified package 641 AND/OR parameter RestrictToSSL do not exist in the system [15/Jan/2003:20:48:54][1779.24580][-conn0-] Error: Error sourcing /home/efnisvaki/web/openacs-head/packages/acs-bootstrap-installer/installer/site-info-2.tcl: Database operation "0or1row" failed (exception NSDB, "Query was not a statement returning rows.") while executing "ns_pg_bind 0or1row nsdb0 { select apm__set_value( :package_id, :parameter, :value ..." ("uplevel" body line 1) invoked from within "uplevel $ulevel [list ns_pg_bind $type $db $sql" invoked from within "db_exec 0or1row $db $full_statement_name $sql" invoked from within "if {[regexp -nocase -- {^\s*select} $test_sql match]} { db_qd_log QDDebug "PLPGSQL: bypassed anon function" set selection [db_..." ("uplevel" body line 6) invoked from within "uplevel 1 $code_block " invoked from within "db_with_handle db { # plsql calls that are simple selects bypass the plpgsql # mechanism for creating anonymous functions (OpenACS - ..." (procedure "db_exec_plsql" line 13) invoked from within "db_exec_plsql set_parameter_value {}" (procedure "parameter::set_value" line 7) invoked from within "parameter::set_value -package_id $package_id -parameter $name -value $set" (procedure "ad_parameter" line 4) invoked from within "ad_parameter -set "acs-admin/*" -package_id $main_site_id RestrictToSSL" (file "/home/efnisvaki/web/openacs-head/packages/acs-bootstrap-installer/installer/site-info-2.tcl" line 45) invoked from within "source $__file "
Is this problem known? Is it maybe related to the APM auto-mount feature work?
I'm using PostgreSQL 7.2.3
TIA