
我的第一個 Linux 發行版是 19.04 版本的 Ubuntu。我在 18.04 更改了它(因為它是 LTS)。 19.04 肯定沒問題。但是當我使用 alt-tab 程式或只是使用某人時,18.04 太凍結了。
會是什麼呢?我該如何解決這個問題?我應該分享哪些資訊?
ls -al ~/.local/share/gnome-shell/extensions
:
結果:
ls: cannot access '/home/andrew/.local/share/gnome-shell/extensions': No such file or directory
ls -al /usr/share/gnome-shell/extensions
:
結果:
total 16
drwxr-xr-x 4 root root 4096 Feb 3 19:24 .
drwxr-xr-x 6 root root 4096 Feb 3 19:24 ..
drwxr-xr-x 3 root root 4096 Feb 3 19:24 [email protected]
drwxr-xr-x 3 root root 4096 Feb 3 19:24 [email protected]
free -h
結果:
total used free shared buff/cache available
Mem: 7.7G 4.6G 458M 518M 2.7G 2.3G
Swap: 2.0G 259M 1.7G
sysctl vm.swappiness
結果:
vm.swappiness = 60
也許這是正常的,當我打開時它會滯後: -Chrome -Intellij Idea -Telegram Desktop 有時更多: -pg4Admin -Postman -pdf files
*-firmware
description: BIOS
vendor: Dell Inc.
physical id: 0
version: 1.2.3
date: 05/15/2019
size: 64KiB
capacity: 15MiB
capabilities: pci pnp upgrade shadowing cdboot bootselect edd int13floppynec int13floppy1200 int13floppy720 int13floppy2880 int5printscreen int9keyboard int14serial int17printer acpi usb smartbattery biosbootspecification netboot uefi
*-memory
description: System Memory
physical id: 3d
slot: System board or motherboard
size: 8GiB
*-bank:0
description: DIMM [empty]
physical id: 0
slot: ChannelA-DIMM0
*-bank:1
description: SODIMM DDR4 Synchronous Unbuffered (Unregistered) 2400 MHz (0.4 ns)
product: HMA81GS6AFR8N-UH
vendor: Hynix Semiconductor (Hyundai Electronics)
physical id: 1
serial: 2B89D03D
slot: DIMM B
size: 8GiB
width: 64 bits
clock: 2400MHz (0.4ns)
*-cache:0
description: L1 cache
physical id: 41
slot: L1 Cache
size: 256KiB
capacity: 256KiB
capabilities: synchronous internal write-back unified
configuration: level=1
*-cache:1
description: L2 cache
physical id: 42
slot: L2 Cache
size: 1MiB
capacity: 1MiB
capabilities: synchronous internal write-back unified
configuration: level=2
*-cache:2
description: L3 cache
physical id: 43
slot: L3 Cache
size: 6MiB
capacity: 6MiB
capabilities: synchronous internal write-back unified
configuration: level=3
*-memory UNCLAIMED
description: Memory controller
product: Sunrise Point-LP PMC
vendor: Intel Corporation
physical id: 1f.2
bus info: pci@0000:00:1f.2
version: 21
width: 32 bits
clock: 33MHz (30.3ns)
configuration: latency=0
resources: memory:d232c000-d232ffff
答案1
FSCK
讓我們檢查一下您的檔案系統...
- 在「嘗試 Ubuntu」模式下引導至 Ubuntu Live DVD/USB
terminal
按Ctrl+ Alt+開啟一個視窗T- 類型
sudo fdisk -l
- 識別「Linux 檔案系統」的 /dev/sdXX 裝置名稱
- 輸入
sudo fsck -f /dev/sdXX
,替換sdXX
為您之前找到的數字 fsck
如果有錯誤則重複命令- 類型
reboot
記憶體測試
讓我們進行一下記憶體測試...
去https://www.memtest86.com/並下載/運行他們的免費 memtest 來測試您的記憶力。至少完成一次所有 4/4 測試,以確認良好的記憶力。這可能需要幾個小時才能完成。
更新#1:
您的DELL Inspiron P75F
BIOS 版本是最新的 1.2.3。
更新#2:
最近的free -h
命令表明記憶體已滿。添加內存。確保成對進行操作...因此,如果您現在有一個 8G DIMM,請新增一個符合的 8G DIMM。如果您現在有兩個 4G DIMM,請將其替換為兩個 8G DIMM。您可以使用它sudo lshw -C memory
來查看您的記憶體現在的配置。
答案2
讓我先說一下您肯定需要更多的內存,尤其是您正在運行的程式。如果您不願意或無法購買更多內存,以下內容可能會有所幫助。
我的安裝凍結也遇到了一些問題,有幾件事可能會有所幫助。
增加交換文件大小,一般經驗法則是交換文件應至少為 1 倍內存,如果您能負擔 1.5 倍內存則更好。
您可以做的另一件事是關閉交換性,這樣就不太容易交換文件。與此結合,如果可以的話,增加你的記憶體可能是一個好主意。
答案3
我看到了磁碟的圖像,但沒有看到交換分割區。我對 Linux 很陌生,但是當我閱讀如何安裝 Linux 時,他們建議我創建一個大約與系統中的 RAM 大小相同的分割區,以使這些東西「刷新」。我檢查了您在控制台中輸入的命令,以查看我的交換是否出現並且它就在那裡。
我有 4GB 內存,但我做了一個 8GB 內存的特殊分區作為交換。
我還看到你有 8GB 內存,我認為這足以運行 Ubuntu
我運行的是 Lubuntu 18.04,我沒有遇到凍結問題,而且我有你一半的記憶體。
關於使用的內存,我讀到系統幾乎使用所有內存作為緩存,並且在需要時它會為程式釋放內存。
你的磁碟和 Linux 分割區上有足夠的空間,所以不存在這個問題。
我可以建議您檢查磁碟的讀取速度,只是為了確保正確。我只有在磁碟寫入大量資料時才會凍結,所以也許問題就在那裡。
另一種建議是在安裝 Linux 時建立多個分割區。我發現人們通常會進行三個分區:
“/”
“/家”
“交換”
我認為“/”和“/home”分開可能是為了格式化SO,並且在這個過程中不要丟失你的東西(我更喜歡在Windows上複製文件並格式化三個分割區,但這就是我的方式)
我希望我發布的一些內容可以對您有所幫助。如果我的英語看起來不太好,我很抱歉,我不是英語母語。