On Tuesday 16 August 2022, J Leslie Turriff wrote:
On 2022-08-15 13:21:47 Per Jessen wrote:
|Siard wrote: |> /usr/local/bin is owned by root with permissions 755, so as a user I |> cannot put a script in there. |> |> I can change the ownership, but every time after a reboot it is owned |> by root again, with permissions 755. |> |> Does anyone know where this is set, and/or how I can make |> /usr/local/bin permanently make writable for a user? | |It isn't meant to be. /usr/local is for local stuff, i.e. not vendor or |system.
Indeed. I have a separate partition mounted at /usr/local, where I keep stuff that I want to preserve across installation events. I have set the permissions the same way as /tmp has, so that I can put stuff there without having to change to root.
I used to do that for the same reason. In more recent years I've kept all the preservable stuff in the one filesystem so local is now a bind mount our of home: LABEL=home /home ext4 noatime,user_xattr 1 2 /home/local /usr/local none bind,user_xattr,noatime 0 0 This simplifies space management, backups, and migration. I generally leave things in local as owned by root, they are mainly local scripts for backups and other maintenance. I add sub-folders to /usr/local owned by me for software I look after, for example all my developments tools are under /usr/local/toolset/ which is owned by me. I also create specific product folders, also own by me, for example, I install SweetHome3D direct from tar.gz into /usr/local/SweetHome3D. Michael