[tex-live] strange changing permissions
George N. White III
gnwiii at gmail.com
Mon Mar 22 12:20:29 CET 2010
On Sun, Mar 21, 2010 at 6:58 PM, Adam R. Maxwell <amaxwell at mac.com> wrote:
> On Mar 21, 2010, at 2:34 PM, George N. White III wrote:
>> On Fri, Mar 19, 2010 at 6:39 PM, Adam R. Maxwell <amaxwell at mac.com> wrote:
>>> On Mar 19, 2010, at 4:17 AM, George N. White III wrote:
>>>> If we keep TL under a normal user ownership, console users with
>>>> admin rights can still do TL admin as on a personal Mac, we just have
>>>> to revert ownership (using sudo) before doing tladmin. Running one
>>>> "chown" is a small fraction of the potential for damage that you could
>>>> get from a bug or intentional hack in one of the many TL admin tools.
>>> That makes sense, but who or what is changing the ownership such that you have to use chown?
>> If a user (probably has to be one with admin privs, but that is
>> normally the "owner" of the system)
>> does an update with the MacTeX GUI the permissions revert to ownership
>> by root (as will most
> Thanks for clarifying! Just to be sure, the "owner" does not have write privs to /usr/local/texlive? I assume "the MacTeX GUI" is TeX Live Utility, so I'd like to improve this if possible (I wrote it).
The owner gets write privs to everything by virtue of being an
administrator. The ssh users are generally not
in the admin group.
Mac TeX has a different GUI that runs tlmgr in non-gui mode.
We could easily put the owner in "tladmin" group with write privs on
/usr/local/texlive, but currently MacTeX uses a
"TeX Live Utility.app" that prompts for an admin login and then runs
tlmgr as root. The Apple GUI apps aren't
available in ssh terminal sessions.
> If you were to create a group that had write privs to /usr/local/texlive and added the ssh and console users to that group, TLU would not ask for admin rights, and wouldn't be running tlmgr as root. Consequently, you shouldn't have to do this chown dance.
> Another possible solution would be to add a preference setting to TLU to use a specific owner and group. I think I could do this by reading owner/group of the directory at `kpsewhich -var-value=SELFAUTOPARENT` and calling setuid() appropriately, if you checked a box for "Run as install directory owner" or something. Other suggestions are welcome.
On most Apple systems "tlmgr --gui" won't run due to problems with the
gwhite@<apple1>:~$ tlmgr --gui
Cannot load Tk, thus the GUI cannot be started!
The Perl/Tk module is not shipped with the TeX Live installation.
You have to install it to get tlmgr GUI running. See
http://tug.org/texlive/distro.html for more details.
Tried that -- once upon a time it actually worked, but after a few updates:
gwhite@<apple2>:~$ tlmgr --gui
no event type or button # or keysym at
/Library/Perl/5.8.8/darwin-thread-multi-2level/Tk/Widget.pm line 1105.
at /usr/local/texlive/2009/texmf/scripts/texlive/tlmgrgui.pl line 222
Compilation failed in require at /usr/texbin/tlmgr line 3126.
On Apple the "TeX Live Utility.app" also creates links in "system"
directories. This allows the admin to switch
the default TeX distro:
gwhite@<apple>:~$ which tex
gwhite@<apple>:~$ ls -l /usr/texbin
8 lrwxr-xr-x 1 root wheel 63 Nov 19 15:03 /usr/texbin@ ->
gwhite@<apple>:~$ ls -l /Library/TeX/Distributions/
0 drwxr-xr-x 3 root admin 102 Apr 7 2009 Fink-teTeX.texdist/
0 drwxr-xr-x 3 root admin 102 Apr 7 2009 MacPorts-teTeX.texdist/
64 -rw-r--r--@ 1 root admin 31302 Apr 7 2009 TeXDist-description.rtf
0 drwxr-xr-x 3 root admin 102 Apr 7 2009 TeXLive-2008.texdist/
0 drwxr-xr-x 3 root admin 102 Nov 19 15:03 TeXLive-2009.texdist/
0 drwxr-xr-x 3 root admin 102 Apr 7 2009 gwTeX-2003-2005.texdist/
gwhite@<apple>:~$ ls -l /Library/TeX/Distributions/.DefaultTeX
8 lrwxr-xr-x 1 root admin 32 Nov 19 15:03 Contents@ ->
MacTeX is more like using a linux distro install of TL that follows
distro-specific conventions, but
with the difference that tlmgr is still being used.
George N. White III <aa056 at chebucto.ns.ca>
Head of St. Margarets Bay, Nova Scotia
More information about the tex-live