ubuntu stepping on the pit notes--boot into the recovery journal solution

insert image description here
Reason: The disk space is full and cannot be started. This problem has been stepped on twice because of the
old logs in ./local/share/xorg and ./var/lib/gdm3/.local/share/xorg. But the reason for entering the recovering journal may not only be that the disk is full.
It should be abnormal for a log file to grow to 177g, but this problem seems to have appeared recently, which is very strange...
insert image description here

Check if you cannot start due to disk space, restart and press ESC to enter grub mode,
insert image description here
and select the recovery mode option.
insert image description here

resume:恢复正常启动,有的人选这个就可以进入系统
clean:清除磁盘中不必要的文档
dpkg:修复受损的安装包
fsck:磁盘检查与修复
grub:更新grub引导
network:带网络连接的shell界面
root:最高管理员的shell界面
system:查看系统的信息,资料

Then select system-summary in the recovery menu to check your own disk space. I know that my system is in nvme0n1p2 (I don’t know how to check it with grub), and the disk space is full. The next step is to delete large files.
insert image description here

Go back to the recovery menu and choose to enter root:

查看磁盘占用:df -lh
查看某个文件大小:du -sh
删除文件夹:sudo rm -rf
删除文件:sudo rm 
检查内存使用情况:free -m
检查内存使用情况:cat /proc/meminfo
查看清理空间:du –h /var/cache/apt/archives
删除已经卸载掉的软件包:sudo apt-get autoclean
删除电脑上存储的安装包:sudo apt-get clean
删除已卸载的安装包:sudo apt-get autoremove
清理内核:sudo apt-get autoremove —purge
清理缓存:sudo du -sh /var/cache/apt
     sudo apt-get clean
检查当前磁盘利用率:df -h
理缩略图缓存:rm -rf ~/.cache/thumbnails/*

It's almost finished deleting, just reboot directly

ps:
As for the problem of unlimited growth of xorg old logs, temporarily use logrotate polling, if there is a better solution or possible reasons for the surge of xrog logs, please leave a message, thank you~ ubuntu log file management Add configuration
files
:

sudo gredit /etc/logrotate.d/xrogold

insert image description here

sudo logrotate /etc/logrotate.conf 
sudo logrotate /etc/logrotate.d/xrogold

Guess you like

Origin blog.csdn.net/github_38060285/article/details/130227333