Re-partitioning and freeing up disk space

I’ve recently had an issue where my disk space filled up - my solution was to delete the snapshots and then install bitbleach. However, I don’t want this to happen again. This is my memory allocation:

df -h Filesystem Size Used Avail Use% Mounted on
/dev/mmcblk0p3 12G 9.1G 2.1G 82%
/ devtmpfs 941M 0 941M 0%
/dev tmpfs 949M 76K 949M 1%
/dev/shm tmpfs 949M 2.2M 947M 1%
/run tmpfs 949M 0 949M 0%
/sys/fs/cgroup /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/spool /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/.snapshots /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/tmp /dev/mmcblk0p1 156M 4.9M 152M 4%
/boot/efi /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/lib/pgsql /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/crash /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/lib/mailman /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/log /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/tmp /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/opt /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/usr/local /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/var/lib/named /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/boot/grub2/i386-pc /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/opt /dev/mmcblk0p3 12G 9.1G 2.1G 82% /srv /dev/mmcblk0p3 12G 9.1G 2.1G 82%
/boot/grub2/x86_64-efi /dev/mmcblk0p4 16G 895M 15G 6% /home

Actually, not hugely helpful as this shows the same memory allocation for several directories. How can I improve this information?

Is there an easy to allocate some of my /home space to other partition?

What can one do to make sure memory doesn’t fill up unexpectedly?

What steps can one take to free up disk space and is there a regular maintenance schedule you would suggest?

Thanks

i would suggest you give more details. by the look of it this look like part of a system stored on a memory card(mmcblk0p3)but correct me if I’m wrong. can you provide the output for fdisk -l as root? what version you are running? etc. the more details the more likely that someone will step in and try to help you.

BTRFS is odd in how it reports things in that it is divided in to sub volumes. All sub volumes use the same space available space. Also tmpfs are in memory so they all share the same available/free space

To keep snapper from gobbling up all the space change it’s setting and make it less aggressive in the number and frequency of it’s snapshots.If you don’t want to mess with it use ext4 FS and you can get buy with much smaller partitions.

On 2015-08-21 09:26, enquirer44 wrote:
>
> I’ve recently had an issue where my disk space filled up - my solution
> was to delete the snapshots and then install bitbleach. However, I don’t
> want this to happen again.

You have to disable snapshots, your “/” partition is too small.

> This is my memory allocation:

Please, next time use code tags to post that. The ‘#’ button in the
forum editor.


> df -h Filesystem  Size  Used Avail Use% Mounted on
> /dev/mmcblk0p3   12G  9.1G  2.1G  82%

> /dev/mmcblk0p4   16G  895M   15G   6% /home

> Is there an easy to allocate some of my /home space to other partition?

No, almost impossible. Better reinstall with different partition choices.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

#dmera - thanks - this is the query:

 fdisk -l

Disk /dev/mmcblk0: 29.1 GiB, 31268536320 bytes, 61071360 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 1E754952-2F3B-439C-BAF6-0CF275952BB6

Device            Start      End  Sectors  Size Type
/dev/mmcblk0p1     2048   321535   319488  156M EFI System
/dev/mmcblk0p2   321536  4530175  4208640    2G Microsoft basic data
/dev/mmcblk0p3  4530176 28547071 24016896 11.5G Microsoft basic data
/dev/mmcblk0p4 28547072 61069311 32522240 15.5G Microsoft basic data

Disk /dev/mmcblk0rpmb: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mmcblk0boot1: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mmcblk0boot0: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
                                                                                                                          

Can I delete any of these?

Thanks.

PS I have disabled snapper

On 2015-08-22 10:56, enquirer44 wrote:

> Code:
> --------------------
> fdisk -l
>
> Disk /dev/mmcblk0: 29.1 GiB, 31268536320 bytes, 61071360 sectors

Your disk is too small.

> --------------------
>
>
> Can I delete any of these?

