[SunHELP] tcgetattr/ttcompat: No such device ar address

Nicholas Dronen sunhelp at sunhelp.org
Fri Jun 22 15:10:34 CDT 2001


On Fri, Jun 22, 2001 at 02:52:02PM -0400, Amy Lyubitska wrote:
> Hi, everybody!
> This is the error message i see every time my cronjob that executes rlogin
> to another machine fails:
> 
> tcgetattr: No such device or address
> ioctl I_FIND ttcompat: No such device or address
> 
> I am running Solaris 2.7 on Sun Ultra 60
> Thanks in advance to everyone who finds time to reply.

$ man tcgetattr

C Library Functions                                  tcgetattr(3)

NAME
     tcgetattr - get the parameters associated with the terminal

SYNOPSIS
     #include <termios.h>

     int tcgetattr(int fildes, struct termios *termios_p);

[ snip ]

ERRORS
     The tcgetattr() function will fail if:

     EBADF     The fildes argument is not a valid  file  descrip-
               tor.

     ENOTTY    The file associated with fildes is not a terminal.

If you run a process that *expects* a controlling terminal from cron,
at, whatever, it's possible that the process will generate errors such
as posted by you.  The first argument to tcgetattr() is a file descriptor,
and that desciptor (when rlogin is run from cron) is not associated with
a controlling terminal device.  Since there is no terminal information to
put into struct termios *termios_p, the system call fails with an errno
of ENOTTY, to let the caller know why it failed.

If your rlogin arrangement is otherwise satisfactory to you, you can
choose -- probably safely, even -- to ignore the errors. :-)

Regards,

Nicholas



More information about the SunHELP mailing list