LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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 07-06-2012, 03:31 AM   #1
Arjun
Member
 
Registered: Feb 2011
Posts: 120
Blog Entries: 2

Rep: Reputation: 0
access pc with name


I run website in linux & access it in lan via its ip address.

What configurations should i do in my linux system so that other users which are present in lan can access the website though their computer via a name not by my lan ip?

Thanks
 
Old 07-06-2012, 03:42 AM   #2
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,475

Rep: Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553
Google DNS and DNS servers.
 
Old 07-06-2012, 04:25 AM   #3
eSelix
Senior Member
 
Registered: Oct 2009
Location: Wroclaw, Poland
Distribution: Arch, Kubuntu
Posts: 1,281

Rep: Reputation: 320Reputation: 320Reputation: 320Reputation: 320
You need to precise if you have private IP address or public. And if you are administrator of this LAN. If private you need to create your own DNS server in LAN (the best if it will work all time), for example "dnsmasq" is good, simple tool for this. And configure clients to use it (if you can not administer this LAN configuration, than you must talk with somone who can). If public you can register your ip address on public DNS servers, but it usually cost some money per year.

Last edited by eSelix; 07-06-2012 at 04:32 AM.
 
1 members found this post helpful.
Old 07-06-2012, 04:43 AM   #4
Arjun
Member
 
Registered: Feb 2011
Posts: 120

Original Poster
Blog Entries: 2

Rep: Reputation: 0
Thanks for your reply

I have the private ip

I just want to use this facility only in the LAN not publicly. Only LAN computers must be able to access via name not by IP

Thanks
 
Old 07-06-2012, 05:47 AM   #5
Lexus45
Member
 
Registered: Jan 2010
Distribution: Debian, Centos, Ubuntu, Slackware
Posts: 361
Blog Entries: 3

Rep: Reputation: 48
If your LAN is really small, it may be easier to edit /etc/hosts files on each PC (in *nix-like OS), to point computers to some concret IP address. Windows also has the hosts file, but I'm not sure where it is located.

Code:
lexus@lexus:~$ cat /etc/hosts
127.0.0.1	localhost
127.0.1.1	lexus
10.15.22.3      webserver

# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

Last edited by Lexus45; 07-06-2012 at 05:48 AM.
 
Old 07-06-2012, 01:21 PM   #6
Ghostwheel
Member
 
Registered: Jun 2004
Location: Mid Michigan
Distribution: CentOS, Ubuntu
Posts: 41

Rep: Reputation: 0
Quote:
Originally Posted by Arjun View Post
Thanks for your reply

I have the private ip

I just want to use this facility only in the LAN not publicly. Only LAN computers must be able to access via name not by IP

Thanks
DNS is not just for the public internet. It is also for intranets. Check whether your router will allow your DHCP server to do DNS registrations.
 
Old 07-06-2012, 11:09 PM   #7
Arjun
Member
 
Registered: Feb 2011
Posts: 120

Original Poster
Blog Entries: 2

Rep: Reputation: 0
Quote:
Originally Posted by Lexus45 View Post
If your LAN is really small, it may be easier to edit /etc/hosts files on each PC (in *nix-like OS), to point computers to some concret IP address. Windows also has the hosts file, but I'm not sure where it is located.

Code:
lexus@lexus:~$ cat /etc/hosts
127.0.0.1	localhost
127.0.1.1	lexus
10.15.22.3      webserver

# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
So i have to change the host file in every computer. Is there any other way to just configure at single place ?

Quote:
Originally Posted by Ghostwheel View Post
DNS is not just for the public internet. It is also for intranets. Check whether your router will allow your DHCP server to do DNS registrations.
How can i check my router for this ?

Can you explain it briefly ?
 
  


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
Unable to see shares on samba server - no authentication access desired (open access) neoelf Linux - Networking 1 06-14-2009 03:18 PM
How to access Access root(/) hard drive attached in Windows XP machine farrukhndm Linux - Software 2 07-29-2008 12:52 PM
Debian Woody: Can't access internet through router, but can access network computers marales314 Linux - Networking 3 06-09-2006 12:33 PM
How to access database created with MS Access on Windows using PHP on Linux Server anjani.78 Linux - Software 1 12-21-2005 06:07 PM
WIFI WLAN / Cannot access internet but can access the router configuration page?SUSE thomas939 Linux - Wireless Networking 12 12-13-2005 10:28 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:21 PM.

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