Page 2 of 6 FirstFirst 1234 ... LastLast
Results 11 to 20 of 52

Thread: HOWTO: Automatic network configuration

  1. #11
    Join Date
    Jan 2005
    Beans
    90

    Re: HOWTO: Automatic network configuration

    whereami.conf is the file that determines what actions are taken based on which network you are on as determined in detect.conf. Each line in whereami.conf starts with a +, -, or = sign. A + means the command is performed when moving from another network to the new network; a - means the perform it when moving away, and the equal means to always perform it when using the network. The +/-/= sign must be followed by a network (which must be listed in detect.conf) and then a command. So, a line looks like this
    Code:
    +/-/=<network> <command>
    My whereami.conf file looks like this:
    Code:
    =home-wired cp /etc/network/interfaces /etc/network/interfaces.old
    =home-wired cp /etc/network/interfaces.wired /etc/network/interfaces
    =home-wired /etc/init.d/networking restart
    =home-wired setresolver search lucifer.blueplazma.org blueplazma.org nameserver 192.168.1.114
    
    
    =wired cp /etc/network/interfaces /etc/network/interfaces.old
    =wired cp /etc/network/interfaces.wired /etc/network/interfaces
    =wired /etc/init.d/networking restart
    =wired /etc/init.d/firewall-secure
    
    =home-wireless cp /etc/network/interfaces /etc/network/interfaces.old
    =home-wireless cp /etc/network/interfaces.home-wireless /etc/network/interfaces
    =home-wireless /etc/init.d/networking restart
    =home-wireless setresolver search lucifer.blueplazma.org blueplazma.org nameserver 192.168.1.114
    =home-wireless /etc/init.d/firewall-home
    
    =wireless cp /etc/network/interfaces /etc/network/interfaces.old
    =wireless cp /etc/network/interfaces.dhcp-wireless /etc/network/interfaces
    =wireless /etc/init.d/networking restart
    =wireless dhclient
    =wireless /etc/init.d/firewall-secure
    
    
    =down cp /etc/network/interfaces /etc/network/interfaces.old
    =down cp /etc/network/interfaces.down /etc/network/interfaces
    =down /etc/init.d/networking restart
    As you can see, I have several different networks, and different commands for each one. This file makes whereami very powerful, because just about any command can be executed based on the network whereami detects. For example, it is possible to automatically create a VPN connection with whereami and some knowhow with the VPN connection. I have not tried this, but see no reason why it would not work... If anyone does get it, let me know. I hope this helps you.

  2. #12
    Join Date
    Apr 2005
    Beans
    432
    Distro
    Ubuntu

    Re: HOWTO: Automatic network configuration

    Will this work if scanning isn't supported by iwconfig? Even though I have an Orinoco wireless card, which is supposedly the most Linux-compatible card there is, scanning is still not supported through iwconfig even after patching the kernel modules for kismet. I see the syntax with the word "scan" and I don't want to get into this if it's going to be pointless.

  3. #13
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by NTolerance
    Will this work if scanning isn't supported by iwconfig? Even though I have an Orinoco wireless card, which is supposedly the most Linux-compatible card there is, scanning is still not supported through iwconfig even after patching the kernel modules for kismet. I see the syntax with the word "scan" and I don't want to get into this if it's going to be pointless.
    sudo iwlist eth1 scan work??
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  4. #14
    Join Date
    Apr 2005
    Beans
    432
    Distro
    Ubuntu

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by Gandalf
    sudo iwlist eth1 scan work??
    Code:
    iwlist eth1 scan
    eth1      Interface doesn't support scanning : Operation not supported

  5. #15
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by NTolerance
    Code:
    iwlist eth1 scan
    eth1      Interface doesn't support scanning : Operation not supported
    hmmmm i was getting the same thing so i went into System -> Administration -> Networking and i set eth1 to "This devise is configured" activate it and since iwlist works
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  6. #16
    Join Date
    Jan 2005
    Beans
    90

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by NTolerance
    Will this work if scanning isn't supported by iwconfig? Even though I have an Orinoco wireless card, which is supposedly the most Linux-compatible card there is, scanning is still not supported through iwconfig even after patching the kernel modules for kismet. I see the syntax with the word "scan" and I don't want to get into this if it's going to be pointless.
    I don't really know about that, sorry. My suspicion is that it will not.

  7. #17
    Join Date
    Apr 2005
    Beans
    432
    Distro
    Ubuntu

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by Gandalf
    hmmmm i was getting the same thing so i went into System -> Administration -> Networking and i set eth1 to "This devise is configured" activate it and since iwlist works
    Are you using an Orinoco card? I'm using Kubuntu though, so I'm not sure what the equivalent is.

  8. #18
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by NTolerance
    Are you using an Orinoco card? I'm using Kubuntu though, so I'm not sure what the equivalent is.
    no i have ipw2200 but i had the same problem
    even iwconfig reports MAC address 000000.... but after this the MAC address was there,
    i'm not sure about the equivalent neither
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  9. #19
    Join Date
    Jan 2005
    Beans
    90

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by NTolerance
    Are you using an Orinoco card? I'm using Kubuntu though, so I'm not sure what the equivalent is.
    Try running these commands from a shell. I'm assuming that your wireless card is eth1. Change eth1 to whatever the interface actually is.
    Code:
    sudo ifconfig eth1 up
    That should do the same thing as what Gandalf did.

  10. #20
    Join Date
    Apr 2005
    Beans
    432
    Distro
    Ubuntu

    Re: HOWTO: Automatic network configuration

    Quote Originally Posted by blueplazma
    Try running these commands from a shell. I'm assuming that your wireless card is eth1. Change eth1 to whatever the interface actually is.
    Code:
    sudo ifconfig eth1 up
    That should do the same thing as what Gandalf did.
    Still the same - scanning not supported.

Page 2 of 6 FirstFirst 1234 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •