LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 12-09-2013, 03:40 AM   #16
fedifedi
Member
 
Registered: Oct 2013
Posts: 30

Original Poster
Rep: Reputation: Disabled

Thank you Stoad for the answer.
Sadly the physical on/off switcher is ok, but I don't understand when you talk about the "wired NIC".
How can I disable that at boot? Sorry for that!
 
Old 12-09-2013, 03:59 AM   #17
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Quote:
Originally Posted by fedifedi View Post
I don't understand when you talk about the "wired NIC".
How can I disable that at boot?
In chapter 7.2.2 you created the ifconfig.XYZ files.

Open /etc/sysconfig/ifconfig.eth0 and change ONBOOT=yes to ONBOOT=no This will make sure that eth0 will not be activated when booting your box.

BTW: A "wired NIC" is a network interface that uses a cable for its communication, a "wireless NIC" doesn't.
 
Old 12-11-2013, 04:32 AM   #18
fedifedi
Member
 
Registered: Oct 2013
Posts: 30

Original Poster
Rep: Reputation: Disabled
So, I try to use DHCP-4.2.5-P1 then Dynamic Ip's.
Now I can connect to Internet with ethernet, but wireless network still not working, and I really don't know hot to proceed.
I past my last configuration of:
"/etc/udev/rules.d/70-persistent-net.rules", "/etc/sysconfig/ifconfig.eth0", "/etc/sysconfig/ifconfig.wlan0",
"/etc/resolve.conf", "/etc/hosts".

Code:
root [ / ]# cat /etc/udev/rules.d/70-persistent-net.rules 
# This file was automatically generated by the /lib/udev/write_net_rules
# program, run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single
# line, and change only the value of the NAME= key.

# net device tg3
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:18:8b:bf:d8:00", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# net device iwl3945
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:19:d2:6c:e7:5e", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="wlan*", NAME="wlan0"
Code:
root [ / ]# cat /etc/sysconfig/ifconfig.eth0 
ONBOOT="no"
IFACE="eth0"
SERVICE="dhclient"
DHCP_START=""
DHCP_STOP=""

# Set PRINTIP="yes" to have the script print
# the DHCP assigned IP address
PRINTIP="no"

# Set PRINTALL="yes" to print the DHCP assigned values for
# IP, SM, DG, and 1st NS. This requires PRINTIP="yes".
PRINTALL="no"
Code:
root [ / ]# cat /etc/sysconfig/ifconfig.wlan0 
ONBOOT="yes"
IFACE="wlan0"
SERVICE="dhclient"
DHCP_START=""
DHCP_STOP=""

# Set PRINTIP="yes" to have the script print
# the DHCP assigned IP address
PRINTIP="no"

# Set PRINTALL="yes" to print the DHCP assigned values for
# IP, SM, DG, and 1st NS. This requires PRINTIP="yes".
PRINTALL="no"
Code:
root [ / ]# cat etc/resolv.conf 
domain fastwebnet.it
search fastwebnet.it
nameserver 62.101.93.101
nameserver 83.103.25.250
Code:
root [ / ]# cat /etc/hosts 
# Begin /etc/hosts (network card version)

127.0.0.1 localhost
192.168.1.15 lfs

# End /etc/hosts (network card version)
 
Old 12-11-2013, 05:46 AM   #19
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
I wouldn't start playing with static and dhcp at this point, focus on static. When you have a working set-up you can always experiment with dhcp.

- Your 70-persistent-net.rules output seems to be OK.

- Remove the search fastwebnet.it (or domain fastwebnet.it) from your /etc/resolv.conf file.

- Try using these 2 ifconfig files:
eth0
Code:
ONBOOT=yes
IFACE=eth0
SERVICE=ipv4-static
IP=192.168.1.15
GATEWAY=62.101.93.101
PREFIX=24
BROADCAST=192.168.1.255
wlan0
Code:
ONBOOT=yes
IFACE=wlan0
SERVICE=ipv4-static
IP=192.168.100.15
GATEWAY=62.101.93.101
PREFIX=24
BROADCAST=192.168.100.255
- Use this /etc/hosts file:
Code:
# Begin /etc/hosts
# localhost
127.0.0.1       localhost.localdomain  localhost

