LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Slackware Internet Issues? (https://www.linuxquestions.org/questions/linux-newbie-8/slackware-internet-issues-876728/)

aquamongoose 04-23-2011 08:21 PM

Slackware Internet Issues?
 
Hi,
I'm new to slackware (and the forums) and I just installed it onto my laptop. I have previously used linux mint, and I like it but I feel that slackware might give me more experience with the terminal, and more original linux ideas. I have kde up and running as far as a window manager, and everything seems to work except connecting to the internet. I have a linksys router. I usually use wifi, but I even tried connecting through an ethernet cord and that didn't work either. I have searched many different threads, but either they didn't address my specific problem, or I couldn't understand what was going on. I tried to configure using "netconfig", but I didn't understand what many of the prompts wanted. I entered a name and a domain name, and selected DHCP, but this did nothing. Any help would be appreciated, and thanks in advance.

MS3FGX 04-23-2011 10:42 PM

We will need to start from the beginning here. Does the system detect your network hardware properly? What do you see when you run "ifconfig -a"?

From there, what is the contents of /etc/rc.d/rc.inet1.conf?

aquamongoose 04-24-2011 09:34 AM

Thanks for the reply. When I ran "ifconfig -a" this came out.
Code:

eth0    Link encap:Ethernet  HWaddr 00:1b:38:36:8e:5a
        inet6 addr: fe80::21b:38ff:fe36:8e5a/64 Scope:Link
        UP BROADCAST MULTICAST MTU:1500  Metric:1
        RX packets:23 errors:0 dropped:0 overruns:0 carrier:0
        collisions:0 txqueuelen:1000
        RX bytes:6615 (6.4 KiB)  TX bytes:492 (492.0 B)
        Interrupt:16

lo      Link encap: Local Loopback
        inet addr:127.0.0.1  Mask:255.0.0.0
        inet6 addr: ::1/128 Scope:Host
        UP LOOPBACK RUNNING  MTU:16436  Metric:1
        RX packets:28 errors:0 dropped:0 overruns:0 frame:0
        TX packets:28 errors:0 dropped:0 overruns:0 carrier:0
        collisions:0 txqueuelen:0
        RX bytes:1440 (1.4 KiB)  TX bytes:1440 (1.4 KiB)

wlan0  Link encap:Ethernet  HWaddr 00:1b:77:76:1a:5d
        UP BROADCAST MULTICAST  MTU:1500  Metric:1
        RX packets:0 errors:0 dropped:0 overruns:0 frame:0
        TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
        collisions:0 txqueuelen:1000
        RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

When I typed "/etc/rc.d/rc.inet1.conf" into the terminal (I think that's what you wanted me to do) it said "bash: /etc/rc.d/rc.inet1.conf: Permission denied" and I did this as root so I don't see why permission was denied.

MS3FGX 04-24-2011 09:36 AM

rc.inet1.conf is a text file, you need to open it with an editor or simply print it's contents with "cat".

aquamongoose 04-24-2011 10:21 AM

Here's the output:
Code:

bash-4.1# cat /etc/rc.d/rc.inet1.conf
# /etc/rc.d/rc.inet1.conf
#
# This file contains the configuration settings for network interfaces.
# If USE_DHCP[interface] is set to "yes", this overrides any other settings.
# If you don't have an interface, leave the settings null ("").

# You can configure network interfaces other than eth0,eth1... by setting
# IFNAME[interface] to the interface's name. If IFNAME[interface] is unset
# or empty, it is assumed you're configuring eth<interface>.

# Several other parameters are available, the end of this file contains a
# comprehensive set of examples.

# =============================================================================

# Config information for eth0:
IPADDR[0]=""
NETMASK[0]=""
USE_DHCP[0]="yes"
DHCP_HOSTNAME[0]=""

# Config information for eth1:
IPADDR[1]=""
NETMASK[1]=""
USE_DHCP[1]=""
DHCP_HOSTNAME[1]=""

# Config information for eth2:
IPADDR[2]=""
NETMASK[2]=""
USE_DHCP[2]=""
DHCP_HOSTNAME[2]=""

# Config information for eth3:
IPADDR[3]=""
NETMASK[3]=""
USE_DHCP[3]=""
DHCP_HOSTNAME[3]=""

# Default gateway IP address:
GATEWAY=""

# Change this to "yes" for debugging output to stdout.  Unfortunately,
# /sbin/hotplug seems to disable stdout so you'll only see debugging output
# when rc.inet1 is called directly.
DEBUG_ETH_UP="no"

## Example config information for wlan0.  Uncomment the lines you need and fill
## in your info.  (You may not need all of these for your wireless network)
#IFNAME[4]="wlan0"
#IPADDR[4]=""
#NETMASK[4]=""
#USE_DHCP[4]="yes"
#DHCP_HOSTNAME[4]="icculus-wireless"
#DHCP_KEEPRESOLV[4]="yes"
#DHCP_KEEPNTP[4]="yes"
#DHCP_KEEPGW[4]="yes"
#DHCP_IPADDR[4]=""
#WLAN_ESSID[4]=BARRIER05
#WLAN_MODE[4]=Managed
##WLAN_RATE[4]="54M auto"
##WLAN_CHANNEL[4]="auto"
##WLAN_KEY[4]="D5AD1F04ACF048EC2D0B1C80C7"
##WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=96389dc66eaf7e6efd5b5523ae43c7925ff4df2f8b7099495192d44a774fda16"
#WLAN_WPA[4]="wpa_supplicant"
#WLAN_WPADRIVER[4]="ndiswrapper"

## Some examples of additional network parameters that you can use.
## Config information for wlan0:
#IFNAME[4]="wlan0"              # Use a different interface name nstead of
                                # the default 'eth4'
#HWADDR[4]="00:01:23:45:67:89"  # Overrule the card's hardware MAC address
#MTU[4]=""                      # The default MTU is 1500, but you might need
                                # 1360 when you use NAT'ed IPSec traffic.
#DHCP_KEEPRESOLV[4]="yes"      # If you dont want /etc/resolv.conf overwritten
#DHCP_KEEPNTP[4]="yes"          # If you don't want ntp.conf overwritten
#DHCP_KEEPGW[4]="yes"          # If you don't want the DHCP server to change
                                # your default gateway
#DHCP_IPADDR[4]=""              # Request a specific IP address from the DHCP
                                # server
#WLAN_ESSID[4]=DARKSTAR        # Here, you can override _any_ parameter
                                # defined in rc.wireless.conf, by prepending
                                # 'WLAN_' to the parameter's name. Useful for
                                # those with multiple wireless interfaces.
#WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=thekey"
                                # Some drivers require a private ioctl to be
                                # set through the iwpriv command. If more than
                                # one is required, you can place them in the
                                # IWPRIV parameter (separated with the pipe (|)
                                # character, see the example).
bash-4.1#


aquamongoose 04-24-2011 02:40 PM

So, any ideas on what I should try? Really appreciate the help.

jamescondron 04-24-2011 03:28 PM

Hi there,

Is the machine picking a link? What does
Code:

ethtool eth0
show?

aquamongoose 04-24-2011 03:43 PM

thanks, here's what came out.
Code:

bash-4.1# ethtool eth0
Settings for eth0:
        Supported ports: [ TP ]
        Supported link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Advertised pause frame use: No
        Advertised auto-negotiation: Yes
        Speed: 100Mb/s
        Duplex: Full
        Port: Twisted Pair
        PHYAD: 1
        Transceiver: internal
        Auto-negotiation: on
        MDI-X: Unknown
        Supports Wake-on: g
        Wake-on: g
        Current message level: 0x000000ff (255)
        Link detected: no
bash-4.1#


markush 04-24-2011 04:03 PM

Quote:

Originally Posted by aquamongoose
I usually use wifi

If you want to configure wlan0, be sure to uncomment the wlan0-settings in rc.inet1.conf, here an example of my laptop:
Code:

...
## Example config information for wlan0.  Uncomment the lines you need and fill
## in your info.  (You may not need all of these for your wireless network)
IFNAME[4]="wlan0"
IPADDR[4]=""
NETMASK[4]=""
USE_DHCP[4]="yes"
#DHCP_HOSTNAME[4]="icculus-wireless"
#DHCP_KEEPRESOLV[4]="yes"
#DHCP_KEEPNTP[4]="yes"
#DHCP_KEEPGW[4]="yes"
#DHCP_IPADDR[4]=""
#WLAN_ESSID[4]=BARRIER05
WLAN_MODE[4]=Managed
WLAN_RATE[4]="54M auto"
##WLAN_CHANNEL[4]="auto"
##WLAN_KEY[4]="D5AD1F04ACF048EC2D0B1C80C7"
##WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=96389dc66eaf7e6efd5b5523ae43c7925ff4df2f8b7099495192d44a774fda16"
WLAN_WPA[4]="wpa_supplicant"
#WLAN_WPADRIVER[4]="ndiswrapper"
...

where I'm using wpa2 which needs wpa_supplicant. If you have wpa2-encryption, be sure to configure the /etc/wpa_supplicant.conf file as well.

The wlan is started via
Code:

/etc/rc.d/rc.inet1 wlan0_start
If my example doesn't meet your requirements, please tell us more about your network-settings.

Markus

Edit: http://alien.slackbook.org/dokuwiki/...ckware:network

aquamongoose 04-24-2011 05:00 PM

I changed the settings to this..
Code:


bash-4.1# cat /etc/rc.d/rc.inet1.conf
# /etc/rc.d/rc.inet1.conf
#
# This file contains the configuration settings for network interfaces.
# If USE_DHCP[interface] is set to "yes", this overrides any other settings.
# If you don't have an interface, leave the settings null ("").

# You can configure network interfaces other than eth0,eth1... by setting
# IFNAME[interface] to the interface's name. If IFNAME[interface] is unset
# or empty, it is assumed you're configuring eth<interface>.

# Several other parameters are available, the end of this file contains a
# comprehensive set of examples.

# =============================================================================

# Config information for eth0:
IPADDR[0]=""
NETMASK[0]=""
USE_DHCP[0]="yes"
DHCP_HOSTNAME[0]=""

# Config information for eth1:
IPADDR[1]=""
NETMASK[1]=""
USE_DHCP[1]=""
DHCP_HOSTNAME[1]=""

# Config information for eth2:
IPADDR[2]=""
NETMASK[2]=""
USE_DHCP[2]=""
DHCP_HOSTNAME[2]=""

# Config information for eth3:
IPADDR[3]=""
NETMASK[3]=""
USE_DHCP[3]=""
DHCP_HOSTNAME[3]=""

# Default gateway IP address:
GATEWAY=""

# Change this to "yes" for debugging output to stdout.  Unfortunately,
# /sbin/hotplug seems to disable stdout so you'll only see debugging output
# when rc.inet1 is called directly.
DEBUG_ETH_UP="no"

## Example config information for wlan0.  Uncomment the lines you need and fill
## in your info.  (You may not need all of these for your wireless network)
IFNAME[4]="wlan0"
IPADDR[4]=""
NETMASK[4]=""
USE_DHCP[4]="yes"
#DHCP_HOSTNAME[4]="icculus-wireless"
#DHCP_KEEPRESOLV[4]="yes"
#DHCP_KEEPNTP[4]="yes"
#DHCP_KEEPGW[4]="yes"
#DHCP_IPADDR[4]=""
#WLAN_ESSID[4]=BARRIER05
WLAN_MODE[4]=Managed
WLAN_RATE[4]="54M auto"
##WLAN_CHANNEL[4]="auto"
##WLAN_KEY[4]="D5AD1F04ACF048EC2D0B1C80C7"
##WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=96389dc66eaf7e6efd5b5523ae43c7925ff4df2f8b7099495192d44a774fda16"
WLAN_WPA[4]="wpa_supplicant"
#WLAN_WPADRIVER[4]="ndiswrapper"

## Some examples of additional network parameters that you can use.
## Config information for wlan0:
#IFNAME[4]="wlan0"              # Use a different interface name nstead of
                                # the default 'eth4'
#HWADDR[4]="00:01:23:45:67:89"  # Overrule the card's hardware MAC address
#MTU[4]=""                      # The default MTU is 1500, but you might need
                                # 1360 when you use NAT'ed IPSec traffic.
#DHCP_KEEPRESOLV[4]="yes"      # If you dont want /etc/resolv.conf overwritten
#DHCP_KEEPNTP[4]="yes"          # If you don't want ntp.conf overwritten
#DHCP_KEEPGW[4]="yes"          # If you don't want the DHCP server to change
                                # your default gateway
#DHCP_IPADDR[4]=""              # Request a specific IP address from the DHCP
                                # server
#WLAN_ESSID[4]=DARKSTAR        # Here, you can override _any_ parameter
                                # defined in rc.wireless.conf, by prepending
                                # 'WLAN_' to the parameter's name. Useful for
                                # those with multiple wireless interfaces.
#WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=thekey"
                                # Some drivers require a private ioctl to be
                                # set through the iwpriv command. If more than
                                # one is required, you can place them in the
                                # IWPRIV parameter (separated with the pipe (|)
                                # character, see the example).
bash-4.1#

but unfortunately, when I tried to start wlan0, this is what happened.
Code:

bash-4.1# /etc/rc.d/rc.inet1 wlan0_start
/etc/rc.d/rc.inet1:  wlan0 information: 'Any ESSID'
Error for wireless request "Set Nickname" (8B1C) :
    SET failed on device wlan0 ; Operation not supported.
Line 22: Invalid PSK 'your_64_char_psk_here'.
Line 22: failed to parse psk 'your_64_char_psk_here'.
Line 24: WPA-PSK accepted for key management, but no PSK configured.
Line 24: failed to parse network block.
Failed to read or parse configuration '/etc/wpa_supplicant.conf'.
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplicant - wpa_ctrl_open: No such file or directory
Failed to connect to wpa_supplic

..and it continued to print those errors indefinitely. If you need more information about my network, I'd be happy to tell you, I just don't know what you want to know. My encryption is WEP. Please help me more, I would love to get the machine working properly.

markush 04-24-2011 05:06 PM

The errormessages don't matter. I have the same messages when everything is working.

But there is a message: "Invalid PSK"

You should check your wpa_supplicant.conf, here an example from my laptop
Code:

ctrl_interface=/var/run/wpa_supplicant GROUP=0

network={
        ssid="xxxxxxxxxxxxx"
        proto=WPA RSN
        key_mgmt=WPA-PSK
        pairwise=TKIP
        psk="xxxxxxxxxxxxxx"
}

# Wildcard match for SSID (plaintext APs only). This example select any
# open AP regardless of its SSID.
#network={
#      key_mgmt=NONE
#}

Markus

aquamongoose 04-24-2011 05:19 PM

How do I get to that file?

markush 04-24-2011 05:21 PM

mh, it is in /etc, you'll have to be root when you edit it.

Code:

cd /etc
vim wpa_supplicant.conf

or another editor if you want.

Markus

aquamongoose 04-24-2011 05:37 PM

It seems like all this is for WPA, but I have WEP..
So I made some changes to that, you were right.
Heres the new error I'm getting.
Code:

bash-4.1# /etc/rc.d/rc.inet1 wlan0_start
/etc/rc.d/rc.inet1:  wlan0 information: 'Any ESSID'
Error for wireless request "Set Nickname" (8B1C) :
    SET failed on device wlan0 ; Operation not supported.
Polling for DHCP server on interface wlan0:
dhcpcd: version 5.2.2 starting
dhcpcd: wlan0: waiting for carrier
dhcpcd: timed out
dhcpcd: allowing 8 seconds for IPv4LL timeout
dhcpcd: timed out
bash-4.1#


markush 04-24-2011 05:41 PM

With the command
Code:

iwconfig
you can check if you're authenticated to the accesspoint. There is a manpage for wpa_supplicant and for wpa_supplicant.conf. You will also find a samplefile for the wpa_supplicant.conf in /usr/share/doc/wpa_supplicant..../

Markus


All times are GMT -5. The time now is 11:33 PM.