Welcome to Linux Forums! With a comprehensive Linux Forum, information on various types of Linux software and many Linux Reviews articles, we have all the knowledge you need a click away, or accessible via our knowledgeable members.
Write an article for LinuxForums Today! Win Great Prizes!
Find the answer to your Linux question:
New to Linux Forums? Register here for free!
    Linux Forums > Your Distro > Slackware Linux Help > slackware server

Forgot Password?
 Slackware Linux Help   For help and Discussion about Slackware linux

Site Navigation
Linux Articles
Linux Forums
Linux Downloads
Linux Hosting
Free Magazines
Job Board
IRC Chat
RSS Feeds
Linux Forum Topics
Linux Forums
Your Distro
Linux Resources
GNU Linux Zone
The Community
Reply
 
Thread Tools Display Modes
Old 09-15-2007   #1 (permalink)
Just Joined!
 
Join Date: Apr 2005
Posts: 13
slackware server

ok so i dug out an old computer i no longer use and installed 2 nics and a dvd rom i had lying around.

so i want to setup this computer with slackware and run it as a server.

I have been using slackware as my desktop os for a while so i know my way around but im no expert.

What i want is my router connected to this server computer and then setup my desktop computer to connect to the internet and network through it.

Does anyone have any advice or know what i need to setup specifically.

also when i install slackware on this computer whats the best way to install it so i can easily upgrade when a new version of slackware is out.

any help appreciated thanks.
invisibleman is offline  



Reply With Quote
Old 09-15-2007   #2 (permalink)
Just Joined!
 
volomir's Avatar
 
Join Date: Jul 2006
Location: romania
Posts: 20
Send a message via Yahoo to volomir Send a message via Skype™ to volomir
hello, if you want to use that old pc as a router, you don't need to do a full install of slackware, just install the things you need

sharing your internet connection is quite simple, you just have to type these 2 lines

echo "1" > /proc/sys/net/ipv4/ip_forward

this activates ip forwarding

iptables -t nat -A POSTROUTING -s 192.168.0.0/24 -o eth0 -j MASQUERADE

this line shares the internet connection to all that ip class ( 192.168.0.0/24 ), and the interface that you receive internet from is eth0, while eth1 will be the nic that you will setup the gateway for your network 192.168.0.1 for example

on your desktop assign an ip from that class, let's say 192.168.0.2
if you use linux, don't forget to add the new route, after you previosly deleted the old route

route dell defaul gw
route add default gw 192.168.0.1

for dns servers, just use the ones you use on your router

cheers
volomir is offline   Reply With Quote
Old 09-16-2007   #3 (permalink)
Just Joined!
 
Join Date: Apr 2005
Posts: 13
i tried setting it up but its not working, I got the internet running on my server box now using 192.168.0.2 but i want to share this internet through the second nic, so i can setup a desktop computer using ip 192.168.0.12

i ran the above commands u said and they didnt give any errors.

The desktop pc i use:
ip = 192.168.0.12
subnetmask = 255.255.255.0
and the gateway set to the server? = 192.168.0.2

my rc.inet1.conf says:

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

# Config information for eth1:
IFNAME[1]="eth0:1"
IPADDR[1]="192.168.0.12"
NETMASK[1]="255.255.255.0"
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="192.168.0.1"




this is what ifconfig said:

eth0 Link encap:Ethernet HWaddr 00:06:4F:4E:4B:9D
inet addr:192.168.0.2 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::206:4fff:fe4e:4b9d/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:242 errors:0 dropped:0 overruns:0 frame:0
TX packets:239 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:135332 (132.1 KiB) TX bytes:26970 (26.3 KiB)
Interrupt:9 Base address:0x6000

eth0:1 Link encap:Ethernet HWaddr 00:06:4F:4E:4B:9D
inet addr:192.168.0.12 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:9 Base address:0x6000

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:1003 errors:0 dropped:0 overruns:0 frame:0
TX packets:1003 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:85118 (83.1 KiB) TX bytes:85118 (83.1 KiB)
invisibleman is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Free Magazines
A Newbie's Getting Started Guide to Linux
Learn the basics of the Linux operating systems. Get to know what it is all about, and familiarize yourself with the practical side. Basically, if you're a complete Linux newbie and looking for a quick and easy guide to get you started this is it.
subscribe
Run Your Own Web Server Using Linux & Apache - Free 191 Page Preview
Learn about everything you'll need to build and maintain your Linux servers, and to deploy Web applications to them.
subscribe
Open Source Security Myths Dispelled
Dispel the five major myths surrounding Open Source Security and gain the tools necessary to make a truly informed decision for your IT organization
subscribe
InformationWeek
InformationWeek is the only newsweekly you'll need to stay on top of the latest developments in information technology.
subscribe



All times are GMT. The time now is 03:45 AM.






© 2000 - - All Rights Reserved - Property of  MAS Media

Content Relevant URLs by vBSEO 3.3.1