- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: backup dial-up connection
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2005 06:14 PM
07-24-2005 06:14 PM
backup dial-up connection
One of my site have a cable connection for Internet. I want to configure a dial-up modem as a backup connetion in such a way that whenever the cable modem's link goes down, the dial-up connection should get activated automatically, and all services but mailing should stop, since the dial-up connections are low-bandwidth connections, and when the server works on dial-up modem, only mailing services ( sendmail and fetchmail) should work. Please let me know how I can get it configured successfully. cable modem is connected to Linux server through RJ-45 connection.
One more suggestion I want from you all, is using sendmail+ FC4+MailScanner+ ClamAV looks inferior than a qmail/ postfix based solution? I prefer to use sendmail based solution because of it's flexibility.
Thanks In advance.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 03:00 AM
07-25-2005 03:00 AM
Re: backup dial-up connection
Components:
1) Check the cable modem connection. Do the next steps only if its down.
2) If cable modem down:
service sendmail stop
# stops most incoming sendmail connections. Does nothing about outbound. Outbound mail will simply queue up, waiting to go out if /etc/resolv.conf does not allow for host name resolution on the dial up ip address.
If you want the mail services to work, then the script needs to use an alternate /etc/resolv.conf file based on the host name resolution provided by the dial up provider. Alternately you can have secondary and/or teritiary entries in /etc/resolv.conf to allow resolution.
Mail will work, slowly outbound if you have host name resolution. Thats pretty much all sendmail is going to care about.
For inbound mail, you would need a line in /etc/mail/sendmail.cf or your sendmail.mc file allowing the daemon to listen on the dial up ip address. Thats probably not worth the hassle, but if you want it, see this website for some sendmail.mc macro tools and scripts: http://www.hpux.ws
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 05:32 PM
07-25-2005 05:32 PM
Re: backup dial-up connection
Write a small script which can handle this:
* Check for cable modem availabiliy (Try pinging some known global machine)
* If it is down, bring up the dialup connection (use wvdial for script based dialup)
* Stop all services (if it is default internet gateway then disable ip_forwarding)
* Bring up sendmail and fetchmail services alone.
Regards,
Gopi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 05:41 PM
07-25-2005 05:41 PM
Re: backup dial-up connection
Now I have a brief outline on how to do that. But you haven't answered my second question (required suggestion wether to use sendmail+other components or qmail/ postfix)?
Thanx in adv
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 06:11 PM
07-25-2005 06:11 PM
Re: backup dial-up connection
All the MTA's does the same job, each one has advantage over others. sendmail is more flexible interms of features and configurations but has its own drawback of speed and security (compared to other MTAs). qmail/postfix do offer better security and robustness over sendmail but they lack features(as I remember).
So its all your call whether you want to sacrifice security and speed for feature or otherway around.
It is same as Gnome vs KDE, both of them offer same functionality but in different ways. Gnome concentrates more on functionality and KDE towards the user interface.
Hope this helps,
Gopi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 08:42 PM
07-25-2005 08:42 PM
Re: backup dial-up connection
Now I have made a tiny script to check the connectivity through cable-modem ( forgive me if it looks bad, I don't have much experience of scripting!). If I run it through terminal , it works well, but if I make a cron entry into /etc/crontab to invoke this script every 2 minutes, I (means root) get an error-mail "TERM environment variable not set" for this entry. Please tell me what is the thing I skipped. Also suggest me to make this script better way.
thanks in advance.
PS: script is attached.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 09:14 PM
07-25-2005 09:14 PM
Re: backup dial-up connection
your problem looks like you are trying to open xterm program which requires running X. Also you need to export DISPLAY variable for xterm to work.
I have attached the updated script which contains suggestions for handling this.
Regards,
Gopi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2005 11:03 PM
07-25-2005 11:03 PM
Re: backup dial-up connection
Your suggestions helped me to understand what's wrong. But I want to get a display on standard output device (monitor) instead of mails. I have tried to set TERM & DISPLAY variables in this script , but no luck. Is there any other way round to get the disconnection error msg instantly displayed on the current display?
thanks in advance
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-26-2005 12:10 AM
07-26-2005 12:10 AM
Re: backup dial-up connection
I believe you want GUI based alert message. for that you need to have the localhost added using xhost. and also the cron job should be executed as the same user as who is logged on the X.
if you want to send message to a particular console terminal (tty1 to 12) then you can use write command. check 'man write' for more info.
if you want to send messages to all the terminals (including remote logins) then use wall command. check 'man wall' for information on this. run wall as root and you will get the message displayed to all the users who are logged on.
Regards,
Gopi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-03-2006 06:18 PM
01-03-2006 06:18 PM