On 11/21/2014 10:09 AM, John Jason Jordan wrote: < snip >
> I can now disable / enable eth1 in a script without needing my > password, but it's not working quite the way I need it to work yet. A win is a win, even if you still have some more tweaking to do. > The first line in the script is 'sudo ifconfig eth1 down' and the last > line is '... up.' These are working as expected, except that the last > line does not actually connect to eth1. I still have to use the GUI to > reconnect to eth1. Note that this is a trivial matter; if I have to > stop and reconnect to eth1 once a day it is not the end of the world. > But scripts are supposed to automate things, so getting this thing to > work the way I want it to is a point of honor. > > Note also that I do not really need to completely disable eth1; all I > need to do is disconnect / reconnect it. I was using '... down' and > '... up' just because I couldn't find a command to just disconnect and > reconnect. Again, this sounds like a routing issue on your laptop and to restart eth1 before your transfer works, you may have to restart eth1 after disconnecting from your SD card as well. > I read the man pages for ifconfig, ifup and interfaces, but I didn't > find a way to automatically connect eth1. Of course, I didn't understand > everything that I read, so what I am looking for might still be in > there. You may want to be using ifup and ifdown instead of ifconfig up / down. I say this because one normally initiates pump or dhclient after ifconfig up unless you specify an IP address with the up. This is confirmed on cursory reading of the man page for ifup and ifconfig, and your personal environment doesn't use DHCP from what I recall, hence the suggestion for ifup / ifdown. > Also, when I reboot my computer it automatically brings up and connects > eth1. Shouldn't it automatically connect to it with the '... up' > command? Maybe I just need to fix something in the parameters of eth1, > or maybe the router? On system boot, your network manager handles all the pieces for you. It sounds like you are trying to replicate this. If you can provide the list with which utility is installed, someone might be able to help you write something that would use that specifically. If you would be willing to paste your script to the group, we might be able to help even more. dafr _______________________________________________ PLUG mailing list [email protected] http://lists.pdxlinux.org/mailman/listinfo/plug
