dd@beta.lanl.gov (Dan Davison) (04/21/89)
I tried this once before and didn't get an answer, so here goes again. We have Gnu 18.53 under SOS (Sun OS) 4.0.1. When users invoke display-time, the modeline says "time and load" briefly, then displays only the time. If the superuser runs Gnu it *does* display the time and load. What's wrong? Is there something obvious I've missed? Thanks in advance, dan davison/theoretical biology/t-10 ms k710/los alamos national laboratory los alamos, nm 875545/dd@lanl.gov (arpa)/dd@lanl.uucp(new)/..cmcl2!lanl!dd -- dan davison/theoretical biology/t-10 ms k710/los alamos national laboratory los alamos, nm 875545/dd@lanl.gov (arpa)/dd@lanl.uucp(new)/..cmcl2!lanl!dd
gangolli@wolvesden.Stanford.EDU (Anil R. Gangolli) (04/21/89)
In article <24241@beta.lanl.gov> dd@beta.lanl.gov (Dan Davison) writes: >I tried this once before and didn't get an answer, so here goes again. > >We have Gnu 18.53 under SOS (Sun OS) 4.0.1. When users invoke >display-time, the modeline says "time and load" briefly, then displays >only the time. If the superuser runs Gnu it *does* display the time >and load. > >What's wrong? Is there something obvious I've missed? In the emacs etc library, the program loadst that gets the load info for display-time needs to have access to kernel memory (/dev/kmem). To give it this access: 1) become superuser 2) use chgrp to put loadst in the group kmem (this should be the group to which the file /dev/kmem belongs). 3) Then do "chmod g+s loadst". This says, when loadst runs, it will run with the access priveleges of its group, which you've just set to be kmem. Now things should work for non-superusers too. --anil.
ecphssrw@robin.csun.edu (Stephen Walton) (04/29/89)
The difficulty with display-time is that it shows the output of the program $emacs/etc/loadst, which reads /dev/kmem. Under 4.2+ BSD and similar Sun/OS releases, /dev/kmem became mode 640, owned by user root and group kmem, as a security feature. So, loadst must either be changed to not read /dev/kmem, or (as we've done here) installed as setgid kmem. -- Stephen Walton, Dept. of Physics & Astronomy, Cal State Univ. Northridge RCKG01M@CALSTATE.BITNET ecphssrw@afws.csun.edu swalton@solar.stanford.edu ...!csun!afws.csun.edu!ecphssrw