[K12OSN] profile.d question

Henry Burroughs hburroughs at HHPREP.ORG
Tue Dec 7 17:28:51 UTC 2004

For some reason it sounds like your /etc/profile.d/ directory entries
are not running.  What version of K12LTSP are you running?  I run the
script on 4.1.   Try running /etc/profile.d/setprinter.sh as a program
under your terminal.  It should return back the prompt with no output.  
Check for SETPRINTERS next (via printenv or echo $SETPRINTER). Even if
the DISPLAY is not set properly (I haven't tested this on VNC, probably
won't change the printer on a VNC connection), it should still set the
environmental variable SETPRINTERS.

You are checking for SETPRINTERS, not SETPRINTER (I wrote the command
wrong in previous e-mail).

Sorry it took me so long to respond.. I got swamped.


On Sat, 2004-12-04 at 07:31, dahopkins at comcast.net wrote:
> Henry,
> I had set the script to be executable, logged out/in,  and it just doesn't seem to matter.  Starting  a bash shell and  checking SETPRINTERS shows that the variable isn't getting set.  All I can think of at this point is perhaps DISPLAY isn't being returned like the script wants?  In that case, perhaps the script is running, but not finding any matches?  I use LDAP for authentication (shouldn't make a difference, but ...) 
> I plan to go in to the school this weekend and will double check on it then.  
> Thanks,
> Dave ...
> > Dave,
> > 
> > I wrote the script you are using on the Wiki (Thanks Petre for getting that on 
> > there).  When run, the script should set an environmental variable called 
> > SETPRINTERS.  If you log into a client (with the script in /etc/profile.d/ at 
> > least), that variable should get set.  Just run "echo $SETPRINTER" and it should 
> > say that it is =true... If that isn't there, then for some reason your profile.d 
> > scripts aren't running... hmm... did you make the script executable?  run "ls -l 
> > setprinter.sh" while in the /etc/profile.d/ directory and make sure you have the 
> > "x" bits set, otherwise the script will not run.  Run "chmod a+x setprinter.sh" 
> > in the profile.d directory again.  Try loging in again and see if the variable 
> > is set. =)
> > 
> > Henry
> > 
> > 
> > -----Original Message-----
> > From:	dahopkins at comcast.net [mailto:dahopkins at comcast.net]
> > Sent:	Fri 12/3/2004 2:00 PM
> > To:	K12LTSP
> > Cc:	
> > Subject:	[K12OSN] profile.d question
> > It is Friday, so I get to try and troubleshoot printer problems again.
> > 
> > Speciifically, I am trying to get the script on the wiki.for setting the default 
> > printer to work.  I have created the profile.d entry, and the /etc/sysconfig 
> > entry.  But, no luck.  If I run lpoptions from a shell, it works fine.  So ... 
> > when do scripts in /etc/profile.d get executed and does it depend on what shell 
> > the user has defined?  I have also tried the script that uses awk to set the 
> > PRINTER variable, but it likewise doesn't work for me.  I am sure the solution 
> > is simple, I just can't find it.  
> > 
> > Sincerely,
> > Dave Hopkins
> > Newark Charter School
> > 
> > 
> > 
> > 
> > 
> > 
> > _______________________________________________
> > K12OSN mailing list
> > K12OSN at redhat.com
> > https://www.redhat.com/mailman/listinfo/k12osn
> For more info see <http://www.k12os.org>
> ______________________________________________________________________
> From: "Burroughs, Henry" <HBurroughs at HHPREP.ORG>
> To: Support list for opensource software in schools.
> <k12osn at redhat.com>, dahopkins at comcast.net
> Subject: RE: [K12OSN] profile.d question
> Date: Fri, 03 Dec 2004 23:39:31 +0000

More information about the K12OSN mailing list