Centos 6x 7 hd loss after deleting files

vegas

Account Disabled
Hello once you delete a file or folder its giga value is not available as a free space on centos 6x or 7 ,the hd that should be released as free space is lost,do you know why?
 
No it wasnt via ssh it was deleted as a desktop computer,if you have any clues really appreciate ur help
 
Someone with exprience on Centos can be of good assistance in telling me why my disc shrinks while deleting files
 
Hi,

There may be possibility that some port of it has remained in the memory and because of this the disk space scenario is not updating. Try command like the below one:

# lsof | grep deleted

Check if you see any files in it and what service it was utilized by, probably restarting the service will do the job.

Give it a try.
 
You need to try the last two and update this post for us to try to help further. If it was resolved you still could say so and share what you did.
 
System reboot should do the work. If it's not working, then you should open your terminal & use the following command to check if any service is using your disk instead.

# lsof | grep deleted
 
Can you tell us more about the type of file you deleted?

If it's related to a running service, it's probably not been replaced as others have mentioned. Make sure nothing is accessing that file and that it's not in the .Trash for your desktop user profile.

Update us with your results.
 
In Unix if you have to delete a large file because you need the space, but it might be owned by a running service, then you should proceed your delete command with a "cat /dev/null"

i.e.

/bin/cat /dev/null > filename.txt

This will ensure that the file, is truncated to 0 bytes and the space is returned to the filesystem.

You can then delete it with the usual tools (with or without success) afterwards.

I appreciate that this is a little late, and most admins know to do this, but it's something we often overlook and then regret.
 

Forum statistics

Threads
80,955
Messages
248,490
Members
20,683
Latest member
tombarko8
Top