Solved

networking in unix

Posted on 2000-05-17
7
228 Views
Last Modified: 2013-12-23
Through telnet connection, i want to login to a unix server and i want that it should always connect to the server with a particular ttyp terminal. It means that whenever i try to telnet from counter no 1 and get connected with the server, it should always connect as ttyp01 only. Likewise from ctr no 2, it should always connect as ttyp02 only. How to implement it in case of SCO unix 5.0.5 server. Please reply as soon as possible. Thanking you,

Regards
0
Comment
Question by:roy_bk100
  • 3
  • 3
7 Comments
 
LVL 20

Expert Comment

by:tfewster
Comment Utility
telnetd allocates pseudo-ttys dynamically and will free them up for re-use when a client disconnects; You could try disabling this by specifying the -n option to telnetd in /etc/inetd.conf

If these are dumb terminals on a terminal server, you may be able to configure the termserver to keep the connection alive. It may even support rtelnet, which _does_ allow you to fix tty numbers by initiating the connection from the server.

Otherwise, if the server is rebooted, all connections will be lost and the ttys would be reallocated as users connected.

What is the requirement behind this question? It may be easier to set an environment variable dependent on the user ID if a user always logs on to a particular terminal, and send messages etc. to the device based on that variable.

0
 

Author Comment

by:roy_bk100
Comment Utility
The requirement is exactly like as mentioned by you in the last para of the reply. A particular user ID should be able to connect only from a particular user and he should always be allocated the same tty. I think now i am clear in my question.
  waiting for your early reply,
0
 
LVL 14

Expert Comment

by:chris_calabrese
Comment Utility
What's the problem you're actually trying to solve?  Is it related to reattaching to an existing "session"?  If so, you'd should look at 'screen'.
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 

Author Comment

by:roy_bk100
Comment Utility
I want to know "Can a specific tty be allotted to a client as per the IP address of the client?". If yes, then how?
0
 
LVL 14

Expert Comment

by:chris_calabrese
Comment Utility
Yes, a specific tty can be allocated to a client as per the IP address of the client.  However, to do this you will have to hack telnetd (source available from the various Linux and BSD sites) to keep a table of the allocations and then try to assign the same tty as was used the last time.  This requires significant programming skills.
0
 

Author Comment

by:roy_bk100
Comment Utility
It could not solve the pupose. Simply saying yes could not explain how.
0
 
LVL 14

Accepted Solution

by:
chris_calabrese earned 70 total points
Comment Utility
I believe I have explained how.  You start with the source code to telnetd and hack it to keep a state file with the associations between client IP's and tty's and try to re-use the same ones.

Since they may already be in use, you have to decide what to do if you can't allocate the one you want (perhaps use a range for each client).

Also, unless you have an SCO source license, you'll first have to port one of the oepn source telnetd's.

I'm not saying this is easy.  In fact, I'm saying it's very difficult.  However, I am saying this is the easiest way to accomplish what you want and that it definitely will work.

"Sometimes when you fill a vacuum it still sucks."
  - Brian Kernighan on X Windows
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

This is an article about my experiences with remote access to my clients (so that I may serve them) and eventually to my home office system via Radmin Remote Control. I have been using remote access for over 10 years and have been improving my metho…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now