LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices



Reply
 
Search this Thread
Old 04-04-2012, 11:05 PM   #1
p4lmtree
LQ Newbie
 
Registered: Mar 2012
Posts: 3

Rep: Reputation: Disabled
Debian server cannot connect to internet


I just installed Debian on an old Dell Dimension 3000, and I followed the instructions here: http://debianserver.wikidot.com/squeeze:start

to set up a home server. The first thing that told me something was wrong is when I couldn't ping anything. I have since changed my DNS to Google's (8.8.8.8 and 8.8.4.4), and ping is fine.

However, apt-get doesn't do anything. It gets stuck at 0% [Working] whenever I try to install a package.

I don't know what's wrong. My eth0 interface seems to be okay, but I just can't do anything internet-related yet. If it makes a difference, I couldn't make a wired connection when the PC had Windows on it either.
 
Old 04-05-2012, 08:40 AM   #2
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Ubuntu 10.10, Slackware 64-current
Posts: 2,124

Rep: Reputation: 776Reputation: 776Reputation: 776Reputation: 776Reputation: 776Reputation: 776Reputation: 776
Quote:
I couldn't ping anything. I have since changed my DNS to Google's (8.8.8.8 and 8.8.4.4), and ping is fine.
This sounds like a problem with your resolver, which in turn could be a DHCP problem or an improperly configured network interface.

1 - Does this system have a DHCP server that it is supposed to be configured by or is it supposed to be using a static IP address?
2 - If it uses DHCP, does the DHCP configure the DNS?

It may be helpful to post your /etc/network/interfaces so that we can see how you have things configured. It would also be be helpful to post the error messages that you are getting when you try to ping (e.g. no route to host, network unreachable, etc). What happens if you try to ping a numeric address (8.8.8.8 will work) via pinging via name?
 
Old 04-05-2012, 11:36 AM   #3
p4lmtree
LQ Newbie
 
Registered: Mar 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
/etc/network/interfaces:

auto lo
iface lo inet loopback


allow-hotplug eth0
iface eth0 inet dhcp


Also, when I try to ping I get "unknown host."

Last edited by p4lmtree; 04-05-2012 at 11:44 AM.
 
Old 04-05-2012, 12:21 PM   #4
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Ubuntu 10.10, Slackware 64-current
Posts: 2,124

Rep: Reputation: 776Reputation: 776Reputation: 776Reputation: 776Reputation: 776Reputation: 776Reputation: 776
This confirms that it is DHCP configured. What does your resolv.conf look like? Unknown host says that it can't locate a DNS server. Does your DHCP list the name servers (this would be typical. I noticed you said "when you changed your DNS to google" you were able to ping. Where exactly did you change it? Clearly something is amiss in this regard. Did you forget to allow this machine to connect through a firewall or something perhaps? The inability to update could mean that traffic is being blocked (firewalled) or it can't resolve the address to establish a connection. I would suggest looking through the log files, e.g. /var/log/messages and others for any indication of trouble.
 
Old 04-06-2012, 03:56 PM   #5
p4lmtree
LQ Newbie
 
Registered: Mar 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
noob having problems configuring a Debian home server

In my last post, I had trouble getting my server to download packages and ping servers. Since then, I changed my DNS to Google's and stayed with DHCP and a dynamic IP on my home network, and for some reason now I can download packages and ping servers.

Now I need to connect to my server from my PC.

First of all, here's my setup:

Desktop: Apple eMac PowerPC G4, Debian with LXDE
Server: Dell Dimension 3000 Pentium 4, Debian with no GUI.

My two main problems: I cannot successfully set a static IP address on my server; I cannot set up SSH functionality between my PC and my server.

My router IP is 10.0.0.1, and I've tried to assign my server to a few different IPs starting with 10.0.0.x. I also tried a couple different DNS addresses, including my default ISP's DNS and Google's public DNS. I also tried to make my server the DNS server as suggested in the Debian server wiki, and none of these configurations worked. The only way I can maintain any kind of internet connection is by keeping a dynamic IP address.

When I try to SSH, I either get "connection refused" or "host unknown." I think my problem is twofold: I don't have a solid grasp on the syntax when trying to make an SSH connection via Terminal, and no matter how strictly I copy online instructions for editing the configuration files, I still don't get it right.

I eventually want to share files with and remotely access media stored on my server, but first I need to figure out basic connections. I've spent two days looking at various sources for instructions on how to do these things, but I can't seem to get it right. What am I doing wrong?
 
Old 04-06-2012, 09:14 PM   #6
frankbell
Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Mageia, Mint
Posts: 8,247

Rep: Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557Reputation: 1557
Regarding the static IP, what have you done?

My Debian home server has one: here are the settings from /etc/network/interfaces in case they can help:

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

# The primary network interface
allow-hotplug eth0
iface eth0 inet static
address 192.168.x.x
netmask 255.255.255.0
gateway 192.168.x.1
auto eth0
I don't have a Mac. Everything is either Windows or Linux, so I do my file sharing through Samba.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Can't connect to the internet (Debian) juliajuliad Linux - Newbie 6 05-09-2011 01:33 PM
Debian 4.0 -- Cannot connect to the internet. somdeb Linux - Newbie 4 04-19-2009 02:48 PM
Debian can't connect to Internet oopsnic Linux - Hardware 1 03-11-2005 06:27 PM
My Debian box can't connect Internet satimis Linux - Networking 6 12-18-2003 06:31 AM


All times are GMT -5. The time now is 01:44 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration