What is the difference between /usr/locale and /usr/local?

Solution 1:

In distributions like Ubuntu, /usr is where packages are supposed to install stuff and /usr/local is where the system administrator can install stuff outside the packaging system. From the Filesystem Hierarchy Standard:

The /usr/local hierarchy is for use by the system administrator when installing software locally. It needs to be safe from being overwritten when the system software is updated. It may be used for programs and data that are shareable amongst a group of hosts, but not found in /usr.

Locally installed software must be placed within /usr/local rather than /usr unless it is being installed to replace or upgrade software in /usr.

/usr/locale seems to be a mistake in packaging. It contains translations of text used by some Unity lenses, but those are supposed to go in /usr/share. For example, here's the directory structure of /usr/locale:

~ find /usr/locale
/usr/locale
/usr/locale/da
/usr/locale/da/LC_MESSAGES
/usr/locale/da/LC_MESSAGES/unity-lens-files.mo
/usr/locale/da/LC_MESSAGES/unity-lens-applications.mo

And in /usr/share/locale, one will find hundreds of such files:

$ find /usr/share/locale | head
/usr/share/locale
/usr/share/locale/tig
/usr/share/locale/tig/LC_MESSAGES
/usr/share/locale/tig/LC_MESSAGES/iso_639_3.mo
/usr/share/locale/tig/LC_MESSAGES/iso_3166.mo
/usr/share/locale/tig/LC_MESSAGES/iso_639.mo
/usr/share/locale/hsb
/usr/share/locale/hsb/kf5_entry.desktop
/usr/share/locale/hsb/LC_MESSAGES
/usr/share/locale/hsb/LC_MESSAGES/kjobwidgets5_qt.qm

Packages are not supposed to create more directories in the top level of /usr. This seems to be a harmless bug. You may report it if you feel like it.

Solution 2:

local means you local machine - files related to current machine only. you'll find a /usr/local/bin/ for local [company, employer|org etc] bins (not system or distro-releated installed which go in /bin or /sbin usually) but there may not be much there [esp. if a home pc]

locale means its related to your locale (geographical region) which include language, currency symbols etc. but may contain locate related files to other regions you interact with... if you want to see info that applies; enter the locale command and you'll get something like

LANG=en_AU.UTF-8 
LC_CTYPE="en_AU.UTF-8"
LC_NUMERIC="en_AU.UTF-8"
LC_TIME="en_AU.UTF-8"
LC_COLLATE="en_AU.UTF-8"
LC_MONETARY="en_AU.UTF-8"
LC_MESSAGES="en_AU.UTF-8"
LC_PAPER="en_AU.UTF-8"
LC_NAME="en_AU.UTF-8"
LC_ADDRESS="en_AU.UTF-8"
LC_TELEPHONE="en_AU.UTF-8"
LC_MEASUREMENT="en_AU.UTF-8"
LC_IDENTIFICATION="en_AU.UTF-8"
LC_ALL=