Forum OpenACS Q&A: Problem with OpenFTS

Collapse
Posted by Richard Hamilton on
I have tried to install OpenACS 4.5 with OpenFTS but seem to have run
into difficulties. I am posting this in the hope that the request
error that I get after mounting the OpenFTS application rings some
bells with someone.

This is the error that I get after selecting the button "Initialising
OpenFTS driver"

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Request Error

invalid command name "Search::OpenFTS::Index::init"
    while executing
"Search::OpenFTS::Index::init opt"
    invoked from within
"array set idx [Search::OpenFTS::Index::init opt]"
    ("uplevel" body line 35)
    invoked from within
"uplevel {
          ad_page_contract {

    Initialize OpenFTS

    @author Neophytos Demetriou

} {
    table_name
    table_id
    dict
    parser
    ..."
    (procedure
"code::tcl::/web/server3/packages/openfts-driver/www/admin/in..." 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 3)
    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..."

Any help gratefully received.

Kind regards
Richard

Collapse
Posted by Richard Hamilton on
Sorry about the formatting. Here is the error report as was.Regs, R.
 Request Error

invalid command name "Search::OpenFTS::Index::init"
    while executing
"Search::OpenFTS::Index::init opt"
    invoked from within
"array set idx [Search::OpenFTS::Index::init opt]"
    ("uplevel" body line 35)
    invoked from within
"uplevel {
    	  ad_page_contract {

    Initialize OpenFTS

    @author Neophytos Demetriou

} {
    table_name
    table_id
    dict
    parser
    ..."
    (procedure "code::tcl::/web/server3/packages/openfts-driver/www/admin/in..." 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 3)
    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..."
Collapse
Posted by Gilbert Wong on
Go to the site map (/admin/site-map) and change the path for the OpenFTS-TCL search directory  (ie openfts_tcl_src_path parameter) to where you unpacked the openfts tcl source.
Collapse
Posted by Benjamin Bytheway on
If you want to get around having to keep the OpenFTS source, you can copy all of the fts_*.tcl to your aolserver tcl library.  If I remember correctly, that was the only reason for the OpenFTS source path in the Search Package.
Collapse
Posted by Richard Hamilton on
Have tried changing the path to the source files but I had entered this before and could not see any reason why the libraries should be invisible to nsadmin :  /usr/local/src/Search-OpenFTS-tcl-0.2

Also tried copying the fts_*.tcl files to /web/server3/packages/acs-tcl/tcl but no luck with this either.

Still getting the same error. AOLServer log shows that the nsfts.so driver is loading into AOLServer just fine.

I have checked the file permissions in the source code directory and all are owned by nsadmin and not executable by any other user.

Any other ideas anyone?

Regards
Richard

Collapse
Posted by Neophytos Demetriou on
Richard, you can either change the ownership of /usr/local/src/Search-OpenFTS-tcl-0.2
with chown or after you move the libraries rename them to *-procs.tcl so that they will be loaded when bootstrapping. I suggest that you move these files under openfts-driver/tcl/ rather than under acs-tcl/tcl/.
Collapse
Posted by Richard Hamilton on
Neophytos,
Thank you very much for your reply. I tried this several times initially, restarting AOL Server each time but had no success. The next time I switched on the power however it worked - and it looks great. Have since read the docs on the Package Manager and now understand the structure and naming convention. Thank you for taking the time.

Regards
Richard