Aleksandar Milivojevic
2006-Aug-18 21:06 UTC
[CentOS] connecting linux console using serial port (NOW PPP)
Quoting israel.garcia at cimex.com.cu:> Alex, thanks for your soon answer, but in case I want to configure PPP > on this server, what files do I have to configure? > Can I login in this server using SSHD over a PPP conection?First you'd uncomment that /AutoPPP/ line in login.config file. Depending if you want to allow or not direct login on modem line, you'd eiteher leave or comment out the "/bin/login" line at the end of a file. Than you'd need to install pppd and configure it. You'd go to /etc/ppp. Edit options and options.ttyS0 files, and probably take a look into chap-secrets and pap-secrets (by default they should be setup as fallthrough to /etc/passwd, unless you changed them). You might put something like this into options file: lock crtscts proxyarp 1.2.3.4: And something like this into options.ttyS0 file: :1.2.3.5 Change 1.2.3.4 to be the IP address of the server (box where the modem is). 1.2.3.5 is the IP address that will be assigned to the client that connected from ttyS0. Make sure both addresses are on the same subnet. And you should be set to go. -- NOTICE: If you are not intended recipient, you are hereby notified that by reading this message you agreed not to disturb frogs during mating season. For more info, visit http://www.8-P.ca/
israel.garcia at cimex.com.cu
2006-Aug-18 21:33 UTC
[CentOS] connecting linux console using serial port (NOW PPP)
Alex, thanks for your soon answer, but in case I want to configure PPP on this server, what files do I have to configure? Can I login in this server using SSHD over a PPP conection? Regards; Israel> Just terminal access -> I want to login in my linux server connecting > through the modem connected in /dev/ttyS0Not sure if this is complete. Install mgetty if not already present on your system. Go to /etc/mgetty+sendfax directory. If you have CallerID feature on your phone line (and you should get it if you don't have it yet), edit dialin.config file and add telephone numbers you will be dialing from. At least this will prevent clueless script-kiddies from getting login prompt on your modem line. I know that some of my modems get regullary probed from strange phone numbers (and those are dedicated modem lines -- no voice calls on them, not listed in white pages, too often on too many lines to be the simple case of wrong number). While there, check login.config file. If you don't want PPP on it, make sure /AutoPPP/ is commented (should be default). Make sure "* - - /bin/login @" line is not commented (should be last line in the default config file). That's the line that will give you login prompt. Edit /etc/inittab and add something like this: s0:2345:respawn:/sbin/mgetty -D -n 2 -s 115200 /dev/ttyS0 The "-n 2" tells mgetty to pick up the phone after second ring. You need to wait till second ring because telephone company sends CallerID information between first and second ring. If you configured mgetty to answer after first ring, it would never get CallerID information. Execute "telinit q" as root (this tells init process to reread inittab file). Configure and connect modem and you should be set to go. I do not recommend allowing root to login directly from modem line (could be configured by editing /etc/securetty and /etc/security/access.conf files if needed, but not wise idea). Login as normal user, than su to root. -- -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/centos/attachments/20060818/8084d6f8/attachment-0002.html>
israel.garcia at cimex.com.cu
2006-Aug-19 14:34 UTC
[CentOS] connecting linux console using serial port (NOW PPP)
Alex, in this case of setting up PPP on my linux, do I have to run "s0:2345:respawn:/sbin/mgetty -D -n 2 -s 115200 /dev/ttyS0 " in inittab file? Thanks again; Regards; Israel Quoting israel.garcia at cimex.com.cu <http://lists.centos.org/mailman/listinfo/centos> :> Alex, thanks for your soon answer, but in case I want to configure PPP > on this server, what files do I have to configure? > Can I login in this server using SSHD over a PPP conection?First you'd uncomment that /AutoPPP/ line in login.config file. Depending if you want to allow or not direct login on modem line, you'd eiteher leave or comment out the "/bin/login" line at the end of a file. Than you'd need to install pppd and configure it. You'd go to /etc/ppp. Edit options and options.ttyS0 files, and probably take a look into chap-secrets and pap-secrets (by default they should be setup as fallthrough to /etc/passwd, unless you changed them). You might put something like this into options file: lock crtscts proxyarp 1.2.3.4: And something like this into options.ttyS0 file: :1.2.3.5 Change 1.2.3.4 to be the IP address of the server (box where the modem is). 1.2.3.5 is the IP address that will be assigned to the client that connected from ttyS0. Make sure both addresses are on the same subnet. And you should be set to go. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/centos/attachments/20060819/0e987b22/attachment-0002.html>
Aleksandar Milivojevic
2006-Aug-21 16:46 UTC
[CentOS] connecting linux console using serial port (NOW PPP)
Quoting israel.garcia at cimex.com.cu:> Alex, in this case of setting up PPP on my linux, do I have to run > "s0:2345:respawn:/sbin/mgetty -D -n 2 -s 115200 /dev/ttyS0 " in inittab > file?Yes, you do. Mgetty is the one that starts pppd. -- NOTICE: If you are not intended recipient, you are hereby notified that by reading this message you agreed not to disturb frogs during mating season. For more info, visit http://www.8-P.ca/