Solved

Setup Static IP On Debian

Posted on 2006-10-22
4
2,060 Views
Last Modified: 2012-06-21
I've recently installed Debian and am trying to figure out how to configure Debian to assume a static local IP. My network isn't anything fancy, just a LinkSys router that serves as my DHCP server. I have my windows computer set to a local IP 192.168.1.100 and would like to do the same for my new Debian server so that I can SSH into the same local IP. I would like to setup this in Debian itself as oppose to mapping the IP based upon the MAC address though the router.

Thanks for any ideas!

~ C
0
Comment
Question by:clickclickbang
  • 2
4 Comments
 
LVL 1

Accepted Solution

by:
Grime121 earned 300 total points
ID: 17784527
type this: pico /etc/networking/interfaces

now change your nic to read something like this:

# The primary network interface
auto eth0
iface eth0 inet static
        address 10.0.0.254
        netmask 255.255.255.0
        network 10.0.0.0
        broadcast 10.0.0.255
        gateway 10.0.0.1
0
 
LVL 1

Expert Comment

by:Grime121
ID: 17784532
errr, it's pico /etc/network/interfaces

when finished press Ctrl-X, then 'y', then 'Enter' to save changes.
0
 

Assisted Solution

by:awerley
awerley earned 200 total points
ID: 17791087
the above is correct... the interfaces file is located at /etc/network/interfaces

Also if your network is 192.168.1.0, you would much rather a configuration like this assuming you want your linux box at 101 since your windows is at 100 and your router is at 192.168.1.1... but you can obviously change it to what you want/need:

auto eth0
iface eth0 inet static
address 192.168.1.101
netmask 255.255.255.0
gateway 192.168.1.1

Best of Luck,
Aaron
0
 
LVL 1

Author Comment

by:clickclickbang
ID: 17796120
Awesome stuff! Thanks guys!
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question