Questions tagged [diskspace]

Issues relating to availability of disk space.

Questions using this tag are expected to be related to handling disk space issues, regardless of language and system.

749 questions
512
votes
7 answers

Is it okay to delete the macOS Xcode CoreSimulator devices folder?

My ~/Library/Developer/CoreSimulator/Devices folder is 26 GB. Is it safe to just delete all the content? Will those files be automatically regenerated?
Franck
  • 8,939
  • 8
  • 39
  • 57
284
votes
9 answers

Android SDK folder taking a lot of disk space. Do we need to keep all of the System Images?

There are a lot of system images piling up on my disk in the android sdk folder. i hardly use the emulator. May be once in 6 months. Most of my development is directly on device. What i wanted to check was, will removing the system images (at least…
Viral Patel
  • 32,418
  • 18
  • 82
  • 110
206
votes
12 answers

How do I monitor the computer's CPU, memory, and disk usage in Java?

I would like to monitor the following system information in Java: Current CPU usage** (percent) Available memory* (free/total) Available disk space (free/total) *Note that I mean overall memory available to the whole system, not just the JVM. I'm…
David Crow
  • 16,077
  • 8
  • 42
  • 34
156
votes
19 answers

How to detect total available/free disk space on the iPhone/iPad device?

I'm looking for a better way to detect available/free disk space on the iPhone/iPad device programmatically. Currently I'm using the NSFileManager to detect the disk space. Following is the snippet of the code which does the job for…
Code.Decode
  • 3,736
  • 4
  • 25
  • 32
117
votes
14 answers

Why is docker image eating up my disk space that is not used by docker

I have setup docker and I have used completely different block device to store docker's system data: [root@blink1 /]# cat /etc/sysconfig/docker # /etc/sysconfig/docker other_args="-H tcp://0.0.0.0:9367 -H unix:///var/run/docker.sock -g…
ming.kernel
  • 3,365
  • 3
  • 21
  • 32
116
votes
14 answers

Android get free size of internal/external memory

I want to get the size of free memory on internal/external storage of my device programmatically. I'm using this piece of code : StatFs stat = new StatFs(Environment.getExternalStorageDirectory().getPath()); long bytesAvailable =…
Android-Droid
  • 14,365
  • 41
  • 114
  • 185
111
votes
9 answers

Docker container logs taking all my disk space

I am running a container on a VM. My container is writing logs by default to /var/lib/docker/containers/CONTAINER_ID/CONTAINER_ID-json.log file until the disk is full. Currently, I have to delete manually this file to avoid the disk to be full. I…
poiuytrez
  • 21,330
  • 35
  • 113
  • 172
107
votes
11 answers

Docker filling up storage on macOS

(Post created on Oct 05 '16) I noticed that every time I run an image and delete it, my system doesn't return to the original amount of available space. The lifecycle I'm applying to my containers is: > docker build ... > docker run CONTAINER_TAG >…
Franco Rabaglia
  • 1,163
  • 2
  • 9
  • 9
102
votes
13 answers

Get free disk space

Given each of the inputs below, I'd like to get free space on that location. Something like long GetFreeSpace(string path) Inputs: c: c:\ c:\temp \\server \\server\C\storage
bh213
  • 6,343
  • 9
  • 43
  • 52
96
votes
8 answers

ElasticSearch find disk space usage

How can I find the amount of disk space that Elastic Search is using for my indexes? I'm currently running it locally and I'm trying to see how much disk space I will need on the VM that I'll be spinning up.
Nived
  • 1,804
  • 1
  • 15
  • 29
90
votes
12 answers

Find size and free space of the filesystem containing a given file

I'm using Python 2.6 on Linux. What is the fastest way: to determine which partition contains a given directory or file? For example, suppose that /dev/sda2 is mounted on /home, and /dev/mapper/foo is mounted on /home/foo. From the string…
Federico A. Ramponi
  • 46,145
  • 29
  • 109
  • 133
83
votes
2 answers

du counting hardlinks towards filesize?

I have a backup system that creates directories named after Unix Timestamps, and then creates incremental backups using a hardlink system (--link-dest in rsync), so typically the first backup is very large, and then later backups are fractions as…
Dan LaManna
  • 3,431
  • 4
  • 23
  • 35
77
votes
4 answers

How to find how much disk space is left using Java?

How to find how much disk space is left using Java?
Roman Kagan
  • 10,440
  • 26
  • 86
  • 126
76
votes
12 answers

Cross-platform space remaining on volume using python

I need a way to determine the space remaining on a disk volume using python on linux, Windows and OS X. I'm currently parsing the output of the various system calls (df, dir) to accomplish this - is there a better way?
Justin Waddell
76
votes
6 answers

Postgresql find total disk space used by a database

I have more than 50 databases hosted in my postgresql server. I need to move some of them on another host, to free-up some disk space,but how can I measure the disk-space used by each database on my volume? Is there any function exists to get the…
pylover
  • 7,670
  • 8
  • 51
  • 73
1
2 3
49 50