深圳国外网站设计,如何建设网站 知乎,花生壳怎么发布自己做的网站,中国建设银行注册网站用户名怎么填Solr总是使用超过90#xff05;的物理内存(Solr always use more than 90% of physical memory)我在solr索引中存储了300000个文档。 并使用4GB RAM作为solr服务器。 但它消耗超过90#xff05;的物理内存。 所以我把我的数据转移到一台有16 GB RAM的新服务器上。 再次solr消…Solr总是使用超过90的物理内存(Solr always use more than 90% of physical memory)我在solr索引中存储了300000个文档。 并使用4GB RAM作为solr服务器。 但它消耗超过90的物理内存。 所以我把我的数据转移到一台有16 GB RAM的新服务器上。 再次solr消耗超过90的内存。 我不知道如何解决这个问题。 我使用了默认的MMapDirectory和solr版本4.2.0。 请解释一下如果您有任何解决方案或原因。I have 300000 documents stored in solr index. And used 4GB RAM for solr server. But It consumes more than 90% of physical memory. So I moved to my data to a new server which has 16 GB RAM. Again solr consumes more than 90% memory. I dont know how to resolve this issue. I used default MMapDirectory and solr version 4.2.0. Explain me if you have any solution or the reason for this.原文https://stackoverflow.com/questions/22149296更新时间2019-11-05 12:05最满意答案MMapDirectory尝试尽可能多地使用操作系统内存(OS Cache)这是正常行为它会尝试将整个索引加载到内存中(如果可用)。 事实上这是一件好事。 由于这些内存是可用的它会尝试使用它。 如果同一台计算机上的另一个应用程序需要更多则操作系统将为其释放它。 这就是为什么Solr / Lucene的查询速度快一个数量级的原因因为大多数调用服务器的内存都是以内存(取决于内存大小)而不是磁盘。JVM内存是不同的东西它可以被控制只有正在运行的查询响应对象和某些缓存项使用JVM内存。 所以JVM的大小可以根据数字请求和缓存条目进行配置。MMapDirectory tries to use the OS memory (OS Cache) to the full as much as possible this is normal behaviour, it will try to load the entire index into memory if available. In fact, it is a good thing. Since these memory is available it will try to use it. If another application in the same machine demands more, OS will release it for it. This is one the reason why Solr/Lucene the queries are order of magnitude fast, as most of the call to server ends up memory (depending on the size memory) rather than disk.JVM memory is a different thing, it can be controlled, only working query response objects and certain cache entries use JVM memory. So JVM size can be configured based on number request and cache entries.相关问答MMapDirectory尝试尽可能多地使用操作系统内存(OS Cache)这是正常行为它会尝试将整个索引加载到内存中(如果可用)。 事实上这是一件好事。 由于这些内存是可用的它会尝试使用它。 如果同一台计算机上的另一个应用程序需要更多则操作系统将为其释放它。 这就是为什么Solr / Lucene的查询速度快一个数量级的原因因为大多数调用服务器的内存都是以内存(取决于内存大小)而不是磁盘。 JVM内存是不同的东西它可以被控制只有正在运行的查询响应对象和某些缓存项使用JVM内存。...暴露给用户空间应用程序的所有地址(包括mtrace()显示的地址mtrace()都是虚拟内存地址。 All addresses exposed to userspace applications, including those shown by mtrace(), are virtual memory addresses.默认情况下solr 4.3将mmap索引到内存中您可以尝试其他DirectoryFactory例如SimpleFSDirectoryFactory。 请参阅solrconfig.xml中的DirectoryFactory部分。 By default, solr 4.3 will mmap index into memory, you may try other DirectoryFactory, such as SimpleFSDirectoryFactory. See DirectoryF...wmic os get FreeVirtualMemory, FreePhysicalMemory, FreeVirtualMemory,MaxProcessMemorySize,TotalVisibleMemorySize,TotalVirtualMemorySize比systeminfo工作得更快 wmic os get FreeVirtualMemory, FreePhysicalMemory, FreeVirtualMemory,MaxProcessMemorySize,TotalVi...Solr显然在这个数字中加入了“buff / cache”。 如果将其添加到“已使用”则获得98。 记忆是可以回收的所以你不应该担心。 操作系统只是尽可能地使用RAM进行磁盘缓存。 Solr apparently includes buff/cache into that number. If you add it to used you get 98%. That memory is reclaimable, so you shouldnt be worried. Operati...虚拟内存本质上(在实际意义上)与物理内存相同只是扩展到系统的磁盘驱动器以进行缓存(请参阅分页文件)。 由于它位于磁盘上因此访问速度要慢得多因为在读取数据之前需要将数据从磁盘“交换”到物理内存中。 如果程序有内存泄漏它将填满(或至少达到程序可用内存的限制。) 您可以使用top来检查消耗大量内存的进程。 如果内存量在异常速率的程序中继续增长那么这可能是内存泄漏的指示。 使用像valgrind这样的程序可以更容易识别 http //en.wikipedia.org/wiki/Valgri...9GB由您添加的8GB执行程序内存作为参数组成 spark.yarn.executor.memoryOverhead设置为.1 因此容器的总内存为spark.yarn.executor.memoryOverhead (spark.yarn.executor.memoryOverhead * spark.yarn.executor.memoryOverhead)这是8GB (.1 * 8GB) ≈ 9GB 。 您可以使用一个执行程序来运行整个过程但这需要很长时间。 要理解这一点您需要...你自己看 JVM无法为堆获取足够的内存并退出。 我认为没有办法让JVM使用特定数量的内存进行分页但您可以使用 -XX:|-UseLargePages - 用于大页面支持 和-XXLargePageSizeInBytes - 用于指定大页面的大小。 请查看http://docs.oracle.com/javase/7/docs/technotes/tools/solaris/java.html See for yourself: JVM fails in getting enough...