Solved

Access Computers by Name not by IP

Posted on 2013-05-29
8
340 Views
Last Modified: 2013-07-14
I have a server running on CentOS 6.3. I am running a accounting software with tomcat web server. My question is that when other computer access the application hosted on tomcat on my local server they have to write my Server IP address and then port no. on which application is hosted. eg. 172.164.1.185:8080

I want instead of knowing my server IP address and port no. they just write my Server name and application is accessible to them.
e.g. accounts.org or university.org


I want to make clear that i am in a INTRA-NET environment and no computer except server can access internet in our LAN.
0
Comment
Question by:edreamers
8 Comments
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39205581
You could put your server name in DNS somewhere in your network but that will Not take care of the port number.  Since it is not on the standard port 80, they will always have to add it to the address.  The only way to get around that is for them to create a shortcut on their desktop or browser that includes all the necessary info.  The shortcut can have any name they want.
0
 

Author Comment

by:edreamers
ID: 39205598
I am new to Linux so kindly tell me step by step to how to add DNS name in CentOS
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39205628
You need to talk to your network administrator, they should be the person who sets up DNS for your network.
0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 
LVL 21

Expert Comment

by:Mazdajai
ID: 39205643
You need to use DNS if you want to use hostname instead of ip address. If NetworkManager  is running, you will need to add the DNS server in your ifcfg files; else you need to add them to /etc/resolv.conf

Can you post your output of /etc/sysconfig/network-scripts/ifcfg-eth0?
0
 
LVL 23

Expert Comment

by:savone
ID: 39205782
You can add the server name to the client machines hosts file.  You will still need to use the port number at the end though.

As root do this:

echo "172.164.1.185 accountapp" >> /etc/hosts

Then you can open a broswer and point it to:

http://accountapp:8080
0
 
LVL 77

Accepted Solution

by:
arnold earned 500 total points
ID: 39206391
Yum install named

You then need to configure named.conf with a local zone mydomain.local
Within which you would define
Server IN A IP_address

You would then need to configure your DHCP server to USB the servers IP as DNS server.

The Internet restriction can be achieved by configuring your firewall to deny any outgoing request unless it is comming from the server's IP.
You would the install and configure a proxy
Yum install squid

The example provided with adding your server IP name into a hosts file is the quickest and simplest. Depending on the systems in your LAN, for windows based systems the hosts file is in c:\windows\system32\drivers\etc\hosts.
0
 

Author Comment

by:edreamers
ID: 39248671
let me check.
0
 

Author Comment

by:edreamers
ID: 39324312
I tried many times but not able to succeed. So I am migrating to windows Platform. Thanx everyone for their support.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Remote desktop Ubuntu from Windows 10 5 92
ignore other .htaccess 2 58
How do I setup Wordpress to use Master / Slave MySQL database setup? 4 52
LINUX Field Separators 7 34
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Fine Tune your automatic Updates for Ubuntu / Debian
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

840 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