Me, I would delete all and reinstall, using swap and a single “/”
partition, no “/home” partition. And I would use ext4. Perhaps btrfs
with COW disabled, if it is possible at all.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

#Carlos.

Thanks. My partitions now look like this:

fdisk -l  Disk /dev/mmcblk0: 29.1 GiB, 31268536320 bytes, 61071360 sectors 
Units: sectors of 1 * 512 = 512 bytes 
Sector size (logical/physical): 512 bytes / 512 bytes 
I/O size (minimum/optimal): 512 bytes / 512 bytes 
Disklabel type: gpt Disk identifier: 1E754952-2F3B-439C-BAF6-0CF275952BB6  

Device            Start      End  Sectors  Size Type 
/dev/mmcblk0p1     2048   321535   319488  156M EFI System 
/dev/mmcblk0p2   321536  4530175  4208640    2G Microsoft basic data 
/dev/mmcblk0p3  4530176 28547071 24016896 11.5G Microsoft basic data 
/dev/mmcblk0p4 28547072 61069311 32522240 15.5G Microsoft basic data  Disk 
/dev/mmcblk0rpmb: 4 MiB, 4194304 bytes, 8192 sectors 
Units: sectors of 1 * 512 = 512 bytes 
Sector size (logical/physical): 512 bytes / 512 bytes 
I/O size (minimum/optimal): 512 bytes / 512 bytes 
Disk /dev/mmcblk0boot1: 4 MiB, 4194304 bytes, 8192 sectors 
Units: sectors of 1 * 512 = 512 bytes 
Sector size (logical/physical): 512 bytes / 512 bytes 
I/O size (minimum/optimal): 512 bytes / 512 bytes 
Disk /dev/mmcblk0boot0: 4 MiB, 4194304 bytes, 8192 sectors 
Units: sectors of 1 * 512 = 512 bytes 
Sector size (logical/physical): 512 bytes / 512 bytes 
I/O size (minimum/optimal): 512 bytes / 512 bytes                                                                                                                                                                                                                                                                                                                                                                                                                                 

On 2015-08-23 09:56, enquirer44 wrote:
>
> #Carlos.
>
> Thanks. My partitions now look like this:

Please post this instead:


lsblk --output NAME,KNAME,SIZE,TYPE,MOUNTPOINT,LABEL,UUID,PARTLABEL,PARTUUID,SIZE


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

lsblk 
NAME         MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT 
mmcblk0rpmb  179:24   0    4M  0 disk  
mmcblk0boot0 179:8    0    4M  1 disk 
 mmcblk0boot1 179:16   0    4M  1 disk  
mmcblk0      179:0    0 29.1G  0 disk  
├─mmcblk0p1  179:1    0  156M  0 part /boot/efi 
├─mmcblk0p2  179:2    0    2G  0 part [SWAP] 
├─mmcblk0p3  179:3    0 11.5G  0 part / 
└─mmcblk0p4  179:4    0 15.5G  0 part                    

On 2015-08-23 19:06, enquirer44 wrote:
>
> Code:
> --------------------
> lsblk
> NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
> mmcblk0rpmb 179:24 0 4M 0 disk
> mmcblk0boot0 179:8 0 4M 1 disk
> mmcblk0boot1 179:16 0 4M 1 disk
> mmcblk0 179:0 0 29.1G 0 disk
> ├─mmcblk0p1 179:1 0 156M 0 part /boot/efi
> ├─mmcblk0p2 179:2 0 2G 0 part [SWAP]
> ├─mmcblk0p3 179:3 0 11.5G 0 part /
> └─mmcblk0p4 179:4 0 15.5G 0 part
>
> --------------------

That’s not what I asked for. You did not type the options to the
command, they are important.

However, another question. What is “mmcblk0p4” for? It appears unused. Why?


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

