multi-core solr deploy process(not complete)

2019-03-27 01:08|来源: 网路

How to set up Solr on Ubuntu 10.04 (or whatever) 0 Comments | Tags: solr search Apache Solr is a fast, open-source search solution. People are doing some very cool things with Solr. I personally have only begun to scratch the surface of what is possible with Solr, but have seen amazing returns with a relatively small investment (thanks entirely to Daniel Lindsley's excellent search framework, django-haystack). There are instructions for getting up and running with Solr + Jetty -- the purpose of this blog entry is to walk through setting up multi-core Solr with Apache Tomcat. Let's go First step, install the server: sudo apt-get install tomcat6 Next you'll want to get Solr and extract it to a temporary directory mkdir -p ~/tmp/solr/ cd ~/tmp/solr/ wget http://apache.multihomed.net/lucene/solr/1.4.0/apache-solr-1.4.0.tgz tar xzf apache-solr-1.4.0.tgz All the solr cores and indexes will go in /var/solr: sudo mkdir -p /var/solr Copy the Solr webapp and the example multicore configuration files: sudo cp apache-solr-1.4.0/dist/apache-solr-1.4.0.war /var/solr/solr.war sudo cp -R apache-solr-1.4.0/example/multicore/* /var/solr/ sudo chown -R tomcat6 /var/solr/ OK, now just need to point Catalina at Solr: echo -e ' 'crossContext="true">\n 'override="true" />\n ' | sudo tee -a /etc/tomcat6/Catalina/localhost/solr.xml echo 'TOMCAT6_SECURITY=no' | sudo tee -a /etc/default/tomcat6 I edited the init script (/etc/init.d/tomcat6) to set solr.home, pointing it at /var/solr. I made this change near the top of the file other environment vars are set up: JAVA_OPTS="$JAVA_OPTS -Dsolr.home=/var/solr" Restart Tomcat6 and luxuriate in your newfound power: sudo /etc/init.d/tomcat6 restart Navigate to http://localhost:8080/solr/ - you should get something like this: Where to now? The solrconfig.xml files provided for each core are pretty barebones, so you'll want to replace those with something more like the solrconfig.xml at ~/tmp/solr/apache-solr-1.4.0/example/solr/conf/solrconfig.xml I personally copy all the stuff from the example conf directory into any new cores I create and use that as a starting place.


转自:http://www.cnblogs.com/lexus/archive/2010/07/23/1783996

相关问答

更多
  • 看看这篇文章: http : //blogs.msdn.com/pfxteam/archive/2008/08/12/8849984.aspx 特别是,限制并行区域的内存分配,并仔细检查写入操作,以确保它们不会发生在其他线程读取或写入的内存位置附近。 So I finally figured out what the problem was - and I think it would be useful to share it with the SO community. The entire issue ...
  • 多少天,我终于在长时间的斗争中找到了问题。 谢谢大家 首先,我不知道version number in schema file中设置version number in schema file 。 根据文档的默认值,对于多值,从版本1.1开始是false 1.0: multiValued attribute did not exist, all fields are multiValued by nature 1.1: multiValued attribute introduced, false ...
  • 您需要多核,因为您无法在多语言数据库中执行词干和停用词。 英语中的常用停用词是“by”和“is”,但这些词在许多北欧语言中意为“城镇”和“冰”。 如果你做多核,每种语言都可以在自己的核心上使用自定义的schema.xml来选择正确的词干分析器,停用词和受保护的单词。 但是同一个JVM在同一台服务器上运行它,所以你不会为一种特定语言的服务器花费任何额外的钱。 然后,如果一个服务器的负载太大,则复制多核设置,所有索引都从副本中受益。 You need multicore because you cannot d ...
  • 这是一个粗略的概述,希望能为您提供所需的详细信息。 汇编代码被翻译成机器代码; 即二进制数据,由CPU运行。 CPU与多核处理器上的核心相同; 即,CPU与处理器(芯片)不同。 每个CPU都有一个指令指针,指向下一个要执行的指令。 对于每个执行的指令,这都会递增。 因此,在多核处理器中,每个核心都有一个指令指针。 为了支持比可用CPU(或内核)更多的进程,操作系统将中断运行进程并定期存储其状态(包括指令指针)。 然后它将恢复已经中断的进程的状态并让它们执行一点。 继续执行的核心取决于操作系统的决定,并由运行 ...
  • 回答我自己的问题! :) 基本上,为了实现我的目标,我需要做以下事情: 在我的Maven POM文件中包含Solr WAR作为依赖项 将默认的Solr核心和配置( example/collection1/ )解压缩到我项目的子目录(我使用了cores/collection1 ) 在launch -Dsolr.solr.home上添加Java VM参数以指向cores目录( -Dsolr.solr.home=/path/to/my/project/cores ) 它不完全是自包含的(我仍然需要指向一个配置), ...
  • 你问题的核心是: NodeJS将不得不像其他多线程架构师那样面对传统的并发问题,例如,写入不受写保护的同一对象? 答案是这种情况通常是不可能的,因为node.js进程不共享内存。 进程A中的ObjectA,ObjectB和ObjectC与进程B中的ObjectA,ObjectB和ObjectC不同。并且由于每个进程都是单线程争用不可能发生。 这是您发现node.js中没有信号量或互斥模块的主要原因。 此外,node.js没有附带的线程模块 这也解释了为什么“没人关心”。 因为他们认为不可能发生。 node. ...
  • 您在每个查询中都给出了参数rows=2147483647 。 该参数的含义是(取自参考文献) 您可以使用rows参数对查询中的结果进行分页。 该参数指定Solr应一次返回客户端的完整结果集中的最大文档数。 默认值为10.也就是说,默认情况下,Solr一次返回10个文档以响应查询。 因此,您告诉Solr生效,在单个响应中发送查询的所有匹配。 这是你糟糕表现的原因。 当查询“java”时 ,谷歌是否会向您发送所有500.000.000次匹配,不会。 为什么不,性能。 我知道的每一个IR应用程序都会为您提供一个带 ...
  • 看来Queue.Queue没有按照您的意愿运行,并且不是为了在多个进程之间共享,而是必须使用Manager.Queue() 我添加了一些打印来理解你的代码流, 您仍然可以使用Pool()而不是num_cpus来num_cpus import pandas as pd import numpy as np import multiprocessing import pprint from multiprocessing import Process, Queue, Manager def do_someth ...
  • 运行以下命令解决了以下问题: sudo chown -R solr:solr /opt/solr/indexes/ 该目录是附加卷(Amazon EBS)的安装点。 在运行命令之前,目录权限看起来像: $ sudo ls -al /opt/solr/indexes/ total 24 drwxr-x--- 3 solr solr 4096 Feb 26 09:25 . drwxr-xr-x 5 solr solr 4096 Feb 26 09:33 .. drwx------ 2 root root ...
  • 如果这些是您唯一的两个选择,并且您确定将要在多台计算机上分配负载,那么ZeroMQ是满足该法案的两种选择中唯一的一种。 Python多处理模块用于在单个机器上跨进程/核心分配负载。 据我所知,多处理模块没有网络协议,这由随附文档中的第一段表示。 ZeroMQ可以在具有IPC协议的单台机器上用于类似的进程间消息传递,但它也具有基于网络的协议,允许您在不同计算机上运行的进程之间发送消息。 也就是说,这个问题有一个XY问题的轻微色调,因为你似乎已经任意缩小你的选择,只有两个,使用Python实现分布式程序的许多可 ...