LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 07-19-2013, 05:28 PM   #1
Draper
LQ Newbie
 
Registered: Jul 2013
Distribution: Ubuntu
Posts: 13

Rep: Reputation: Disabled
Apt-get update not connecting, sources.list not fixing problem


Hi,

I'm running Kali 1.0.3 amd64 from hard drive(I know, not really Debian but was hoping someone could help). It's a new install, and I ran into an issue where the network manager said my wired network "device not ready", so I changed the [ifupdown] to true and rebooted. Ifconfig is showing me that I am sending/receiving packets and am issued an IP address (would post output but I'm not currently willing to retype everything-on a different machine). Can't check if internet works because I removed iceweasel while trying to install firefox, which is where I came across the issue at hand.

So my problem is that when I try apt-get update, it attempts to connect to http.kali.org and security.kali.org and neither will connect. My sources.list file has pretty much everything I've seen that could have potentially fixed this problem, and can't find anywhere that someone has done something other than editing the sources.list file to fix this.

Any advice is appreciated. Please let me know if you need more info.

Thanks

Last edited by Draper; 07-19-2013 at 05:29 PM.
 
Old 07-19-2013, 09:14 PM   #2
Dutch Master
Senior Member
 
Registered: Dec 2005
Posts: 1,686

Rep: Reputation: 124Reputation: 124
One of the benefits of Linux is that "everything is a file". And files can be saved on Flash devices that can be read by other computers

Anyway, let's start with the basics: what's on the screen when you issue the command
Code:
ifconfig -a
This should list all interfaces, regardless whether they're connected and/or online. You mentioned you have a wired connection, chances are this is named as eth0 (as in zero). If the first command doesn't show it as connected and sending/receiving packets, try
Code:
ifup eth0
Assuming you have a router with DHCP server, it should connect and you should have an internet connection.

If the above fails, examine the contents of the file /etc/network/interfaces. Is eth0 mentioned, or any other outside network interface (like wlan, etc)? In case the file only mentions the lo device, issue the following command:
Code:
echo "# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp" >> /etc/network/interfaces
Try the ifup command again.

Assuming you have a physical connection but still no access to the net, use the ping command to see if there's a DNS issue on your machine:
Code:
ping -c 5 82.94.234.42
This sends 5 packets to one of the Google servers, who will respond if there's a proper connection. If that works, try again, but now with the domain name instead of the IP address:
Code:
ping -c 5 google.com
This should yield about the same results as the previous one. If this one fails, and the IP address worked, the issue is in the DNS, as in you don't have a DNS gateway configured. We'll get to that when you get that far

If all the above commands fail, execute them again, but append each with a redirect to an named file: [command] >> [command-name+count].txt This will create a text file with the name of the command and a number (manually added!) to distinguish between the various (repeated) iterations of that command. You can then transfer these text files to your connected machine and post them here
 
1 members found this post helpful.
Old 07-21-2013, 02:40 AM   #3
RootMason
Member
 
Registered: Oct 2012
Location: Tucson, AZ
Distribution: Debian/CentOS
Posts: 124

Rep: Reputation: 5
I agree with DutchMaster's response: I would begin by trying to ping an outside source. I like to use:

ping 8.8.8.8

... to ping Google's nameservers. It would be my guess your problem is not in sources.list, but in your connection itself. The transmitted packets you are seeing could very likely be local, they are not necessarily WAN-related.
 
Old 07-22-2013, 11:31 AM   #4
Draper
LQ Newbie
 
Registered: Jul 2013
Distribution: Ubuntu
Posts: 13

Original Poster
Rep: Reputation: Disabled
Ok. So running ifconfig -a gives
Code:
eth0      Link encap:Ethernet  HWaddr 88:51:fb:53:f4:d7  
          inet addr:10.40.4.100  Bcast:10.40.4.255  Mask:255.255.255.0
          inet6 addr: fe80::8a51:fbff:fe53:f4d7/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1113 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1296 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:799895 (781.1 KiB)  TX bytes:144360 (140.9 KiB)

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:65536  Metric:1
          RX packets:16 errors:0 dropped:0 overruns:0 frame:0
          TX packets:16 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:960 (960.0 B)  TX bytes:960 (960.0 B)

wlan0     Link encap:Ethernet  HWaddr b8:76:3f:70:84:29  
          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)
and ifup says "interface eth0 already configured"

The interfaces file says eth0 is the primary network interface

Code:
# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp
Pinging google:
Code:
PING google.com (74.125.224.227) 56(84) bytes of data.
64 bytes from lax04s08-in-f3.1e100.net (74.125.224.227): icmp_req=1 ttl=55 time=37.1 ms
64 bytes from lax04s08-in-f3.1e100.net (74.125.224.227): icmp_req=2 ttl=55 time=37.2 ms
64 bytes from lax04s08-in-f3.1e100.net (74.125.224.227): icmp_req=3 ttl=55 time=37.3 ms
64 bytes from lax04s08-in-f3.1e100.net (74.125.224.227): icmp_req=4 ttl=55 time=37.3 ms
64 bytes from lax04s08-in-f3.1e100.net (74.125.224.227): icmp_req=5 ttl=55 time=37.1 ms

--- google.com ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4005ms
rtt min/avg/max/mdev = 37.132/37.229/37.336/0.190 ms
Then, assuming problem was solved, attempted to access internet via google chrome. It couldn't load the page, so I attempted to ping google again, which returned nothing. Is this potentially a problem with the network, beyond my control?
 
Old 07-22-2013, 11:46 AM   #5
Draper
LQ Newbie
 
Registered: Jul 2013
Distribution: Ubuntu
Posts: 13

Original Poster
Rep: Reputation: Disabled
Ok well I literally just now got an email from IT that they had upgraded the internet connection in our building on Friday, and we are "experiencing minor connection problems, please bear with us for a few days while we deal with our Internet Service Provider.". Now I'm on the problem machine and am running into no real connection issues, albeit it's a little slow.

Thanks a ton for the help though, I really appreciate your willingness to help.
 
Old 07-22-2013, 01:02 PM   #6
RootMason
Member
 
Registered: Oct 2012
Location: Tucson, AZ
Distribution: Debian/CentOS
Posts: 124

Rep: Reputation: 5
You got it buddy... great to see you got yourself up and running!
 
Old 07-22-2013, 01:30 PM   #7
Dutch Master
Senior Member
 
Registered: Dec 2005
Posts: 1,686

Rep: Reputation: 124Reputation: 124
Glad to help. That's what LQ is all about
 
  


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
/etc/apt/sources.list How to update? mrshanim Debian 4 09-12-2009 03:13 AM
How Do I Update /etc/apt/sources.list To 8.04 ?? taurusx5 Linux - Software 2 08-02-2008 01:09 PM
debian /etc/apt/sources.list update problem asparagus Linux - Newbie 2 01-16-2008 05:38 AM
/etc/apt/sources.list update problem asparagus Debian 1 01-15-2008 07:46 PM
apt-get update errors since Debian released ( bad /etc/apt/sources.list ?) forgox Debian 10 06-13-2005 12:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 08:14 PM.

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