MongoDB排序錯誤:Sort operation used more than the maximum 33554432 bytes of RAM
錯誤描述
我用如下命令查詢某一個鍵的最大值:
db.video_info.find().sort({'vid':-1})
出現如下錯誤:
Error: error: { "ok" : 0, "errmsg" : "Executor error during find command: OperationFailed: Sort operation used more than the maximum 33554432 bytes of RAM. Add an index, or specify a smaller limit.", "code" : 96, "codeName" : "OperationFailed" }
分析解決問題
排序操作使用超過最大33554432個位元組的RAM,新增索引或指定較小的限制。
這是由於mongodb排序的時候會把資料載入到記憶體中,在這裡排序的資料量太大導致超過了32M的預設排序記憶體。
由於我這裡僅僅需要查詢最大值,所以我採用提示的第二種方案,命令後面加一個limit
。
db.video_info.find().sort({'vid':-1}).limit(1)
相關推薦
MongoDB排序錯誤:Sort operation used more than the maximum 33554432 bytes of RAM
錯誤描述 我用如下命令查詢某一個鍵的最大值: db.video_info.find().sort({'vid':-1}) 出現如下錯誤: Error: error: { "ok" : 0, "errmsg" : "Executor error
OperationFailed Sort operation used more than the maximum 33554432 bytes of RAM. Add an index, or specify a smaller limit
imu command mongo sed 大內存 gson style fan index 按照錯誤提示,知道這是排序的時候報的錯,因為 mongo 的 sort 操作是在內存中操作的,必然會占據內存,同時mongo 內的一個機制限制排序時最大內存為 32M,當排序的
tomcat server 報錯之 More than the maximum allowed number of cookies
int str sock lar time color errors round pin More than the maximum allowed number of cookies EVERE: Error processing request java.lang.
解決MYSQL的錯誤:Got a packet bigger than 'max_allowed_packet' bytes
測試 == 註意 Go ont 解決 情況下 class 開始 Mysql 5.1開始遇到的信息包過大問題,當用客戶端導入數據的時候,遇到錯誤代碼: 1153 - Got apacket bigger than ‘max_allowed_packet‘ bytes,數據庫終
mysql報錯Multi-statement transaction required more than 'max_binlog_cache_size' bytes of storage
.cn nbsp 導致 variable ria sed size log more mysql報錯Multi-statement transaction required more than ‘max_binlog_cache_size‘ bytes of storage
More than the maximum number of request parameters
必須 導致 png deb .cn 好的 attr sina ram 前些時間,我們的的一個管理系統出現了點問題,原本運行的好好的功能,業務方突然講不行了,那個應用已經運行了好多年了,並且對應的代碼最近誰也沒改動過,好奇怪的問題,為了解決此問題,我們查看了日誌,發現請求的參
While trying to acquire a needed new resource, we failed to succeed more than the maximum number of
出現如下錯誤,原因是資料庫驅動,我自己一直記著我的MySQL資料庫是8.0.13.版本,但是出學ssm配置pom.xml檔案的時候把資料庫驅動配置錯誤了。找了半天,後面神奇的突發奇想的覺得要看看驅動相容不? Type Exception Report Message Request pro
錯誤程式碼: 1242 Subquery returns more than 1 row
1. 錯誤描述 1 queries executed, 0 success, 1 errors, 0 warnings 查詢:SELECT t.id, DATE_FORMAT( t.statis
mongodb遊標錯誤:com.mongodb.MongoCursorNotFoundException: Query failed with error code -5
環境 mongodb:3.4.15 java:1.7 場景 對使用者日誌表補加時間戳的欄位; 具體程式碼如下: public static void main(String[] args) { final MongoCollectio
git pull遇到錯誤:error: Your local changes to the following files would be overwritten by merge:
覆蓋 eset class 代碼更新 hang err ast div clas 今天用git pull將服務器的代碼拉到本地時,遇到錯誤,Your local changes to the following files would be overwritten by
Linux錯誤:warning: here-document at line 5 delimited by end-of-file (wanted `EOF`
shell 指令碼執行‘warning’: 執行此test.shell報如下錯: warning: here-document at line 17 delimited by end-of-file (wanted `EOF') 原因是末尾的EOF後面帶有空格,EOF前
開啟虛擬機器所報的錯誤:VMware Workstation cannot connect to the virtual machine. Make sure you have rights to run the program, access all directories the program
當我們開啟虛擬機器時出現錯誤: VMware Workstation cannot connect to the virtual machine. Make sure you have rights to run the program, access all directories the program
文章翻譯:Recommending items to more than a billion people(面向十億級用戶的推薦系統)
red 這不 得到 放大 條件 mage 上界 出了 color Web上數據的增長使得在完整的數據集上使用許多機器學習算法變得更加困難。特別是對於個性化推薦問題,數據采樣通常不是一種選擇,需要對分布式算法設計進行創新,以便我們能夠擴展到這些不斷增長的數據集。 協同過濾(C
git pull遇到錯誤:error: Your local changes to the following files would be overwritten by merge:解決方法
error: Your local changes to the following files would be overwritten by merge: 意思是我桌上型電腦上新修改的程式碼的檔案,將會被git伺服器上的程式碼覆蓋;我當然不想剛剛寫的程式碼被覆蓋掉,看了git的手
錯誤程式碼 1242 Subquery returns more than 1 row
1. 錯誤描述1 queries executed, 0 success, 1 errors, 0 warnings查詢:SELECT t.id, DATE_FORMAT( t.statisTime, '%Y-%m-%d %H:%i:%s' ) statisTime,
git pull遇到錯誤:error: Your local changes to the following files would be overwritten by merge
出現這個問題的原因是,我個人認為是原生代碼和伺服器程式碼衝突,本地的程式碼將會被伺服器的程式碼覆蓋掉,有兩種解決的方法: 1.保留本地修改的程式碼,並把伺服器的程式碼pull到本地 git stash git pull origin master
scrapy框架之post傳輸數據錯誤:TypeError: to_bytes must receive a unicode, str or bytes object, got int
pos data 簡單 錯誤 soc spi ack erro http 錯誤名:TypeError: to_bytes must receive a unicode, str or bytes object, got int 錯誤翻譯:類型錯誤:to_bytes必須接收
It’s more than the music- a UX case study
It’s more than the music- a UX case studyNowadays, we can do anything from our cellphones. We can buy groceries, connect with people across the world, and
MySQL 執行SQL檔案,報錯:”Got a packet bigger than 'max_allowed_packet' bytes“
開發十年,就只剩下這套架構體系了! >>>
MyBatis錯誤:The server time zone value '?泄???????' is unrecognized or represents more t
mysq exce xxxxx 解決 技術 name 差異 錯誤 href 原文地址:http://blog.csdn.net/oppo5630/article/details/52162783 解決java.sql.SQLException: The server ti