I was doing testing on my server and always getting this error
file for here-document: No space left on device
-bash: cannot create temp file for here-document: No space left on device
So I check it with the command "df".
Filesystem 1K-blocks Used Available Use% Mounted on
devtmpfs 1970540 0 1970540 0% /dev
tmpfs 1988952 0 1988952 0% /dev/shm
tmpfs 1988952 65980 1922972 4% /run
tmpfs 1988952 0 1988952 0% /sys/fs/cgroup
/dev/nvme0n1p1 8376300 8376280 20 100% /
tmpfs 397792 16 397776 1% /run/user/1000
I saw that the file /dev/nvme0n1p1 is using most of the memory. Is there any way I can free those memory? Or what can I do to have free some memory.
To free memory you can do the following:
/var/log
and empty any big log files.logrotate
tool to make sure that logs are will not consume disk space specially if you are using any webserver "Nginx, Apache for example".find
command as the following:
find / -size +100M | xargs du -sch
this command will list big files and show it's size.