Find the answer to your Linux question:
Results 1 to 8 of 8
Like Tree1Likes
  • 1 Post By atreyu
Hi, I have a wireless connection which connects Fedora to my home network. My network interface is wlan0 which shows from ip addr command, but in my /etc/sysconfig/network-scripts directory, I ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2008
    Location
    Co.Mayo, Ireland
    Posts
    33

    Question Network Interfaces


    Hi,

    I have a wireless connection which connects Fedora to my home network. My network interface is wlan0 which shows from ip addr command, but in my /etc/sysconfig/network-scripts directory, I have a ifcfg-eircom77954150 file which represents my network connection (Eircom is an Irish ISP).

    Would that be the interface file I need to configure if I wanted to allow a DHCP server to listen on, and to allocate static IP address information to?

    Thanks much appreciated

  2. #2
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    yeah, that's probably the file. to be sure, take a look in it and see if there is a DEVICE="xxx" entry. that should have the actual interface name (e.g., "wlan0").

    btw, by "DHCP server to listen on...etc.", what exactly do you mean? do you want this Fedora box to by a DHCP client, and get its ip address from some DHCP server on the local subnet? then yeah, you'd use this file (provided it matches the DEVICE name). you'd comment out the IPADDR, NETMASK, and maybe GATEWAY entries, and change BOOTPROTO from "static" to "dhcp". also make sure that the dhclient package is installed.

    also, udev might have something to do with it. take a look at the contents of this file:

    Code:
    /etc/udev/rules.d/70-persistent-net.rules

  3. #3
    Just Joined!
    Join Date
    Oct 2008
    Location
    Co.Mayo, Ireland
    Posts
    33
    Thanks alot for your reply.

    I actually did look inside the file and it says nothing about my interface being wlan0. Just confirms default seettings such as BOOTPROTO which is dhcp, and other info.

    And no I actually mean the other way around, setting this host as DHCP server, so my VM clients can get IP addresses (just for practice). Altho that question is answered because it should be the file to configure.

    Il take a look at that file and I'l let ya know whats inside the *net.rules file.

    Thanks again

  4. #4
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    Quote Originally Posted by dougie1809 View Post
    I actually did look inside the file and it says nothing about my interface being wlan0. Just confirms default seettings such as BOOTPROTO which is dhcp, and other info.
    okay, what about HWADDR, is that in there? that is the mac address, and you can verify it against the device you think it is using this command:

    Code:
    cat /sys/class/net/wlan0/address
    assuming wlan0 is the name of the interface in question.

    And no I actually mean the other way around, setting this host as DHCP server, so my VM clients can get IP addresses (just for practice). Altho that question is answered because it should be the file to configure.
    so this box gets its ip address from another DHCP server, and it is going to be a DHCP server, as well? Are they on the same subnet? If so, then that is not a good idea - they will war. It would be good if you have multiple NICs on your box and can segregate the two.

  5. #5
    Just Joined!
    Join Date
    Oct 2008
    Location
    Co.Mayo, Ireland
    Posts
    33
    Yup the HWARE address entry matches the value in the /sys/class/net/wlan0/address file. So that implies that I am using the ifcfg-eircom77954150 interface file?

    Yes they are on the same subnet, and the host has only one NIC interface. And yes this host is using the ISP's DHCP service. But can you not configure the client to specifically get IP info from my host rather than the ISP's DHCP?

    Thanks

  6. #6
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    Quote Originally Posted by dougie1809 View Post
    Yup the HWARE address entry matches the value in the /sys/class/net/wlan0/address file. So that implies that I am using the ifcfg-eircom77954150 interface file?
    yeah, i'd bet dollars to donuts.

    if you want, you could probably rename it to something more sensible, like "ifcfg-wlan0". reboot to test.

    Yes they are on the same subnet, and the host has only one NIC interface. And yes this host is using the ISP's DHCP service. But can you not configure the client to specifically get IP info from my host rather than the ISP's DHCP?
    i'm no DHCP expert, but i believe that you cannot do that. DHCP clients work by broadcasting a request for an ip on the local network (via UDP), and the first available DHCP server responds.

    If you had a VLAN-capable router inb/t you'd probably be safe, though. otherwise, i'd personally recommend investing in a 2nd NIC (you can get a cheap but reliable USB adapter on Amazon).
    dougie1809 likes this.

  7. #7
    Just Joined!
    Join Date
    Oct 2008
    Location
    Co.Mayo, Ireland
    Posts
    33
    Thanks alot for your help.

    Yea that makes sense about the DHCP. Although my original question was about the interface file, which I got a good answer back.

    Thanks again

  8. #8
    Trusted Penguin
    Join Date
    May 2011
    Posts
    4,353
    cheers. marking as Solved. You can do this as well, using the Thread Tools link at the top of the page.

Posting Permissions

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