Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am having a problem with one of my partitions being full and i have no idea why. It is the /dev/sda3 partition and has 13gb total and is 93.5% full. I am running Fedora 30 on VMWare workstation 15 player. The total hard disk size is 54 gb.
Filesystem Partition 1 - 524 MB
Swap Partition 2 - 4.3 GB
Filesystem Partition 3 - 13GB (93.5% full)
Extended Partition 4 27gb
Filesystem Partition 5 1.0GB
Partition 6 - 992 MB
Partition 7 - 999 MB
Filesystem Partition 8 - 2.1GB
Free Space - 22GB
I cannot seem to figure out how to see what is on Partition 3 to see what is taking up so much space, and then to figure out how to free it up. I am currently in a Linux class and so i am very new to Linux, and this has proved to be very difficult to grasp for me. Thank you for your assistance.
The "du"command will show you what is allocated - "man du" will give you the manual; use q to quit the manpage.
Wer need more info - from a terminal run this and post the output - it is similar to what you posted. You can use copy-paste from a terminal session.
I apologize, but i do not know how to copy-paste from a terminal. I did try to google how, but it all involved highlighting the output on the terminal using a mouse. As far as i know, i do not have a mouse to highlight anything in the terminal.
Should be pretty straight-forward - note I am talking about a terminal emulator, not a tty. Hit the "Windows" key and start typing terminal. Click on the icon - it will have an "Edit" menu selection, and yes the mouse highlighting will work. Copy from there, paste here.
Has your class covered shell redirection yet? If not, you might need to look ahead. Redirect to a file, and use the file to get the df -hT output into your web browser.
You should find the ncdu utility run by the superuser very useful in identifying files that waste space. Some locations where space wasting stale files are often found are /var/log/journal/, /boot/ and /lib/modules/ (old kernels & initrds), and the cache used by your package manager, e.g. /var/cache/dnf/ or /var/lib/dnf/system-upgrade/.
It's also worth looking at the file /etc/fstab. You can list its contents with the cat command. It will show you where that particular partition gets mounted at boot. My guess is that it's your home partition as it's so large.
In Linux, partitions are made accessible to the system by mounting them on an empty directory which becomes, for the duration of the mount, a synonym for the root directory of the partition. All directories and files on the partition thus become part of that directory tree. All mounted partitions ultimately form a single tree descending from the root directory of the root partition. They are not, as in Windows, separate island universes.
Once you find out what part of the filesystem tree that partition represents, you can use any file manager to find out what's taking up all the room.
in a terminal. Look for two things, a lost+found directory and a directory name some variation of .Trash (note the dot). The lost+found is contains things found by a check of the file system that could not be identified. Depending upon what you determine them to be you may be able to delete them. The .Trash contains files that were erased but not fully deleted so that they are easily recoverable. They take up space but are not normally listed in a directory listing. Things in there can probably be removed, again your call. To get rid of them actually force a removal don't just delete them or they will pop back up.The best way is to use the rm command.
I apologize, but i do not know how to copy-paste from a terminal. I did try to google how, but it all involved highlighting the output on the terminal using a mouse. As far as i know, i do not have a mouse to highlight anything in the terminal.
You are running Fedora 30. Are you using the full terminal, or are konsole inside the GUI?
If you are running the GUI, just open a terminal/konsole and you can highlight the text on the screen and typically use the middle mouse button to paste it into the browser.
If you are not running a GUI, than follow the advice about >> foo.txt for the output.
Should be pretty straight-forward - note I am talking about a terminal emulator, not a tty. Hit the "Windows" key and start typing terminal. Click on the icon - it will have an "Edit" menu selection, and yes the mouse highlighting will work. Copy from there, paste here.
#
# /etc/fstab
# Created by anaconda on Tue Feb 11 20:58:54 2020
#
# Accessible filesystems, by reference, are maintained under '/dev/disk/'.
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.
#
# After editing this file, run 'systemctl daemon-reload' to update systemd
# units generated from this file.
#
UUID=f927dc2b-10ac-4aaa-a58a-fb1b92748aab / ext4 defaults 1 1
UUID=f8a80453-0538-472e-b076-c620cae8c60c /boot ext4 defaults 1 2
UUID=c6a7fa3a-b32e-452d-aa58-0cdb6c6319f3 none swap defaults 0 0
/dev/sda5 /newmount ext4 defaults,usrquota,grpquota 0 0
/dev/vg00/newdata /newdata ext4 defaults 0 0
UUID=4de9cb8a-5b60-4a20-accd-a0e1034ca189 /xfsmount xfs defaults 0 0
Results of ls -a:
[user1@localhost ~]$ ls -a
. .bash_history .bash_profile .cache Desktop Downloads .esd_auth .gtkrc-2.0-kde4 .kde .mozilla Pictures specialfile Videos
.. .bash_logout .bashrc .config Documents .emacs.d .gtkrc-2.0 .ICEauthority .local Music Public Templates
Filesystem Type Size Used Avail Use% Mounted on
...
/dev/sda3 ext4 12G 12G 137M 99% /
...
This is your root filesystem, 99% full. Comment #5 suggests places to inspect for excess space consumers. If you have added much additional software since installing, such as for programming development, 12G for / may have been an under-allocation that only repartitioning and most likely reinstalling can rightly solve. For a 54G HD, you really have too many partitions for effective space allocation. With that little total space, you should have either only swap, / and at most one other partition (/home), or swap, /boot, and LVM, unless you are an expert in space utilization and management.
Please, when you paste in output from running commands, always wrap your paste in code tags ( [ # ] above the input composition window).
This is your root filesystem, 99% full. Comment #5 suggests places to inspect for excess space consumers. If you have added much additional software since installing, such as for programming development, 12G for / may have been an under-allocation that only repartitioning and most likely reinstalling can rightly solve. For a 54G HD, you really have too many partitions for effective space allocation. With that little total space, you should have either only swap, / and at most one other partition (/home), or swap, /boot, and LVM, unless you are an expert in space utilization and management.
Please, when you paste in output from running commands, always wrap your paste in code tags ( [ # ] above the input composition window).
Mr. Mazda, thank you for your reply. I did not know how to use the code tags, but will do so moving forward. I read comment #5 and you were correct. It looks like /var/log/journal/ is the culprit at 12288MB. I have hardly added any additional software, and i honestly dont really know how or what i would install at this point.
Code:
[user1@localhost journal]$ ls -l /var/log/journal/
total 16
drwxr-sr-x+ 2 root systemd-journal 12288 Apr 28 21:32 244803c1edc3486684b7c223941773f8
I checked the disk usage within the journal directory, but that only came back at 496.3M, so i am not sure where all the extra is. I also tried limiting the journal size to 3GB, but that didnt seem to do anything.
Code:
[user1@localhost journal]$ journalctl --disk-usage
Archived and active journals take up 496.3M in the file system.
[user1@localhost journal]$ sudo journalctl --vacuum-size=3G
Vacuuming done, freed 0B of archived journals from /var/log/journal/244803c1edc3486684b7c223941773f8.
[user1@localhost journal]$ sudo nano /etc/systemd/journald.conf
[user1@localhost journal]$ ls -l /var/log/journal/
total 16
drwxr-sr-x+ 2 root systemd-journal 12288 Apr 28 21:32 244803c1edc3486684b7c223941773f8
you can also try ncdu (it was already suggested) if you find that easier (probably need to install first, and probably that won't work).
but the suggestion in post #12 should work anyway.
Don't worry about /usr - there is very little you can do about that. More importantly, you really don't want to be meandering around there deleting stuff. Not at your current level of knowledge, not later when you think you know all about it.
PackageKit on the other hand is just a PITA - seems more so on Fedora. I just delete the lot. The situation is that your partition is way too small. What does this return.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.