Solved Where does `pkg install` extracts packages?

I've been attempting to run FreeBSD off USB stick and to speed things up moved my /var to fast NVMe SSD and /tmp to in-memory tmpfs. Sadly, package extraction phase during pkg install still takes forever. Does pkg extract to somewher in / or /usr or smth?

End of the day I can move everything to SSD but as a temp workaround would there be a way to manually tar -xf fetched package and then install it from that directory? So:
Code:
tar -xf /var/cache/pkg/binutils-2.33.1_4,1.txz -C /tmp/binutils
cd /tmp/binutils
pkg install ???
 
Does pkg extract to somewher in / or /usr or smth?
Look at pkg info -l <packagename>. All packages are third party software, so they'll all install in LOCALBASE aka /usr/local. Some packages may create directories in /var/log and/or /var/run/ but that's really not where the bulk of a package goes, those are really only important for logging and storing things like PID files. The MySQL/MariaDB packages for example will create a /var/db/mysql directory but it's not going to be filled with data until you actually run the service for the first time.
 
oh hell ... so I guess those are just tar files with filetree inside, so most package installation amounts to untarring to / and it'll populate /usr/local/... as needed?
Thank you for that command. I followed by then actually looking at contents of ath txz package :)

PS: thank you for moving thread to appropriate forum
 
so most package installation amounts to untarring to / and it'll populate /usr/local/... as needed?
That's the gist of it, yes. It does a few other things but those are more related to "housekeeping" (like registering the package in the package database for example).
 
Back
Top