[comp.unix.ultrix] Fixing the rlogin problem on DEC3100 running ultrix 4.1

brendan@cs.widener.edu (Brendan Kehoe) (06/26/91)

jroyea@itu203.kodak.com wrote:
>amit@osceola.cs.ucf.edu (Amit Jain) writes:
>> The problem is when I rlogin from the DECstation to one of the
>> sun-4's it seems to hang.
>
>I would like to hear about it also.  I am using a DECstation 5000-200 running
>ULTRIX 4.2, and I am having the same problem.  Thanks.

 I also had this problem on a DS3100 running Ultrix 4.1.
 My solution was to get the rlogin source from
	uunet.uu.net:/bsd-sources/usr.bin/rlogin
 and build it on the DecStation. It only needed one tiny tweak (and a
 declaration of a function, for cleanliness), and it works like a
 charm. I linked it with the BSD resolv library from bind 4.8.3, too,
 just to be `pure' about it.

 This doesn't fix or diagnose the problem; merely takes it out of the
 limelight of those users that have to get bitten by it. Now you can
 diagnose the why whilst they use it.

-- cut --
*** rlogin.c.~1~	Wed Jun 26 10:05:29 1991
--- rlogin.c	Wed Jun 26 10:15:35 1991
***************
*** 113,119 ****
  	int argoff, ch, dflag, one, uid;
  	char *host, *p, *user, term[1024];
  	void lostpeer();
! 	char *getenv();
  
  	argoff = dflag = 0;
  	one = 1;
--- 113,119 ----
  	int argoff, ch, dflag, one, uid;
  	char *host, *p, *user, term[1024];
  	void lostpeer();
! 	char *getenv(), *rindex();
  
  	argoff = dflag = 0;
  	one = 1;
***************
*** 272,280 ****
--- 272,282 ----
  	    setsockopt(rem, SOL_SOCKET, SO_DEBUG, &one, sizeof(one)) < 0)
  		(void)fprintf(stderr, "rlogin: setsockopt: %s.\n",
  		    strerror(errno));
+ #ifdef IP_TOS
  	one = IPTOS_LOWDELAY;
  	if (setsockopt(rem, IPPROTO_IP, IP_TOS, (char *)&one, sizeof(int)) < 0)
  		perror("rlogin: setsockopt TOS (ignored)");
+ #endif
  
  	(void)setuid(uid);
  	doit(omask);

-- cut --


-- 
     Brendan Kehoe - Widener Sun Network Manager - brendan@cs.widener.edu
  Widener University in Chester, PA                A Bloody Sun-Dec War Zone
Top Ten Surprises in Rocky V -- Number 5, Loveable Character Chewbacca Dies