Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
11-15-2004, 06:11 PM
|
#1
|
|
Member
Registered: Sep 2004
Posts: 30
Rep:
|
power lost from cable modem, interface lost
Hi,
I have a cable modem connected to my usb port and using it as eth1, this works good.
The problem is when there is a power failure, the modem shutsdown because it s not connected to ups and when it is turned on i cant connect to the interface, if i do ifconfig i get only my ethernet eth0 interface. to gain access to eth1 i must do ifdown eth1, ifup eth1. This is a big problem because i want to have remote access to this computer using ssh, but if there is a power failure i cant connect to the computer.
There is a way to automatically recover eth1 from a power failure, automatically doing ifdown eth1, ifup eth1.
Thanks in advance.
|
|
|
|
11-15-2004, 07:00 PM
|
#2
|
|
Member
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 146
Rep:
|
Go to /etc/sysconfig/network. If a file for eth1 does not exist create one using eth0 as a template(The file name usually starts with something lie ifcfg-eth1). That should be able to allow the system to start the interface during boot time or whenever you need to view ifconfig.
good luck
|
|
|
|
11-16-2004, 08:23 AM
|
#3
|
|
Member
Registered: Sep 2004
Posts: 30
Original Poster
Rep:
|
hi,
i'am using debian, i think in debian you mean /etc/network/interfaces.
This is my configuration.
# The loopback interface
auto lo
iface lo inet loopback
# The first network card - this entry was created during the Debian installation
auto eth0
iface eth0 inet static
address 192.168.0.60
netmask 255.255.255.0
network 192.168.1.0
hwaddress ether 00:0c:96:af:34:f3
auto eth1
iface eth1 inet dhcp
hwaddress ether 00:0c:8a:a2:c4:0f
The system works fine at boot time, the problem is if there is a power failure, the computer continue
connected (UPS) but the modem shutsdown. In this case when the power returns i cant connect remotely to the computer
because the interface is lost. I must have fisical access to the computer and reboot or execute ifdown eth1 ifup eth1.
There is a command or some other way to restart the interfaces automatically when they desapear from ifconfig ?????
Thanks you all
|
|
|
|
11-16-2004, 08:45 AM
|
#4
|
|
Member
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 146
Rep:
|
"There is a command or some other way to restart the interfaces automatically when they desapear from ifconfig ?????"
I can suggest that you write a script that will ping the modem to see if it responds. If the modem doesn't respond then it will restart the interface.
There's a script http://www.linuxquestions.org/questi...hreadid=254977 here it pings servers but you can tailor it to ping the modem. All you have to do is add ifdown/ifup to one of those lines.
That's a temporary fix for now. Good luck! 
|
|
|
|
11-16-2004, 09:01 AM
|
#5
|
|
Member
Registered: Sep 2004
Posts: 30
Original Poster
Rep:
|
thanks,
that should work for now
regards
MM
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 12:13 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|