Preventing Wireless from Trying to Connect Sometimes?
FedoraThis forum is for the discussion of the Fedora Project.
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.
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.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Preventing Wireless from Trying to Connect Sometimes?
Hello:
I have a problem. Running Fedora Core 4 (2.6.11-1.1369) and at home I have a wireless network.
So all's well when I boot up my computer in range of my wireless network. My problem is that when I'm away from an unencrypted wireless network (I use MAC filtering at home), it takes two minutes of bootup time or more to determine that "eth1 failed."
I want to know if there would be a way to set it up so that perhaps from GRUB I can tell the system not to bother checking eth1 for signal, thus speeding up boot time when not at home. Is this possible?
Originally posted by Brian1 Are you using DHCP to get your IP?
If so then change it to a static IP so it does not try for 2 minutes to get an IP.
Brian1
But I use my laptop in more than one place. If I set it to static, it'll work here, but nowhere else. My point is I want to be able to control when it's activated on bootup and when it isn't so that when I don't need it I can bypass it.
- Trip
Last edited by Trip in VA; 10-16-2005 at 04:00 PM.
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
What you are going to need to do is edit your /etc/init.d/network script and when it gets to the section on starting other network interfaces you will need to add some scripting tio ask the question. Yes to start up interfaces, No to skip that section, and maybe a timeout to automatically say Yes for non interactive use.
This type of scripting is beyond my level of writing scripts so I can not be of any help there. If you do get it to work like above please post back to this post to allow others to learn from it.
Maybe someone here is able to help you out with that if you are new to scripting in bash.
Only other way is to not to start network interfaces and when booted up run the command ' /sbin/ifup eth1 '. Note it requires root access to run this.
Originally posted by Brian1 What you are going to need to do is edit your /etc/init.d/network script and when it gets to the section on starting other network interfaces you will need to add some scripting tio ask the question. Yes to start up interfaces, No to skip that section, and maybe a timeout to automatically say Yes for non interactive use.
This type of scripting is beyond my level of writing scripts so I can not be of any help there. If you do get it to work like above please post back to this post to allow others to learn from it.
Maybe someone here is able to help you out with that if you are new to scripting in bash.
Only other way is to not to start network interfaces and when booted up run the command ' /sbin/ifup eth1 '. Note it requires root access to run this.
Hope this helps.
Brian1
Thank you for your help. I will definitely look into it now that I know where to look and post here if I come up with anything.
And ifup does not work properly, so if I don't start it on bootup, it doesn't ever get started.
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
What I should have mention is you need to edit the /etc/sysconfig/network-scripts/ifcfg-eth0 and or ifcfg-eth1 and change the line that says onBoot=yes to onBoot=no. This will not have the nic to start at boot. Then when in your terminal or gui run the command as root ' /sbin/ifup eth1 ' to startup the nic or you can from the gui from the Start Menu / System Settings / Network and start the interface from there.
Originally posted by Brian1 What I should have mention is you need to edit the /etc/sysconfig/network-scripts/ifcfg-eth0 and or ifcfg-eth1 and change the line that says onBoot=yes to onBoot=no. This will not have the nic to start at boot. Then when in your terminal or gui run the command as root ' /sbin/ifup eth1 ' to startup the nic or you can from the gui from the Start Menu / System Settings / Network and start the interface from there.
Brian1
Yes, I know that. ifup does not work. Period.
And my GUI network interface freezes if I try to change anything in it and save those changes.
And as of yet I've not found anything terribly helpful about the bash scripting. If anyone has any thoughts, I'd be most appreciative.
Originally posted by Brian1 Are you saying there is no /sbin/ifup command on your system or does it send back and error message?
Does the gui freeze completely and requires a reboot or for a period of time like 5 to 20secs?
Does it give any errors?
Brian1
ifup appears to work, no errors are returned. However no network connection is established as I can't ping anything but localhost and nothing goes anywhere.
The GUI freezes and has to be shutdown via the Performance Monitor and it loses all changes. No errors are given. When I used to run the Runaway Process Catcher (that got annoying really fast) it would always indicate that the program was frozen whenever I'd do anything that involved saving stuff.
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
Is this a notebook wiht a hardwired ethernet port and a wirless card of some kind?
If so and the hardwired port is eth0 and the wirless is eth0 try it this way.
Originally posted by Brian1 Is this a notebook wiht a hardwired ethernet port and a wirless card of some kind?
If so and the hardwired port is eth0 and the wirless is eth0 try it this way.
ifdown eth0
ifdown eth1
ifup eth1
pause a couple seconds between each command.
See if that works.
Brian1
This is a laptop with an Intel Pro wireless card in it, detected as eth1 (instead of wlan0, and last time I tried to change it I had to reinstall FC4). I don't hook my laptop up to my wired network, though the wired port is picked up as eth0. That one is NOT set to start on boot.
I've tried doing that before and it doesn't work. It just doesn't reconnect to my router.
Originally posted by Brian1 Well out of ideas here. Never seen such strange issues with enabling and disabling nics.
edit: Did a quick reread and you mention mac filtering. Diasble that on the router and see if disconnect and reconnecting works.
edit:
Good luck and if I think of anything else I will post back.
Brian1
It didn't work before I enabled the MAC filtering (which I only use because FC4's bootup won't pick up the network if it's got WEP on it).
I know it must be annoying since I'm not actually doing anything now and only reporting past results, but I'm doing some work in between looking at this and figure that nothing's changed. I don't feel like restarting this thing three times. As much as I love Linux, the one thing I can't stand is the long boot times.
For what it's worth, I had a similar issue with Slackware on my IBM Thinkpad. My way around it was to prevent the driver for the Centrino wireless card from loading by blacklisting it in the start-up scripts (in Slackware there's a file called /etc/hotplug/blacklist I don't know what it is in Fedora). Then I start the wireless connection after I am booted with a script that can be run by clicking on an icon or by typing its name at the command line. The script loads the ipw2100 module and then enables me to either choose my home network and configure the card with the right network name and WEP key, or some of the other network info I use for other networks.
This didn't have to do with wireless specifically, but at work, I was using my laptop to transfer a few gigs of video files from an old network to a new one. Rather than constantly going to the network setup dialog, I saved the configuratin that was changed in /etc/sysconfig/ for the first network (I added an extension indicating which network it was for). After setting up for the second network, I saved these files again under a unique name. I also, of course backed up the original that I used at home.
Then I wrote two scripts, each named after the corresponding network, that would simply copy over the configuration file and run "rcnetwork restart". ( I'm using SuSE, for Red Hat or Mandrake, one would use "service network restart" instead ).
Also, for commands that you need to enter as root, consider running "visudo" to add these commands to the list of commands that you are allowed to run. You can opt to not have to enter a password, however I think that you need to enter the command exactly for this to work. This is a way to not have to enter the root password for certain commands, and even more importantly, not have to share the root password.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.