Vannkorn

Full Stack Web Developer

Close

Some useful Linux commands I once in a blue moon use

It's annoying when you need to do certain things on Linux environments and you forgot the command to tell the computer what to do.

Ads: Register now via this link to receive $100 credit from Vultr

It’s annoying when you need to do certain things on Linux environments and you forgot the command to tell the computer what to do.

This happens to me all the time and so does everyone on the planet, not limited to tech people, I believe.

Without further ado, here are the Linux commands I find useful and worth to note down:

Check storage size
df -h
Delete file content
truncate -s 0 [file-name]
List down files whose size are more than 100MB
find / -size +100M -ls
List down files between 100MB and 1GB
find / -size +100M -size -1024MB -ls
List all system users 
less /etc/passwd
Change ownership of the specific user recursively down the folders
chown -R [user]:[group] *

Leave a Reply

Your email address will not be published. Required fields are marked *