Carrier Detection in Solaris 8 for Dial in and Null Modem Connections | Unix Linux Forums | Solaris

  Go Back    


Solaris The Solaris Operating System, usually known simply as Solaris, is a Unix-based operating system introduced by Sun Microsystems. The Solaris OS is now owned by Oracle.

Carrier Detection in Solaris 8 for Dial in and Null Modem Connections

Solaris


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 06-13-2013
rstor rstor is offline
Registered User
 
Join Date: Jun 2013
Last Activity: 16 June 2013, 2:33 PM EDT
Posts: 7
Thanks: 2
Thanked 0 Times in 0 Posts
Carrier Detection in Solaris 8 for Dial in and Null Modem Connections

I am having troubles with carrier detection for dialing in via a modem or direct connection via a null modem connection under Solaris 8 (i.e. login session remains active after the modem disconnects). I tried two different dumb modems (which do not respond to AT commands) on the machine that I am dialling into . I tested the CD output on one of the modems and found the appropriate voltage on the CD line when a carrier is detected/not detected (I have confirmed this using a volt meter and applying the appropriate carrier tone via a function generator). If you dial in, login, then hang up, and call back the previous session continues without prompting to login.

I then decided to try a null modem connection. When accessing the serial console on the Solaris 8 system using a null modem cable, the login session remains active when disconnecting the cable and plugging it back in. To my understanding this should not happen, in the first case with the modem, or with the null modem cable as I disabled software carrier detection:


Code:
eeprom ttya-ignore-cd=true  
eeprom ttya-rts-dtr-off=true

Also I've specified the -S n parameter to disable software carrier detection:


Code:
/usr/sbin/pmadm -a -p zsmon -s ttya -i root \
-v `/usr/sbin/ttyadm -V` -fu -m "`/usr/sbin/ttyadm \
-p "login:" -d /dev/term/a -s /usr/bin/login -l contty2H from  -b \
-S n -m ldterm,ttcompat`" -y "dial in/out on serial port"


The instructions that I followed to setup the dial in connection was from Celeste Stokely’s Tutorial on Solaris 2.x Modems and Terminals.

I decided to test out carrier detection on FreeBSD 9.1 on a different machine running within virtual box. I used a usb-serial dongle which shows up as ttyu0 on the BSD machine. Carrier detection appears to work. When I establish a null modem connection (using the same null modem cable that I tried on the Solaris machine) I receive a login prompt. If I login, and then unplug and plug back the null modem cable, I get the login prompt again and the old session does not continue.

I have read a post on-line about carrier detection in Solaris not working and being "broken".

It this correct? Is carrier detection a known bug/issue in Solaris 8?

Last edited by Scott; 06-13-2013 at 05:52 PM.. Reason: Please use code tags
Sponsored Links
    #2  
Old 06-13-2013
DGPickett DGPickett is offline Forum Advisor  
Registered User
 
Join Date: Oct 2010
Last Activity: 15 October 2014, 5:08 PM EDT
Location: Southern NJ, USA (Nord)
Posts: 4,455
Thanks: 8
Thanked 546 Times in 524 Posts
A null modem is two cable heads and some wires. You can force CD true all the time with wiring it to DTR on the other side (if the other side powers off, there is no carrier). Wiring plans vary. Similar rules apply to other leads. Wiring varies to simulate a half duplex switched carrier modem as opposed to a full duplex continuous carrier modem. With the right wiring, it should be a rock. https://en.wikipedia.org/wiki/Null_modem Two DTE's, each pretending to be DCE to the other. https://en.wikipedia.org/wiki/RS-232
Sponsored Links
    #3  
Old 06-13-2013
rstor rstor is offline
Registered User
 
Join Date: Jun 2013
Last Activity: 16 June 2013, 2:33 PM EDT
Posts: 7
Thanks: 2
Thanked 0 Times in 0 Posts
@DGPickett