lsblk --output NAME,KNAME,SIZE,TYPE,MOUNTPOINT,LABEL,UUID,PARTLABEL,PARTUUID,SIZE NAME         KNAME         SIZE TYPE MOUNTPOINT LABEL UUID                                 PARTLABEL PARTUUID                              SIZE 
mmcblk0rpmb  mmcblk0rpmb     4M disk                                                                                                         4M 
mmcblk0boot0 mmcblk0boot0    4M disk                                                                                                         4M 
mmcblk0boot1 mmcblk0boot1    4M disk                                                                                                         4M 
mmcblk0      mmcblk0      29.1G disk                                                                                                      29.1G 
├─mmcblk0p1  mmcblk0p1     156M part /boot/efi        B91C-58D0                            primary   9e6d25c3-1216-4f86-863e-2566cddddd99  156M 
├─mmcblk0p2  mmcblk0p2       2G part [SWAP]           12202366-afa3-4619-aa03-1b14f85316d2 primary   6996d200-b82d-420d-8bc3-bc7760a121c3    2G 
├─mmcblk0p3  mmcblk0p3    11.5G part /                eb43ebc1-39af-4281-a4e1-7a8e8b84c001 primary   89f59514-68bb-46f3-94a8-b258d970cac7 11.5G 
└─mmcblk0p4  mmcblk0p4    15.5G part                  2a8d4eea-4398-4b89-a7cc-f0121ba03c63 primary   76937538-a5ad-4006-9d07-f3f594289dd2 15.5G

As for mmcblk0p4: it just set it up this way I suppose because the max partition size is 11.5G - I tired to change this but couldn’t it didn’t permit a custom partition larger than the 11.5G. So, guess it is not using it?

Appreciate your help -thanks.

On 2015-08-24 12:56, enquirer44 wrote:
>
> Code:
> --------------------
> lsblk --output NAME,KNAME,SIZE,TYPE,MOUNTPOINT,LABEL,UUID,PARTLABEL,PARTUUID,SIZE NAME KNAME SIZE TYPE MOUNTPOINT LABEL UUID PARTLABEL PARTUUID SIZE
> mmcblk0rpmb mmcblk0rpmb 4M disk 4M
> mmcblk0boot0 mmcblk0boot0 4M disk 4M
> mmcblk0boot1 mmcblk0boot1 4M disk 4M
> mmcblk0 mmcblk0 29.1G disk 29.1G
> ├─mmcblk0p1 mmcblk0p1 156M part /boot/efi B91C-58D0 primary 9e6d25c3-1216-4f86-863e-2566cddddd99 156M
> ├─mmcblk0p2 mmcblk0p2 2G part [SWAP] 12202366-afa3-4619-aa03-1b14f85316d2 primary 6996d200-b82d-420d-8bc3-bc7760a121c3 2G
> ├─mmcblk0p3 mmcblk0p3 11.5G part / eb43ebc1-39af-4281-a4e1-7a8e8b84c001 primary 89f59514-68bb-46f3-94a8-b258d970cac7 11.5G
> └─mmcblk0p4 mmcblk0p4 15.5G part 2a8d4eea-4398-4b89-a7cc-f0121ba03c63 primary 76937538-a5ad-4006-9d07-f3f594289dd2 15.5G
>
> --------------------
>
>
> As for mmcblk0p4: it just set it up this way I suppose because the max
> partition size is 11.5G - I tired to change this but couldn’t it didn’t
> permit a custom partition larger than the 11.5G. So, guess it is not
> using it?
>
> Appreciate your help -thanks.

Ok, I understand now. Although I forgot to tell you in that command line
to include “FSTYPE”. I hope it is ext4.

No, there is NO size limit for partitions. You just did not tell the
installer to destroy and use it. So, just start yast, partitioner, or
gparted, and -destroy-, or erase, partition number 4. (not reformat, but
remove)

Then, either reinstall, making sure that it uses the space of partition
3 and what was #4 (if not, erase both), or resize in the running system
partition 3 to reach the end of the disk.

Or, reinstall, making sure you tell the installer to use the ENTIRE
disk, without separate “/home.” That’s what I would do.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

OK. I now have this:

lsblk --output NAME,KNAME,SIZE,TYPE,MOUNTPOINT,LABEL,UUID,PARTLABEL,PARTUUID,SIZE NAME         KNAME         SIZE TYPE MOUNTPOINT LABEL UUID                                 PARTLABEL PARTUUID                              SIZE 
mmcblk0rpmb  mmcblk0rpmb     4M disk                                                                                                         4M 
mmcblk0boot0 mmcblk0boot0    4M disk                                                                                                         4M 
mmcblk0boot1 mmcblk0boot1    4M disk                                                                                                         4M 
mmcblk0      mmcblk0      29.1G disk                                                                                                      29.1G 
├─mmcblk0p1  mmcblk0p1     156M part /boot/efi        B91C-58D0                            primary   9e6d25c3-1216-4f86-863e-2566cddddd99  156M ├─mmcblk0p2  mmcblk0p2       2G part [SWAP]           12202366-afa3-4619-aa03-1b14f85316d2 primary   6996d200-b82d-420d-8bc3-bc7760a121c3    2G └─mmcblk0p3  mmcblk0p3    11.5G part /                ba59a889-34c4-43ca-9c95-d20a01ac1998 primary   89f59514-68bb-46f3-94a8-b258d970cac7 11.5G 

I’m not finding this that easy. The options in the set-up don’t seem that intuitive as error messages occur (eg when trying to use the max disk space it says can’t allow partition overlap…) what’s that all about?

What’s this part(?) above here under mmcblk0p3?

Thanks again.

On 2015-08-24 22:56, enquirer44 wrote:

> What’s this part(?) above here under mmcblk0p3?


mmcblk0p1     156M part /boot/efi
mmcblk0p2       2G part [SWAP]
mmcblk0p3    11.5G part /

Partition 1 is EFI, used for booting UEFI machines. It is very small.

Partition 2 is swap. If your machine is a laptop, and/or you intend to
hibernate it, then it must be the same size as your ram, or a bit more.

Partition 3 is where Linux is installed, and it should be about 26 GiB,
the rest of the disk. It is not. If you tell the installer to use the
entire disk, it should really use the entire disk.

If you try to edit partition sizes yourself, it can say that a partition
can not overlap another partition. That’s right, you can not. Think of
car parking slots: you can not paint the slot for a car using half of
another slot. What would you, have a car on top of another? Remove half
of the car body? :slight_smile:

There is an entry in the installer partition setup labelled something
like “use the entire disk”. That’s what you have to use.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

Thank you Carlos - now sorted but it’s not obvious. Had to fiddle around a bit. If I used ‘Entire Disk’ it created an unallocated partition. Anyway, thanks for sticking this out with me.

I like that. One can use that analogy even further to explain how a smaller car fits into a large slot and not the other way around. That it is not the slot that decides if the car is a van or a limousine. That it may be easy to adjust the slot (some paint), but that it is less easy to ajust the size of a car. And much more. I hope I remember this when I hit some people not understanding partitioning.

It probably created a separate home which is the normal openSUSE install default. But with such little space you need to take control and set things the way you want them not use the installer recommended partitioning. Remember it is just a program you must tell it what you want

On 2015-08-25 13:36, gogalthorp wrote:
>
> It probably created a separate home which is the normal openSUSE install
> default.

Yes, that was what he initially had, resulting in a very small btrfs
root partition. I told him to erase home and reinstall without home
partition, but apparently the installation took the same root partition,
leaving what was home as free partition space.

He has a 29 GB disk, IMO too small for having a separate home. Better
have a single root.

Thus I’m telling him to tell the installer to use the entire disk. There
is an option by that name, but I don’t have a photo.

…]

Ah, I see he said he finally could do it, somehow :slight_smile:


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))