PassMark Logo
Home » Forum

Announcement

Collapse
No announcement yet.

Division by zero in search_km.php warning message

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Division by zero in search_km.php warning message

    Hi there,

    After increasing memory_limit to 512mb i don't get below message anymore as before

    "Fatal error: Allowed memory size of 33554432 bytes exhausted ...."

    ..but another problem seems to appear. My search function is not really working. For your info, i use cgi/linux platform instead of php since my site is huge. If i search word "v6", not all documents that appear seems to have that word at all and sometimes i even get this message..."Warning: Division by zero in /srv/www/htdocs/epla/minit/mmk/search_km.php on line 1261"

    So, what is exactly the problem here??? Hope you can assist me again.

    Thanks

  • #2
    search_km.php is not our file. So I don't know what it does. I assume it is a script you wrote yourself?

    The memory limit I think you are referring to is the limit in the php.ini file. And is the memory limit for PHP scripts, not CGI's.

    So it is not surprising that you don't get PHP memory errors if you are using the CGI.

    In any case we no longer support V4 of Zoom. You should upgrade to V6.


    Comment


    • #3
      Warning: Division by zero in /srv/www/htdocs/epla/minit/mmk/search_km.php on line 126

      Hi there,

      I've upgraded memory limit to 512MB in php.ini and the error message doesn't seem to appear anymore as before. (Fatal error: Allowed memory size of...)..

      But another problem arise when i finish doing indexing using CGI/Linux platform instead of PHP since my site is huge, this error appear..."Warning: Division by zero in /srv/www/htdocs/epla/minit/mmk/search_km.php on line 1261
      "


      Also when i try to do searching not all document that appear contain the word that i'm searching for. Let's say if i'm searching the word "v6", not all document appear contain that word.

      So what causes the problem to both these problems? I would appreciate your help again.

      For your info search_km.php is my file

      Thanks.

      Comment


      • #4
        > Division by zero in search_km.php
        > For your info search_km.php is my file

        As it is your file, we
        don't know what it does, nor what code is in it. So no one reading this would be able to provide any suggestions.

        You post also doesn't make sense, based on the information provided. If you are using the CGI as you claim, then why is there any error in PHP? Clearly you are using PHP for something.

        If some pages are not appearing in the search results, see these FAQ,

        Q. Why are some of my pages being skipped by the indexer?

        Q. Why are links in my Javascript menus being skipped?

        Q. I am indexing with spider mode but it is not finding all the pages on my web site

        Comment


        • #5
          Sorry to misunderstand the issue yesterday. Let me explain the real situation of my search system. I really need to do 3 searches of search_km.php,
          search_mm.php and search_ml.php which I modify the coding in the original file is search.php .

          The original script that I modify from search.php file is like the zoom_wordmap.zdat to zoom_wordmap_km.zdat,
          zoom_dictionary.zdat to zoom_dictionary_km.zdat


          .... and so too is zoom_xxx.zdat to zoom_xxx_km.zdat / zoom_xxx_mm.zdat / zoom_xxx_ml.zdat . The words ...... _ml / _km / _mm refers to three different searches that I mean today.


          Therefore, I rename the original file (search.php) to meet the requirements of the system. Due to a search of "km" ("search_km.php") site is too large, I had to do indexing using cgi platform / linux platform though my system using php script

          So, you say I need to upgarde to zoom v6 and php 5. Whether the zoom v6 can overcome my problem (large site) or not because that's my main problem right now

          And I see you specify unique maximum limit for PHP and ASP from 300,000 to 500,000 for zoom v6, right? How about the maximum file can be scanned and other elements in the "Limits" which is one of the features of the zoom v6?

          Hope you can explain and hope also zoom v6 can solve my problem

          Thanks again.

          Comment


          • #6
            I think you're confused in several areas.

            First, you cannot create an index for the CGI/Linux platform, then take those index files and use it with the PHP search script. The index files created for CGI will only work with "search.cgi".

            If you need to index more pages than possible with the PHP version, then you can't use the "search.php" script, and the other changes mentioned would seem pointless.

            If that's not the case, then I still don't understand why you need to rename the files.
            If you simply want to have 3 sets of search functions (and 3 sets of index files), then put them in 3 different directories. Renaming those files and modifying the scripts are not supported usages, we can't be sure if your modifications have not broken the scripts, and we it's outside our support to debug our customer's scripts.

            Zoom V6 using CGI is certainly capable of indexing 300,000 to 500,000 files. Whether your server is configured and capable is a second factor. And it can also vary depending on the content and data in the file. 500,000 small HTML files (each several kilobytes in size) is very different to 500,000 large PDF files (each say, 20 MB in size and containing hundreds of pages of text).

            Please also see this FAQ:
            Q. Does Zoom support very large sites? What are the practical limits of the size of sites that Zoom can be used with?
            --Ray
            Wrensoft Web Software
            Sydney, Australia
            Zoom Search Engine

            Comment

            Working...
            X