The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Major OS errors/Bash errors help!!!! wcmmlynn UNIX for Dummies Questions & Answers 12 11-13-2007 01:50 AM
stty tcgetattr errors Student37 UNIX for Dummies Questions & Answers 8 04-26-2007 10:02 AM
Adapter Errors and Link Errors mcastill66 AIX 2 08-02-2005 03:51 PM
Adapter Errors and Link Errors mcastill66 UNIX for Advanced & Expert Users 0 08-02-2005 03:11 PM
stty frank UNIX for Dummies Questions & Answers 1 11-08-2002 08:49 AM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1  
Old 02-06-2006
Registered User
 

Join Date: Jun 2004
Posts: 146
stty errors

Hi folks,

I run a script in rsh on HP-UX v2 (B.11.23 U 9000/800) and each time I have "su - user" in my program I'm getting the following output on the screen:
Code:
stty: : Unknown error
process not attached to terminal
Usage:  who [-rbtpludAasHTqRmW] [am i] [utmp_like_file]

r       run level
b       boot time
t       time changes
p       processes other than getty or users
l       login processes
u       useful information
d       dead processes
A       accounting information
a       all (rbtpludA options)
s       short form of who (no time since last output or pid)
H       print header
T       status of tty (+ writable, - not writable, x exclusive open, ? hung)
q       quick who
R       print host name
W       print Entries in wtmps
Any suggestions how to overcome it?

Thanks in advance,
Nir
Reply With Quote
Forum Sponsor
  #2  
Old 02-06-2006
blowtorch's Avatar
Supporter
 
Join Date: Dec 2004
Location: Singapore
Posts: 2,326
Are you running this script through cron? If yes, the problem could be this: When you do 'su - user', the user's profile files are parsed. There could be commands in the profile that require to be run from a terminal.
Reply With Quote
  #3  
Old 02-06-2006
Registered User
 

Join Date: Jun 2004
Posts: 146
This script is not run by cron.
The "su" user is ias and its .cshrc looks as the following:
Code:
if ($?prompt) then
set nobeep
set history=50
set savehist=50
set system='hostname'
stty erase ^h
set filec
set noclobber ignoreeof
if ( `who am i | wc -w` >= 5 ) then
   setenv DISPLAY `who am i | cut -d"(" -f2 | cut -d")" -f1`
endif
endif
setenv ORACLE_BASE /home/ias
setenv ORACLE_HOME $ORACLE_BASE/v10.1.2
setenv ORACLE_SID DB10g
setenv ORACLE_TERM vt100
setenv NLS_LANG AMERICAN_AMERICA.UTF8
setenv LD_LIBRARY_PATH $ORACLE_HOME/lib:/usr/lib:$ORACLE_HOME/webcache/lib
setenv LD_LIBRARY_PATH $ORACLE_HOME/Apache/Apache/libexec:$LD_LIBRARY_PATH
setenv LD_LIBRARY_PATH $ORACLE_HOME/icache/lib:$LD_LIBRARY_PATH
setenv LD_LIBRARY_PATH $ORACLE_HOME/6iserver/reports60/lib:$LD_LIBRARY_PATH
setenv LD_LIBRARY_PATH $ORACLE_HOME/6iserver/forms60/lib:$LD_LIBRARY_PATH
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 01:16 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0