Ubuntu Network

dizital

Distinguished
Apr 27, 2010
24
0
18,510
I am setting up a home network with ubuntu being the server for my network. I currently have it up and running just fine, I have 2 nic cards eth0 and eth1, I'm wanting to use eth0 for the server to connect to the internet directly, and use eth1 to connect to the swith to share the internet and file system of the server, I have setup so far that I do have internet on the server and I have been able to ping my windows machine but I cannot get the windows machine to connect to the server,

i'm brand new to the ubuntu family and this is my first time actually setting up a network with a server and a switch involve.

thanks for all the comments.
 
I'd agree about putty, but I always install webmin on my *nix systems. It's especially useful with my FreeBSD server which runs headless. (That plus XMing for an XWindow connection and putty for emergencies.)

Webmin does make life easier when configuring DHCP, DNS and firewalls (and lots of other servers as well).
 

linux_0

Splendid
Webmin is great in the hands of an experienced user but it's also a security threat if it's not totally locked down. :)

There's been a lot of incidents of E.V.I.L peeps targeting open source routers with default passwords and other vulnerabilities as well as webmin and lots of other management tools.

It's always best to drop all incoming connections to webmin, ssh and just about all other services on a router.

Semper Fi :)
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510
yea i'm looking at getting a netgear wireless vpn/firewall, would the netgear replace my linksys wireless router or would i still need that?
 

linux_0

Splendid
Linux can be a great VPN and firewall, you'll just have to find a nice Linux and BSD friendly wifi card.

You'll be able to combine wired, wireless, firewall and VPN functions in the same Linux system if that's what you want to do.

Good luck :)
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510
That's what my intentions are, I currently have all computers connected to the linksys router, as I'm currently setting up the server with the switch
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510



On the steps that it shows I can't get my machine to setup the network cards, all I can get it to do is the address and the subnet address. I have no netmask address, broadcast address network address like the example show. It saids that he added the code to the file but, I don't know how to add the code to the file, any help in that area?
 
I take it the problem is with the eth1 interface? To add the code to the file just use a text editor to open the file /etc/network/interfaces and type the code in. You'll need to be logged on as root to do this. Hence the "su" command first, which changes your logon to root temporarily (you'll be prompted for the root password). The server will act as a DHCP server for other computers on your network, but it needs to be set up with a fixed address itself. The one used here is just one from the available non-routable addreses that are available for private networks.

Most Linux configuration is simply a matter of editing text files like this. The link show use of the "vi" editor, but this is a little unfriendly; any text editor will do. If you're going to play around with Linux it's a good idea to get to know "vi"; it's the one editor that you can be 99.9% sure is available on any *NIX system and it may well be the only editor that will be available if you ever have to boot in single-user mode.
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510



Should the connects thats going to support my network that is going to be connected to the switch be a static ip or can it be a dhcp, i'm thinking static so it doesnt change but i could be wrong.
 
Yes, the interface that connects to the switch (eth1) should be a fixed IP address (at least it's going to be a lot easier that way).

As audiovoodoo says, "sudo" will give root privileges for one command (as long as the "/etc/sudoers" file is correctly set up, which I guess it will be with Ubuntu). It will prompt you for a password, which is your password. Alternatively, "su" changes the terminal session to a root logon until you "exit" it. This also prompts for a password, but this time it is the root password, not your password.

"sudo" is generally considered the safer option as you don't need to remember to cancel the elevation of privilege.
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510



Would I need to set a host name for the gateway? I'm not going to have a website.
 
You don't need to set a hostname for the gateway. But it can be convenient, for example if you wanted to access it from another computer via SSH or run other services on it. I always give all of my machines, real or virtual, a name for this reason.

No device on the Internet needs a name, but it makes life a whole lot easier.
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510



On setting up the static ip address on my other machines which ip address do I need to give them,

the address, network or the broadcast ip address,

also when i goto windows to set the static ip address do i need to give it a gateway address cause my server eth1 doesn't have a gateway address either.

I'm currently installing webmin ask its asking me for a port number for my web server, is there one already setup or am I creating one at this point?
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510
when i try to install this line

apt-get install dhcp3-server bind9 vim perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl libmd5-perl

i get this error E: Couldn't find package bond9
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510
on the webmin application it saids to configure the dhcp but where exactly do i go to setup that? under the server tab?
 

linux_0

Splendid
You don't need a gateway on the internal network card ( eth1 ) like 10.0.0.1

Configure dhcp to set the router to 10.0.0.1 if your eth1 is configured with that IP.

You'll have to enter your gateway for the external network card ( eth0 ) 24.0.0.? -- that's just an example you'll need to get your IP from your provider.

Take a look at the wiki http://doxfer.com/Webmin

Good luck :)
 

dizital

Distinguished
Apr 27, 2010
24
0
18,510
Ok, I have no idea what I'm doing wrong at this point, I've tried changing this differant times, but I'm constantly getting bad subnet/mask combination subnet 192.168.25.1 netmask 255.255.255.0