Go Back   Linux Forums by TotalPenguin! Get linux Help! > Linux > Linux Networking

Linux Networking This forum is for Linux Networking Only. Routing, servers, etc.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-04-2008, 01:18 PM
Off Off is offline
Member
 
Join Date: Feb 2008
Posts: 60
Off is on a distinguished road
Default How to determine Server Name in Linux

I know the default value is 'localhost' but I want the real network name. How can I determine the network name of my server inside of a Linux from an SSH command prompt?
Reply With Quote

Sponsored Links
  #2 (permalink)  
Old 03-10-2008, 05:37 PM
Jordan's Avatar
Administrator
 
Join Date: Nov 2006
Posts: 570
Jordan is on a distinguished road
Default

Do:

Code:
# cat /etc/hosts
Which should give you the host name.
Reply With Quote
  #3 (permalink)  
Old 03-21-2008, 02:42 AM
Senior Member
 
Join Date: Jan 2007
Posts: 109
Hektor is on a distinguished road
Default

Can't you also connect to a network share and see it? Or do a reverse resolve?
Reply With Quote
  #4 (permalink)  
Old 03-25-2008, 03:55 PM
Member
 
Join Date: Jan 2008
Posts: 78
LinuxBomber is on a distinguished road
Default

Doesn't Linux has something like 'localhost'??
Reply With Quote
  #5 (permalink)  
Old 03-26-2008, 12:56 AM
Off Off is offline
Member
 
Join Date: Feb 2008
Posts: 60
Off is on a distinguished road
Default

I know localhost, all computers (Win, Mac, Linux) have localhost which equals 127.0.0.1. I need the fully qualified host name.
Reply With Quote

Sponsored Links
  #6 (permalink)  
Old 03-26-2008, 06:22 AM
Super Moderator
 
Join Date: Dec 2007
Location: Denmark
Posts: 273
v0id is on a distinguished road
Send a message via MSN to v0id
Default

Have you tried hostname?
Code:
$ hostname
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ip Forwarding, Proxy Server for Linux? Pan Linux Networking 2 02-22-2008 12:48 AM
Who needs Windows Home Server with Linux around? kernel Linux News 0 08-22-2007 08:37 PM


All times are GMT. The time now is 04:25 AM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.