LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-13-2002, 11:27 PM   #16
bbenson
LQ Newbie
 
Registered: Sep 2001
Location: Charlotte, NC
Distribution: Red Hat
Posts: 6

Rep: Reputation: 0

I don't like the idea of using the loopback interface for this purpose. If you expect to route around the network, you're going to have to use routable IPs, like those assigned by your DHCP server. If there aren't any other boxes, no problems.

By easily, I mean through the use of hostnames, not IPs. You couldn't tell another computer in your network to talk to "Alpha" without giving it another IP address, cuzz routing to 127.0.0.1 on any other computer would result in the computer routing to itself through the loopback interface.

IMHO, I would still go with adding the dynamically assigned IP to the /etc/hosts file and copy that around to the other boxes (if any)... this way all boxes can be reached easily through the use of hostnames and you wouldn't have to remember IPs.

Of course, if you don't mind typing in the IP (which, depending on what programs are used for FTP, telnet, SSH, etc, might not be a problem), then you could do it the way David suggested and I'm just a big blowhard.

Have fun!
 
Old 01-14-2002, 09:04 PM   #17
DavidPhillips
LQ Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,163

Rep: Reputation: 58
I guess I misread the problem or something,

you want to create an /etc/hosts file after ip is assigned?

try this, there may be some other easy way

echo "127.0.0.1 localhost.localdomain" > /etc/hosts

echo -n "yourhostname " >> /etc/hosts

ifconfig eth0 | grep inet | cut -d ":" -f2- | cut -d "B" -f1 >> /etc/hosts

here is the result

cat /etc/hosts
127.0.0.1 localhost.localdomain
yourhostname 24.15.28.124
 
Old 03-16-2002, 04:46 PM   #18
driver
LQ Newbie
 
Registered: Mar 2002
Posts: 1

Rep: Reputation: 0
Question Big question

Hi,

I am restricted access to Linux server by IP.

How I could to restrict the access by MAC address of ethernet adapter also?

Linux version is RED HAT 7.2


Thanks in advance!
 
  


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
setup internet king kong killa Linux - Networking 18 06-07-2004 03:54 PM
internet setup oregonroper Linux - Networking 3 10-06-2003 08:36 PM
internet / network setup darazman Linux - Networking 2 08-21-2003 07:02 PM
How to setup Internet ? thundersnows Linux - Networking 0 08-04-2003 10:46 PM
Internet Connection Setup lilcap Linux - Networking 1 07-20-2003 06:43 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:38 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
Open Source Consulting | Domain Registration