# Manticore Search 2.4.1 GA release

我们很高兴宣布 Manticore Search 2.4.1 的 GA 版本正式发布。

适用于 Debian、Ubuntu、Red Hat/CentOS、Windows 和 OSX 的预编译包可以从 [此处](https://github.com/manticoresoftware/manticore/releases) 下载。

Manticore Search 2.4.1 GA 与现有的 Sphinx 搜索版本 100% 兼容（如果您从较旧的 Sphinx 版本升级，请检查升级路径至 2.3.2）。

### 新功能


  
  
##### WHERE 子句中的 OR 运算符


现在可以在属性过滤器之间使用 WHERE 子句中的 OR。请注意，目前仍无法在 MATCH 子句和属性过滤器之间使用 OR。

```bash
mysql> select * from wikipedia where match('test')  and pageid=357881 OR  len=2070;
+-----------+------------------------------------------------------------+---------+-------+------------+
| id        | title                                                      | pageid  | len   | touched    |
+-----------+------------------------------------------------------------+---------+-------+------------+
| 227704715 | Test-driven_development                                    |  357881 | 24915 | 1216959577 |
| 222632760 | Echo_(command)                                             |  754160 |  2070 | 1214847412 |
+-----------+------------------------------------------------------------+---------+-------+------------+
2 rows in set (0.01 sec)

```

  
  
##### 维护模式


使用 [SET](http://docs.manticoresearch.com/latest/html/sphinxql_reference/set_syntax.html) 语句，服务器可以进入维护模式。在此模式下，只有使用 VIP 连接的客户端可以执行查询。

```bash
mysql> SET MAINTENANCE = 1;

```

  
  
##### 在分布式索引上执行 CALL KEYWORDS


现在也可以在分布式索引上运行 CALL KEYWORDS。该命令会在每个节点上执行，结果由主节点合并后返回。
  
  
##### UTC 时间分组


默认情况下，时间分组函数在本地时区计算。[grouping_in_utc](http://88.99.251.227:9090/latest/html/conf_options_reference/searchd_program_configuration_options.html#grouping-in-utc) 允许切换到 UTC 时区。也可以通过 [SET ](http://88.99.251.227:9090/latest/html/sphinxql_reference/set_syntax.html) 语句实时更改。
  
  
##### 日志文件权限


默认情况下，searchd 以 600 权限创建日志文件。现在可以使用 query_log_mode 设置不同的权限。

```bash
searchd
{
   ...
   query_log_mode = 666
   ...
}

```

 

其他小改进：

 - 字段权重可以为零或负数

 - max_query_time 现在可以中断全扫描查询（没有 MATCH 子句的查询）

 - 引入了 net_wait_tm、net_throttle_accept 和 net_throttle_action。这些是网络线程的微调设置，适用于 workers=thread_pool 的繁忙服务器。

 - 现在可以在使用 facets 时执行 COUNT DISTINCT

 - IN 现在可以与 JSON 浮点数组一起使用

 - 多查询优化不再因整数/浮点表达式而中断

 - 当使用多查询优化时，SHOW META 会显示 'multiplier' 行



  
  
### 编译


编译所需的最低 gcc 版本为 4.7.2。编译过程需要 cmake。这使得可以将构建打包为 zip 或特定发行版包（rpm/deb）。有关更多信息，请参阅文档中的 [编译部分](http://docs.manticoresearch.com/latest/html/installation.html#compiling-manticore-from-source)。
  
  
### 从 Sphinx 搜索升级


Manticore Search 继续使用常规的 `/etc/sphinxsearch/sphinx.conf`。

服务将在 `manticore` 用户下运行（Sphinx 使用的是 `sphinx` 或 `sphinxsearch`）。

默认使用的文件夹是 `/var/lib/manticore`、`/var/log/manticore`、`/var/run/manticore`。您仍然可以使用现有的 sphinx.conf，但需要手动更改 `/var/lib/sphinxsearch`、`/var/log/sphinxsearch`、`/var/run/sphinxsearch` 的权限。
  
  
### 错误修复


Sphinx 2.3.2 上报告的许多错误已修复，但可能并非全部。如果您升级后仍然遇到错误，请在官方 [问题跟踪器](https://github.com/manticoresoftware/manticore/issues) 上提交工单。

如果您使用的是 RealTime 索引，我们建议升级到 Manticore Search 2.4.1 GA，因为 Sphinx Search 2.3.2 引入的 RT 块渐进合并可能导致索引损坏。

有关更改的完整报告，请参阅 [发布说明](http://docs.manticoresearch.com/latest/html/releasenotes.html#version-2-4-1-ga-16-october-2017) 。
