Score:0

ข้อความ "Matlab ถูกฆ่า" แสดงขึ้นขณะเรียกใช้ matlab ใน Ubuntu 20.04.3

ธง cn
anu

ข้อความ "Matlab ถูกฆ่า" แสดงในเทอร์มินัลขณะเรียกใช้ matlab ใน Ubuntu 20.04.3 โปรดช่วยฉันเกี่ยวกับเรื่องนี้

us flag
MATLAB เป็นซอฟต์แวร์ที่เป็นกรรมสิทธิ์ ติดต่อฝ่ายสนับสนุนของ MATLABในกรณีฉุกเฉิน ให้ตรวจสอบว่า [GNU Octave](https://www.gnu.org/) ใช้งานได้หรือไม่ (หากต้องการติดตั้ง ให้ป้อนคำสั่ง `sudo apt install octave`) เป็นโอเพ่นซอร์สฟรีและคงความเข้ากันได้สูงกับไวยากรณ์ของ MATLAB
us flag
ตาม https://www.mathworks.com/matlabcentral/answers/523663-matlab-gets-killed-with-out-of-memory-in-ubuntu-20-04-how-to-limit-the-memory- สำหรับกระบวนการ เป็นเพราะ MATLAB ใช้หน่วยความจำมากเกินไป จริงๆ เปลี่ยนไปใช้ Octave ถ้ามันเหมาะกับคุณ หากคุณไม่ต้องการกล่องเครื่องมือมากนัก Octave ก็ใช้งานได้ดี
Score:1
ธง cn

The message comes from the OS, from the dread OOM-killer, the "out of memory killer".

Years ago, operating systems took their memory allocation responsibilities seriously. When an application allocated memory, the OS allocated the memory. If there was not enough memory to satisfy the request, it was denied. Some still work that way, but Linux usually does not.

Linux is usually configured by default to treat memory allocation the way airlines treat reservations. It "honors" more allocations than it can actually supply, on the (correct) theory that not every allocation will actually be used. That works great until it doesn't.

On an airplane, overbooked passengers aren't pushed off the plane in mid-air. On Linux, that's exactly what happens: when memory is actually, really exhausted, the Grim Reaper, the OOM-killer, picks a victim. In your case, the victim is Matlab. Lucky you. Instead of a free ticket, you get a message.

To defeat the OOM-killer, change the overcommit_memory kernel setting to 2.

That solution is unfortunately a rear-guard action. The influence of Linux has led many applications to rely on overcommitted memory, and be profligate in their memory allocations. When it's not available, those applications use a lot of memory. On the other hand, it has the meritorious property of actually running programs that do start, and not killing running processes arbitrarily chosen as OOM targets.

To run Matlab reliably for the problem you have on the machine you have, you might need more RAM. As a stopgap, you could increase swap space, which increases virtual memory, which is what you need.

anu avatar
cn flag
anu
ขอบคุณมากครับท่าน คำแนะนำของคุณช่วยฉันได้จริงๆ

โพสต์คำตอบ

คนส่วนใหญ่ไม่เข้าใจว่าการถามคำถามมากมายจะปลดล็อกการเรียนรู้และปรับปรุงความสัมพันธ์ระหว่างบุคคล ตัวอย่างเช่น ในการศึกษาของ Alison แม้ว่าผู้คนจะจำได้อย่างแม่นยำว่ามีคำถามกี่ข้อที่ถูกถามในการสนทนา แต่พวกเขาไม่เข้าใจความเชื่อมโยงระหว่างคำถามและความชอบ จากการศึกษาทั้ง 4 เรื่องที่ผู้เข้าร่วมมีส่วนร่วมในการสนทนาด้วยตนเองหรืออ่านบันทึกการสนทนาของผู้อื่น ผู้คนมักไม่ตระหนักว่าการถามคำถามจะมีอิทธิพลหรือมีอิทธิพลต่อระดับมิตรภาพระหว่างผู้สนทนา