When using the null modem cable on the FreeBSD machine to another computer terminal, I receive the login prompt when the null modem cable is connected, and when I login, and then disconnect the cable and reconnect the cable again I receive the login prompt again. It appears the getty process in FreeBSD is detecting the carrier loss when the cable is disconnected and ending the previous login session. This is the correct behaviour to my understanding.

However on the Solaris system, when the null modem cable is connected to another computer terminal, if I login, and then disconnect the cable and then connect it back again I am still logged in at the shell. This means that on the Solaris machine it did not detect the carrier loss when the null modem cable was disconnected.

Since I have tried the same null modem cable on both the FreeBSD machine and the Solaris machine, I am thinking it has something to do with either a configuration setting in Solaris itself, the hardware on which Solaris is running on, or something else? ....
    #4  
Old 06-14-2013
DGPickett DGPickett is offline Forum Advisor  
Registered User
 
Join Date: Oct 2010
Last Activity: 15 October 2014, 5:08 PM EDT
Location: Southern NJ, USA (Nord)
Posts: 4,455
Thanks: 8
Thanked 546 Times in 524 Posts
Well, the loss of DSR or CTS or even effectively a break (long zero) might also be what is detected. An rs232 can be as little as three wires, SD, RD and ground, emulating a current loop connection. Does stty have other lead watchers you might turn on? Can you put a breakout box on and see what leads are live as senders or receivers, or just a volt-ohm-meter, as even receivers usually have voltage or resistance you can sense?
Sponsored Links
    #5  
Old 06-14-2013
Corona688 Corona688 is offline Forum Staff  
Mead Rotor
 
Join Date: Aug 2005
Last Activity: 22 October 2014, 6:34 PM EDT
Location: Saskatchewan
Posts: 19,649
Thanks: 818
Thanked 3,344 Times in 3,132 Posts
Whether this is obeyed may depend on the settings of your serial port as well, see stty
Sponsored Links
    #6  
Old 06-14-2013
DGPickett DGPickett is offline Forum Advisor  
Registered User
 
Join Date: Oct 2010
Last Activity: 15 October 2014, 5:08 PM EDT
Location: Southern NJ, USA (Nord)
Posts: 4,455
Thanks: 8
Thanked 546 Times in 524 Posts
I guess you can even stty other tty using stdin redirection?

The options are a bit overwhelming, to accommodate many different modem and terminal systems, flow control schemes, etc.

Last edited by DGPickett; 06-14-2013 at 02:25 PM..
Sponsored Links
    #7  
Old 06-16-2013
rstor rstor is offline
Registered User
 
Join Date: Jun 2013
Last Activity: 16 June 2013, 2:33 PM EDT
Posts: 7
Thanks: 2
Thanked 0 Times in 0 Posts
The issue has been resolved. According to the documentation/tutorial referenced in my opening post, it mentioned to issue the following commands (which I did):


Code:
eeprom ttya-ignore-cd=true  
eeprom ttya-rts-dtr-off=true

However; on Oracle's site, regarding the eeprom(1M)command it mentions the following:

Quote:
ttya-ignore-cd If true, operating system ignores carrier-detect on TTYA. Defaults to true.

ttya-rts-dtr-off If true, operating system does not assert DTR and RTS on TTYA. Defaults to false.
Therefore setting both to false allowed both carrier detection and DTR to be asserted in Solaris.
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Modem (dial up) connecton to Unix machine Mick UNIX for Advanced & Expert Users 1 10-16-2011 08:45 PM
help me!!!! how configure modem dial up with smc in solaris 10 mr.ridho Solaris 0 05-13-2008 08:26 AM
Dial-Out & Dial-In Connections in OpenServer 5.0.6. thecobolguy SCO 1 04-28-2005 07:43 AM
Dial-Up Modem Synbios UNIX for Dummies Questions & Answers 0 09-26-2004 08:40 PM
Hyperterminal null modem connection to Solaris seethams UNIX for Dummies Questions & Answers 3 08-16-2004 10:54 PM



All times are GMT -4. The time now is 01:55 AM.