# wired
192.168.1.15    lfs.wired.home         lfs

# wireless
192.168.100.15  lfs_wl.wireless.home   lfs_wl

# End /etc/hosts
Execute this entry:
Code:
echo "HOSTNAME=lfs" > /etc/sysconfig/network
After all the above, stop and start the network:
Code:
/etc/rc.d/init.d/network stop
/etc/rc.d/init.d/network start
(depending on what you've done previously you might want to reboot instead).

Post the output of the following commands:
Code:
$ ifconfig -a
$ route
$ ping -c2 lfs
$ ping -c2 lfs_wl
$ ping -c2 www.linuxquestions.org
If any errors show up, please post them here.
 
Old 12-12-2013, 03:50 AM   #20
fedifedi
Member
 
Registered: Oct 2013
Posts: 30

Original Poster
Rep: Reputation: Disabled
Druna I've do the steps you said and I've got this problem when i run this command "/etc/rc.d/init.d/network start".
The output is:

Code:
root[ - ]# /etc/rc.d/init.d/network start
Bringing up the eth0 interface...                        
Adding IPv4 address 192.168.1.15 to the eth0 interface..  [ OK ]
Setting up the default gateway..RTNETLINK answers: Network is unreachable  [ FAIL ]
******
Bringing up the wlan0 interface...                        
Adding IPv4 address 192.168.100.15 to the wlan0 interface..  [ OK ]
Setting up the default gateway..RTNETLINK answers: Network is unreachable  [ FAIL ]
EDIT: I found this answer in "wiki.archlinux.org":
"RTNETLINK answers: Cannot assign requested address
If you get this error when trying to set an interface up, its most probably because you've got an invalid MAC adress. To set a working MAC, see MAC Address Spoofing.
"

Last edited by fedifedi; 12-12-2013 at 04:06 AM.
 
Old 12-12-2013, 05:31 AM   #21
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
I'm rather sure that this isn't a MAC address problem. This error is probably related to the GATEWAY=62.101.93.101 entries.

I might have overlooked something important: How do you connect to the outside world?
- Do you have a modem between your computer and your ISP? Or do you connect from your computer straight to the ISP? (please answer for both wired and wireless).

BTW: Can you post the output of the ifconfig -a and route command (just ignore the error message about RTNETLINK). This to make sure that the basic setup is correct and both devices are seen and can be activated.
 
Old 12-12-2013, 09:07 AM   #22
fedifedi
Member
 
Registered: Oct 2013
Posts: 30

Original Poster
Rep: Reputation: Disabled
About my connection, I've got a router between me and my ISP.
This is the output of "ifconfig -a" and "route"
Code:
root [ ~ ]# ifconfig -a
eth0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500  metric 1
        inet 192.168.1.14  netmask 255.255.255.0  broadcast 192.168.1.255
        ether 00:18:8b:bf:d8:00  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device interrupt 18  

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536  metric 1
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 0  (Local Loopback)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

sit0: flags=128<NOARP>  mtu 1480  metric 1
        sit  txqueuelen 0  (IPv6-in-IPv4)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500  metric 1
        inet 192.168.1.15  netmask 255.255.255.0  broadcast 192.168.1.255
        ether 00:19:d2:6c:e7:5e  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
Code:
root [ ~ ]# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         192.168.1.254   0.0.0.0         UG    0      0        0 eth0
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
192.168.1.0     *               255.255.255.0   U     0      0        0 wlan0

I change /etc/sysconfig/eth0 and /etc/sysconfig/wlan0 with the correct gateway:

Code:
root [ ~ ]# cat /etc/sysconfig/eth0
ONBOOT=yes
IFACE=eth0
SERVICE=ipv4-static
IP=192.168.1.14
GATEWAY=192.168.1.254
PREFIX=24
BROADCAST=192.168.1.255
Code:
root [ ~ ]# cat /etc/sysconfig/wlan0
ONBOOT=yes
IFACE=wlan0
SERVICE=ipv4-static
IP=192.168.1.15
GATEWAY=192.168.1.254
PREFIX=24
BROADCAST=192.168.1.255
Now when i do "/etc/rc.d/init.d/network start" I've got only a warning:
Code:
ay already setup: skipping  [ warn ]
And I can connect with eth0 but when I try to use wlan0, for example when I try scanning I've got this:

Code:
root [ ~ ]# iwlist wlan0 scan
 wlan0 interface doesn't support scanning
When I was connected with eth0 i do the commands you said: "ping -c2 lfs", "ping -c2 lfs_wl", "ping -c2 www.linuxquestions.org", and there are the results:

Code:
root [ ~ ]# ping -c2 lfs
PING lfs.wired.home (192.168.1.15): 56 data bytes
64 bytes from 192.168.1.15: icmp_seq=0 ttl=64 time=0.095 ms
64 bytes from 192.168.1.15: icmp_seq=1 ttl=64 time=0.067 ms
--- lfs.wired.home ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max/stddev = 0.067/0.081/0.095/0.000 ms


root [ ~ ]# ping -c2 lfs_wl
PING lfs_wl.wireless.home (192.168.100.15): 56 data bytes
--- lfs_wl.wireless.home ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss


root [ ~ ]# ping -c2 www.linuxquestions.org
PING www.linuxquestions.org (75.126.162.205): 56 data bytes
64 bytes from 75.126.162.205: icmp_seq=0 ttl=47 time=159.283 ms
64 bytes from 75.126.162.205: icmp_seq=1 ttl=47 time=157.094 ms
--- www.linuxquestions.org ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max/stddev = 157.094/158.189/159.283/1.095 ms
 
Old 12-12-2013, 09:28 AM   #23
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
You're making some progress.

You fixed the gateway problem for eth0, which is now up and running.

I'm not sure why you changed the wlan ip address, leave it as suggested by me in post #19 (IP=192.168.100.15 / BROADCAST=192.168.100.255). Why, you might ask: Eth0 and wlan0 are 2 different devices, it would be wise to put them on different networks.

When using a static IP address you have to make sure that that IP address is also used in /etc/hosts (it doesn't seem to be so, looking at the # ping -c2 lfs_wl output (which points to 192.168.100.15).

Does your wireless also make use of the router to connect to the outside world? If not, then how? You might need a different gateway address or have to make use of dhcp (which I overlooked originally, sorry about that).

I'm not sure how to fix the following:
Quote:
root [ ~ ]# iwlist wlan0 scan
wlan0 interface doesn't support scanning
BTW:
Quote:
Now when i do "/etc/rc.d/init.d/network start" I've got only a warning:
If the network interface is already up you get the already setup: skipping [ warn ] message.
 
Old 11-18-2014, 12:23 PM   #24
ordealbyfire83
Member
 
Registered: Oct 2006
Location: Leiden, Netherlands
Distribution: LFS, Ubuntu Hardy
Posts: 302

Rep: Reputation: 89
I know this is old; I found this thread when trying to set up iwl3945.

Quote:
I'm not sure how to fix the following:
root [ ~ ]# iwlist wlan0 scan
wlan0 interface doesn't support scanning
I had this same problem until recompiling my kernel with cfg80211:

Networking support --->
Wireless --->
cfg80211 - wireless configuration API: Y or M
cfg80211 wireless extensions compatibility: Y
Generic IEEE 802.11 Networking Stack (mac80211): Y or M
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
wheezy didn't recognize CDROM piobair Debian 5 08-07-2013 04:31 PM
Ubuntu didn't recognize a sound dtphong_1989 Linux - Hardware 1 07-29-2010 10:34 PM
Fedora 12 didn't recognize existing Ubuntu 9.10 murthyna Ubuntu 9 02-20-2010 04:14 PM
kernel 2.6 didn't recognize the CDROM, while 2.4 did abd_bela Debian 1 02-01-2006 11:30 AM
SuSE 9.0 didn't recognize kb or mouse walterbyrd Linux - Distributions 2 04-14-2004 11:36 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 01:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration