Skip to content

How to handle a 10GB pacman update

I just got back from a 6 month study abroad in Sweden. It's time to update my PC. I apparently only have 1.9 GB left in root of 25 GB or so, but my pacman update requires 10GB of space. How can I handle this and/or chunk it up to make it manageable?

7 points23 comments
Open on Reddit
About this post
Posted
Archived
Score
7 · 100% up
Kind
Text
ID
ccgyug

Author

19
posts
77
comments
1
media
View profile

23 comments

I dont know why anyone else hasn't suggested that you get a flash drive. Not to boot from, but to mount as a pacman package cache. Grab a flash drive, mount it to /var/cache/pacman/pkg, and run your updates. You may have to move the directory that's already there, and make a new one as you can't mount on occupied dirs. The worst that happens is you have to do some extra file movement to get old packages in case you need to downgrade, so definitely move the dir, don't delete it. Edit: very late, slept for too long :c Just wanted to say thanks, kind person, for the gold!

40 points

This is the most unix-y answer I've read.

15 points

"limited disk space"? Just add more. But for real, the jump from C: and D:/ drives to a single tree with volumes mounted kinda wherever was a rough one. Once I started to understand how it worked, it became a magic bullet for so many of my (self inflicted) storage problems.

Afaik, doing many-disk installs like that (a volume for package cache, one for user files, others for others, etc , etc) is reasonably common among servers -- provided you aren't using fancier things like btrfs instead. I have no idea if it's that great an option on desktop/laptop systems, though. I imagine the biggest problem would be ensuring the disks mount appropriately, and you can still reach an emergency shell if it breaks for some reason. Not impossible, just extra work.

3 points

You can usually mount over non-empty directories with -o nonempty.

4 points

This. The files won't disappear, they just become inaccessible (although, file handles that are already open are not affected).

1 points

First, clear your pacman cache.

Second change your cachedir in pacman.conf. You can specify a partition where you do have enough room or even mount a usb drive and use that as a temporary cachedir.

Third update.

Good luck. Bear in mind updating a rolling release after 6 months may or may not lead to issues.

11 points

You could clean your pacman cache if you've exhausted all the other areas.

https://wiki.archlinux.org/index.php/pacman#Cleaning_the_package_cache

I'd consider reinstalling and partition better.

10 points

Type that 2 commands:

to free journalctl logs journalctl --vacuum-size=100M

to free pacman cache pacman -Sc

It should give you some free space without delete important things.

8 points

Warning: Not sure how evil this is regarding partial upgrades.

You could write a bash loop that takes the first line/package from checkupdates, upgrade it, clear cache, repeat.

6 points

Very evil.

Though you can do something like that either manually or with a bit of extra logic that upgrades independent dependency trees, if that's the only way out - anyway

5 points

Why ppl always left so small amount of space to /root????

1 points

If your /root needs more than a few kilobytes, you are probably doing something wrong.

5 points

What I did recently (10GiB update) was to free some space on my /home partition, reallocate it to / using a live cd and after the update I'd just undo those partition changes

1 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.