Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This 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!


  Search this Thread
Old 02-13-2012, 11:46 AM   #1
Registered: Apr 2010
Posts: 82

Rep: Reputation: 1
clean up free some disk space

my diskspace in linux is all occupied , no more free disk space, I want to free some disk space but I dont know what is safe to delete , I dont know what folders are dedicated to linux os , I know I folder I use , but others I want to delete , deleting these folder should not impact linux os .
please advice me
here is the folder by size

[root@ACFAS12 /]# du -sh * |sort
0 misc
0 net
0 proc
0 sys
11G pkg
12K u02
1.3G root
141M etc
16K lost+found
16M boot
199M lib
21M lib64
2.5G usr
31M sbin
3.2G opt
4.0K media
4.0K selinux
4.0K srv
4.0K svn_backup
4.1G var
520K tmp
7.6G home
7.6M bin
77M u01
8.0K mnt
88K dev

can I delete the Pkg folder ? is this linux specific or user created ?
Old 02-13-2012, 11:57 AM   #2
Senior Member
Registered: Aug 2010
Location: Near Edinburgh, Scotland
Distribution: Cinnamon Mint 20.1 (Laptop) and 20.2 (Desktop)
Posts: 1,574

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
What distribution are you running? Do you want to remove data (pictures/documents/music, etc) or Linux applications? You can't just delete a directory in Linux or you're asking for trouble.
If you can clear out data, it should be in your /home directory. If you want to remove applications I'd use whatever package manager your distribution uses; yast for SUSE, Synaptics for Debian based Distros, eg, Ubuntu. This would allow you to remove the software cleanly. You can also tidy up by removing browser histoey files and cookies (not a lot of space freed off really)

Play Bonny!

Last edited by Soadyheid; 02-13-2012 at 11:58 AM. Reason: spellnig!
Old 02-13-2012, 12:21 PM   #3
Registered: Apr 2010
Posts: 82

Original Poster
Rep: Reputation: 1
I am using CentOS release 5.3 (Final)

please advice me what cleaning tool should I use ?
Old 02-13-2012, 03:11 PM   #4
Senior Member
Registered: Jul 2006
Location: Belgrade, Yugoslavia
Distribution: Debian stable/testing, amd64
Posts: 1,053

Rep: Reputation: 47
CentOS uses 'Yellow dog Updater, Modified (Yum)' as package manager. you should try uninstalling something with it. usually, on every modern OS you use same program for installing and uninstalling software.
There is also an option to use filesystem that can compress /usr and similar, but that sounds complex to me (never used it).

Last edited by qrange; 02-13-2012 at 03:12 PM.
Old 02-13-2012, 03:17 PM   #5
Senior Member
Registered: Feb 2009
Posts: 4,667

Rep: Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409Reputation: 1409
A $99 replacement hard drive would solve your problem (and give you lots of room to grow).

You can free up a gigabyte here and there by clearing log files, package caches, etc.; but it will not solve the underlying problem: your drive will eventually fill back up again, and searching for files to safely delete will become a weekly/monthly frustration.
Old 02-13-2012, 09:09 PM   #6
LQ Guru
Registered: Aug 2004
Location: Sydney
Distribution: Centos 7.7 (?), Centos 8.1
Posts: 17,925

Rep: Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631Reputation: 2631
You might want to tune up logrotate, which should be purging your logfiles under /var.
You may be retaining more files than you want.

Check carefully what yum says it is going to delete before confirming or you may break your system.

As snowpine said though, disks these days are very cheap; I think the default is prob 500GB, maybe 1TB by now.

PS: that pkg dir is non-std; can you do an ls in there.
Did you setup this system yourself?
Does it normally have internet access?
It's possible that whoever set it up copied the pkgs from the install media onto the HDD.
If you do have internet access normally, then that would be redundant.

Last edited by chrism01; 02-13-2012 at 09:26 PM.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
partition space and disk space usage and free don't match nsic Linux - Newbie 3 02-22-2013 01:57 PM
[SOLVED] How to clean up disk space on /var partition RedHat5 LRL8793rh5 Linux - Newbie 4 05-13-2011 03:07 PM
clean up disk space in SuSE linux nanda22 Linux - Newbie 5 08-01-2008 06:37 AM
Running out of disk space... clean up possible? donv2 Linux - Newbie 3 04-19-2005 03:48 AM
resizing linux partitions to free up space for window$ - safe or clean install? dianat100 Linux - Newbie 5 03-09-2005 01:05 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:07 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration