HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Feedback on Ubuntu 10.04 load of Sphinxsearch from Peregrine.

peregrineperegrine MVP
edited August 2012 in Feedback

I started a new discussion post, based on your message here

thx. I read your answers, and

I've used the latest version available through ubuntu 10.04 which is
sphinxsearch 0.9.8.1-2 (not compatible with your plugin).

apt-get and synaptic package manager Ubuntu 10.04 only picks up sphinxsearch 0.9.8.1-2
the package distributions can be woefully outdated depending on the repository. you could (pull a more updated version off an untrusted launchpad ppa not for ubuntu distro ) I'm not ready to upgrade the OS version, so ..

I am going straight to this link for the 2.05 .deb build

http://sphinxsearch.com/downloads/release/

where there are releases that are built already.

Your distribution of sphinx source (requires mysql-dev++ headers to be installed) to successfully configure and a compiler (e.g. g++) to make it.

I 'm pulling down the .deb release and I'll let you know - provided you want feedback for improvement (or complaints as some people call them).

I do like the demo you have, and the installation plugin looks like a herculean effort to design and build for all linux variants, and versions.

I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

Comments

  • mcu_hqmcu_hq ✭✭✭

    I 'm pulling down the .deb release and I'll let you know - provided you want feedback for improvement (or complaints as some people call them).

    yes, of course..it is what makes software better.

    installation plugin looks like a herculean effort to design and build for all linux variants, and versions.

    Not really, it should work on most linux variants just by nature of the commands. I didn't try anything too fancy in that aspect.

    That is weird....I would think that Ubuntu has their repo up-to-date. I've tested this with 2.0.4 as well with no problems. The sql_fields_string is showstopper obviously, but you may get away with other older versions that support this that are not quite >v2.0.4.

    If you have access to your server and can configure sphinx in the first place, I think you have a great chance of success. If I were you, I would try the built in installer first since your package manager does not have the latest. Maybe @Gillingham can pitch in on how he got the latest through apt-get

  • peregrineperegrine MVP
    edited August 2012

    I got it working mcu_hq - here's the problems along the way if you are interested.

    
    I used the sphinx.conf and added the diffs back in.
    
    got the .deb distribution. It was faster than loading a new compiler and the mysql headers to configure and make.  The brunt of the problem was getting a suitable version of sphinx  to work with 10.04 that was compatible with your plugin.  I preferred to use the one in package manager rather than compiling a new one (making it is easier on software upgrades and deletions sometimes)
    
    
    
    
      That is weird....I would think that Ubuntu has their repo up-to-date.
    
    
        - actually its pretty common.  ubuntu 10.04 is an older version but still supported.  I don't know if later versions have upgraded packages of sphinx.
        
        http://serverfault.com/questions/385128/how-do-i-install-the-latest-version-of-sphinx-seach-in-apt-get
        
        different versions of ubuntu - do indeed respond differently to an apt-get :)
        
        
        
        then I blew away your plugin and reinstalled it.
        
        some of the issues I had on ubuntu and your plugin now are the process still can't be killed through the plugin.
        
        when the searchd process is spawned with a -nodetach flag  which causes the process to respawned automatically after you kill pid
        the only way to kill the process and the spawning is with this command
        
        stop sphinxsearch
        
        odd but true (you can believe me or not  :).  I'll have to check to get rid of that on startup if it continues.
        
      
        
        some other errors along the way.  in the plugin dashboard settings.
        
        sh: Not: not found
        
        Attempting to stop searchd, try to run this command manually in Terminal:
        Not Detected --config Not Detected --stop
        
        at directory:
        /
        
        Try running it with sudo if it doesn't work
        Terminal Output:
        
        
        
        
      

    Index and rotation seem to work.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • mcu_hqmcu_hq ✭✭✭
    edited August 2012

    EXCELLENT

    I want to compile a list of success instructions for different distros and hosts in the FAQ.

    So you are saying that you can't stop searchd? If you click on any of the buttons in the CPanel without installing sphinx properly, you are going to get senseless errors. The whole "Not Detected" is what I have saved on default.

    This is what I run to kill all instances of searchd: killall -9 searchd

    The usual start/stop searchd is:

    start:<searchd path> --config <confpath>
    stop: <searchd path> --config <confpath> --stop

    so can you search your docs with this?

  • First off - your plugin is superb and the search options and functionality are fantastic - thanks for the plugin mcu_hq.

    Now - what I encountered clarified...

    stopping and starting searchd from the plugin does not work the way things are set up. I could probably change the permissions on a bunch of directories where it writes the pid and a few other things (I wouldn't worry about this - just letting you know).

    I don't ever use CPANEL. my installation was purely local. But you are correct one error can compound into many errors.

    I just wanted to provide a solution for anyone if they have searchd running like this
    
     /usr/bin/searchd --nodetach
    
    kill, killall will NOT kill the above searchd process completely because it will respawn another one.
    
    one solution is to use
    
    <searchd path> --config <confpath> stop: <searchd path> --config <confpath> --stop
    
    and an easier solution on ubuntu is
    
     stop sphinxsearch
    
    
    Also I made two minor modifications to your plugin
    
     I changed this  (removed the & )
    
      public function Base_Render_Before($Sender) {
    
    
      I added this - I like being able to click on the Sidemenu for sphinxsearch instead of having to click settings on the plugin.
    
      public function Base_GetAppSettingsMenuItems_Handler($Sender) {
          $Menu = $Sender->EventArguments['SideMenu'];
          $Menu->AddItem('Forum', T('Forum'));
          $Menu->AddLink('Forum', T('SphinxSearch'), 'plugin/sphinxsearch', 'Garden.Settings.Manage');
       }
    

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • mcu_hqmcu_hq ✭✭✭
    edited August 2012

    Ok, I'll add that link to the admin side of things.

    The Plugin's CPanel (control panel on the bottom of the main plugin page) can't stop searchd properly if it was not started originally through the CPanel. If you started it through your distro, then the plugin can't properly close it since it was started from a different user. This is normal operation from the plugin point of view. As long as the plugin can tell that sphinx is running, then you should be fine. Can you index through the plugin cpanel?

  • mcu_hq said:
    Ok, I'll add that link to the admin side of things.

    The Plugin's CPanel (control panel on the bottom of the main plugin page) can't stop searchd properly if it was not started originally through the CPanel. If you started it through your distro, then the plugin can't properly close it since it was started from a different user.

    Yes.

    This is normal operation from the plugin point of view. As long as the plugin can tell that sphinx is running, then you should be fine. Can you index through the plugin cpanel?

    Yes. works fine

    Personally, I think it would be an improvement to the config.php
    
    1) if you moved any variables that involved these parameters out of the config.php  that involve running and are dynamic.
    
    $Configuration['Plugin']['SphinxSearch']['Uptime'] = '954';
    $Configuration['Plugin']['SphinxSearch']['TotalQueries'] = '65';
    $Configuration['Plugin']['SphinxSearch']['IndexerMainLast'] = '1344450241.7261';
    $Configuration['Plugin']['SphinxSearch']['IndexerDeltaLast'] = '1344450258.1344';
    $Configuration['Plugin']['SphinxSearch']['IndexerStatsLast'] = '1344450266.566';
    $Configuration['Plugin']['SphinxSearch']['SearchdPortStatus'] = 'Open';
    $Configuration['Plugin']['SphinxSearch']['SearchdConnections'] = '565';
    $Configuration['Plugin']['SphinxSearch']['SearchdRunning'] = TRUE;
    

    All variables that are a manipulation by the user as far as view settings etc are fine in config.php.

    But the variables listed above cause alot of updates to the config.php.

    I think should really only change with hard and fast settings changes, not dynamic on the fly changes.

    perhaps a db table or a metatable or accessory config file.

    just my opinion - I don't like to see my config.php changing so frequently as I use it to track changes that I purposefully make, not to store temporary values.

    Once again, this is my suggestion - do as you like obviously - but I think you get the gist of what I am trying to say here.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • mcu_hqmcu_hq ✭✭✭
    edited August 2012

    Ok, I agree...I'll keep it in mind for the next release. Those should only be updated in the cpanel of the plugin though....normal operation should have very writes (if any).

    Also, I remember reading somewhere of a complaint that the view settings for some of the options are greyed out. This is correct operation. The view 'simple' is merely just the discussion title so this is the only option avaliable for widgets in the sidebar.

  • peregrineperegrine MVP
    edited August 2012

    Also, I remember reading somewhere of a complaint that the view settings for some of the options are greyed out. This is correct operation. The view 'simple' is merely just the discussion title so this is the only option avaliable for widgets in the sidebar.

    could have been in one of my thousands of edits :).

    question when you change display results to simple view in image below, it works when I click go button (not in image but upper far right )

    should the same thing happen when I click the search button and view will be simple (I don't seem to see that happen).

    you have a good idea to stack up your changes before releasing new version instead of releasing new version after every change.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • mcu_hqmcu_hq ✭✭✭

    should the same thing happen when I click the search button and view will be simple

    Yea, the search button that is included in your snapshot should also then change the view to be 'simple'

  • FYI @mcu_hq - this is what I get, your results may vary. give it a try.

    It works as expected and as you say  
    
     if this is set in config.php
    $Configuration['Garden']['RewriteUrls'] = TRUE;
    

    there seems to be an issue if

    this is set in config.php
    $Configuration['Garden']['RewriteUrls'] = FALSE;

    issue

    with $Configuration['Garden']['RewriteUrls'] = FALSE;
    
    
    
    1) I enter the word "hope" in the search box from the main discussion page
    I get the results of search properly displayed
    
    the url at the top now says
    http://localhost/vanilla/index.php?p=%2Fsearch&Search=hope
    
    everything fine up to here.
    
    2) I  next click on Search directly above more options
    
    the url produced is this:
    
    http://localhost/vanilla/index.php?Search=hope&child=&forums=&or=&mem=&tag=&pg=&date=All&Checkboxes[]=titles&Checkboxes[]=WithReplies&res=Classic&match=Any
    
    
    and it goes to the main discussions page NOT the search results.
    

    once again - for me it is not important if you change this - but thought I would let you know. Let me know if you tire of me reporting issues, and I will stop the feedback as I know it gets tiresome.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • if $Configuration['Garden']['RewriteUrls'] = FALSE;
    
    http://localhost/vanilla/index.php?Search=hope&child=&forums=&or=&mem=&tag=&pg=&date=All&Checkboxes[]=titles&Checkboxes[]=WithReplies&res=Classic&match=Any
    
    
    needs to be changed to 
    
    http://localhost/vanilla/index.php?p=/search&Search=hope&child=&forums=&or=&mem=&tag=&pg=&date=All&Checkboxes[]=titles&Checkboxes[]=WithReplies&res=Classic&match=Any
    

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • @mcu_hq

    how many hours do you think you spent developing and troubleshooting this plugin? I don't think most non-developers understand how much time is spent on developing a complex plugin.

    How many hours have you also spent personally helping individuals to get the plugin on their site?

    my questions are to shed some light on the "volunteer time" developers provide to the community when they write plugins.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • mcu_hqmcu_hq ✭✭✭
    edited September 2012

    This one took very long....I would say 3-4 months at the very least. I am still troubleshooting some things with very large data sets that I cannot replicate locally because of the data involved. That includes normal life interruptions, hobbies, travel, etc. so it is hard to put a schedule on anything. However long you think a project will take - you should multiply it by 3.

    Also depends on your programming skill and how clean you want the code to be. I tried new things and made it very "pluggable" like being able to add widgets with ease. This took me much longer than simply writing a bunch of huge functions that are closely tied to the sphinx application.

Sign In or Register to comment.