> Main > Products and Services > Purchase > Company
English / Russian

CNSearch

The search engine for web-sites

Current Version

CNSearch 2.0.1

User Manual / CNSearch 1.5.1

3 Working with the System

CNSearch is comprised of two parts - an indexer and a search module module. The indexer analyses a web-site (or a group of sites) where one are going to search and creates an index file; the Search module performs a quick search in the created index file.

3.1 Indexing

To start the indexing one should perform the following actions:

  1. Enter the Job name (any) and the address of the web-site for indexing in search.conf file:


    Figure 1 Setting the indexing parameters

    there localhost is a name of a job, and http://localhost/my_site is the web-site address.

  2. Run indexer.exe in the command line, defining the following parameters:
    • Name of the job;
    • Name of the configuration file and its location (in case it is located in another directory).

Example for Windows:

C:\indexer.exe localhost

or

C:\indexer.exe --config=D:\www\search.conf localhost 

Example for Unix/Linux:

./indexer name_of_task
or
./indexer.exe --config=/home/www/search.conf name_of_task 

To perform indexing of several sites at once, one should enter the sites` URLs within one job in search.conf:


Figure 2 Setting up several sites indexing

Having finished the indexing the system creates the following set of index files:

Note: At the present moment two types of indexing are available in the system:

3.2 Defragmentation

There is a possibility to optimize the search process by means of the index defragmentation: the indexing results are being systematized, which allows accelerating the next search process. To fulfill defragmentation one should copy idefrag.exe file, located in the indexer directory, to a folder containing index files (index.cns, docs.cns and files.cns) and launch it. After the end of the process docs.cns will be replaced by results.cns.

Note: Defragmented index files can not be edited.

3.3 Search

To perform search within the generated index, one should perform the following options:

  1. Copy index files (see Indexing) to the directory containing search module; as a rule, it is /cgi-bin/ directory of the web-server;
  2. Define a path to search.exe file;
  3. Enter a search request in the form and press Search; provided that the search request has been correctly specified, the system will display the list of search results:

Figure 3 Search results

It is possible to sort out the search results by date or by relevancy.

One can set the interface of the results form with the help of templates (see Templates setting).

'fulltxt.cns' file contains all texts of the indexing documents: these data allow showing text samples, containing highlighted search phrase in the search results, for instance:

Note: 'fulltxt.cns' file may be of a considerable size; in this case one can delete it or cancel its generation by means of Type parameter (see search.conf) during the indexing process - search results will be displayed in the following way (without highlighting and citing, only first 256 symbols of a document):


Back | Manual index | Next