A hostname is the label given to a device connected to a computer network.

learn more… | top users | synonyms

1
vote
1answer
662 views

A command that gives username@hostname:pwd

I know that pwd gives the current working directory, hostname gives the current host and whoami gives the current user. Is there a single unix command that will give me the output of ...
0
votes
3answers
240 views

Debian cannot SSH to OS X by hostname (Windows OK)

I've seen some questions asking why xxx can't connect to MyMacName.local, which answer regarding Avahi as a requirement. I don't think I am in the same category as I can successfully connect to a ...
3
votes
1answer
5k views

Using DNSMasq for Local Hostname Resolution

I'm working on setting up a home intranet for me and my roommates. My idea is that we'll be able to store things like past utility bills in a place that's more accessible than a drawer in the kitchen ...
3
votes
1answer
248 views

Obtain the “pretty” hostname in bash

On my Fedora 19 system, I am able to change the system hostname with hostnamectl. This allows me to set several things, such as the static (normal) hostname, as well as a "pretty" hostname. Is there ...
1
vote
2answers
287 views

Prevent dhcpcd from setting hostname

How to prevent dhcpcd from setting hostname got from server? Change of it breaks a lot of things (including X session). My current distribution is Gentoo, init system is systemd and dhcpcd is spawn ...
1
vote
2answers
3k views

binding ip address to hostname

I just registered a domain name and paid for hosting with CentOS and I found that I had to do the binding myself following the lengthy steps http://www.linux-sxs.org/internet_serving/bind9.html I was ...
0
votes
1answer
2k views

Hostname not changing on Centos 6.4

We have centos machine. We have tried both the /etc/hosts and also /etc/sysconfig/network. Edited both files and service network restart. Yet the hostname is showing as localhost.localdomain. How to ...
4
votes
2answers
633 views

Obtaining remote host name in bash script

Sorry my knowledge of Linux bash commands is pretty basic, I've been searching for a while but I'm not 100% sure what I need to search for. I was wondering if there's a way to grab the current logged ...
2
votes
1answer
80 views

How to property configure DNS . . . from a conceptual perspective

I'm not looking for actual tools or techical how to type answers here. I'm in a complex networking environment, and I'm trying to understand the constraints on my choice of a hostname / domain / DNS ...
4
votes
2answers
3k views

in which file is hostname alias persistent, if not /etc/hosts?

In order to have an alias for my server, which can be seen in a "hostname -a" command, I edited the /etc/hosts file to add the alias at the end of the entry containing the hostname. For example, my ...
2
votes
1answer
38 views

Viewing hostnames in network

Is there Linux command equal to Net View in Windows, that shows hostnames in your network? I am in a VPN network and want to see computer names in my network.
1
vote
1answer
853 views

Changing the server name

I changed the name of the hosts in /etc/hosts to IP.GOES.HERE newname Apache does recognize the new server name; but still, via ssh i get this on the ssh prompt: [root@oldname] Why? Where else ...
1
vote
2answers
7k views

Unable to set hostname for use within network

I am having a lot of trouble setting up a hostname for my home server for use within my home network. My home server is running Ubuntu 12.04 LTS and all packages are up to date. Management of this ...
1
vote
1answer
301 views

Resolving an alias to a remote server

I have what I think is called an IP alias, which is used to access a Windows file server from a Unix server. The path on Unix looks something like: /folder/file.txt which is somehow resolved as: ...
1
vote
4answers
888 views

Setting a network hostname doesn't work

I'm on a Kubuntu 11.10 and I'm having trouble setting a hostname on the network. I already tried changing send host-name "myhostname" in /etc/dhcp/dhclient.conf or /etc/dhcp3/dhclient.conf with a ...
2
votes
3answers
85 views

Can DNS identify hostnames dynamically if they're statically configured?

I've got a small environment of ~40 VMs with static IPs on 12 servers, it would be dandy if I could refer to each VM by name. We have a lot of VMs come and go, so maintaining one static list is a ...
1
vote
0answers
3k views

centos 6, hostname won't resolve, dns issue, loop detected

I've searched everywhere and tried all the suggestions that I've seen, but I just can't get this to work now (it was working before). This is the first time I've ever installed a test server that I ...
7
votes
3answers
3k views

“Unable to resolve hostname” - how to cleanly change hostname without rebooting

At work, I work on a small website using Ubuntu servers hosted on Amazon EC2 instances. We have two webservers, and at any given time one of them is 'live' and one is 'testing', but when we've got our ...
4
votes
2answers
6k views

Creating alias to domain name with /etc/hosts

I have a domain setup to point to my LAN's external IP using dynamic DNS, because my external IP address changes frequently. However, I want to create an alias to this host, so I can access it with ...
-1
votes
2answers
163 views

Applications get started in the network instead of localhost [closed]

Normally uname -a shows me Linux localhost.localdomain [more stuff...] but for some reason it shows me some other other domain (but it is still my own terminal but really slow). I guess I am connected ...
4
votes
1answer
113 views

Getting a website's ip with 'host'?

Why is it that when I run the command host examplewebsite.com it gives me website's ip, but for some websites, when I type that IP address into the address bar and hit enter, it shows me a 404 page? ...
0
votes
2answers
3k views

How to add an IP to hostname file

I have a Centos 5.8 server. How can I add my server IP address 192.168.20.254 so that it reflects when I run the command hostname -i At the moment the command only shows the loopback IP 127.0.0.1 and ...
4
votes
1answer
176 views

show hostname in top

I'm using top with tmux to monitor the most-CPU-consuming processes on different computers. How can I get the hostname to be displayed in each pane? Can I tell top to display the hostname somehow?
2
votes
3answers
716 views

How to append / extend zshell completions?

I am using zsh with oh-my-zsh. Unfortunately, oh-my-zsh does not use file ~/.ssh/config for hostname auto-completion (see Issue #1009, for instance). This could easily archived by the following code: ...
7
votes
2answers
1k views

What are the ramifications of setting the hostname?

I have several Amazon EC2 servers and I'm using Chef to manage the configuration. I'd like to set the hostname so that the default bash prompt is more helpful. Right now after launching a new server ...
6
votes
1answer
358 views

Why the difference between network addresses reported by hostname and ping?

I have tried hostname and ping in a cluster machine, with different outputs. I am wondering what is the difference between the two? For example, on the same machine, hostname outputs node4.XXX and ...
2
votes
1answer
571 views

Fail to ssh to remote machine via hostname

The problem is that I fail to SSH to a remote machine via its hostname, while using its IP works. The hostname returned by command hostname is: california_desert while the name returned by command ...
2
votes
0answers
177 views

why is FQDN using external IP address

When postfix connects to the FQDN dur.bounceme.net it uses the external IP address: root@dur:~# root@dur:~# tail /var/log/mail.log Aug 28 04:39:45 dur postfix/master[6667]: terminating on signal 15 ...
5
votes
1answer
495 views

Is there any way to access a hostname containing an underscore?

I have this weird problem. I need to access a website that contains an underscore from Linux. The hostname is invalid and Linux does treat it as such. The problem is that access from Windows seems to ...
8
votes
3answers
4k views

How do I get to use .local hostnames with Arch Linux?

If I'm using Ubuntu or Linux Mint (the only two flavours I've tried and know work for sure), I can run something like this: wayne@myhost$ ssh wayne@otherhost.local And the name is automagically ...
6
votes
5answers
1k views

resolve all ip addresses in command output using standard command line tools

I have several log files that contain a bunch of ip addresses. I would love to be able to pipe the data through a program that would match and resolve ip addresses. I.E. cat /var/log/somelogfile | ...
2
votes
1answer
631 views

Changing hostname without errors

I tried to change my hostname according to this guide for Debian based system: I edited /etc/hostname I ran /etc/init.d/hostname start Though there are errors. Always when I write a sudo command ...
2
votes
3answers
490 views

I changed my hostname, rebooted and lost internet connection

I set a new hostname on my machine using: sudo hostname NEWHOSTNAME Then I restarted, and tried accessing the internet and nothing happened. I checked the hostname and it was set to ...
4
votes
2answers
16k views

Unable to resolve hostname

So I try to do: ssh $(hostname) and it tells me: ssh: Could not resolve hostname woofy: Name or service not known It knows that its own hostname is "woofy"; why can't it connect to itself?
7
votes
7answers
25k views

How to get the hostname along with the domain name?

In unix (Solaris) is there any command that returns the hostname and domain name together? For instance: hostname -> servername domainname -> us.xyz.com I need : servername.us.xyz.com
0
votes
1answer
581 views

How to set name to localhost in fedora15?

I want to set name to my localhost.for example I want mysite.com instead of localhost/mysite how to do that? I have searched but couldn't get a solution for Linux.
2
votes
1answer
291 views

Remove a directory level from a website URL

Can anyone tell me how to configure apache to not display a website folder name at the end of a base URL, please? - but only for one out of many websites. Let me describe the scenario ... I have a ...
2
votes
1answer
256 views

ZSH %m prompt escape not working as documented under Debian Linux

The zshmisc man page on my new Debian Squeeze install states, under SIMPLE PROMPT ESCAPES: %m The hostname up to the first `.'. An integer may follow the '%' to specify how many components of the ...
2
votes
2answers
2k views

Fedora 16 ssh over the internet/home network help. Same computer ok

I first posted this on serverfault, but this forum seem to be more appropriate. http://serverfault.com/questions/345471/fedora-16-ssh-over-the-internet-home-network-help-same-computer-ok I think I ...
2
votes
2answers
4k views

Get client hostnames from DHCP

I have a voyage 2.6.38 machine running DNSMASQ for a DHCP server and I would like to get the hostnames of the clients that acquire DHCP leases. How would I go about doing this?
5
votes
3answers
9k views

How does traceroute resolve names?

While writing a script, I wanted to reference a machine by the computer name that I gave it (e.g. "selenium-rc"). I could not ping it using "selenium-rc", so I tried the following commands to see if ...
1
vote
1answer
1k views

New SL6 system: No hostname?

This is in regards to Scientific Linux 6.1 system, but should also apply to CentOS 6.1 & RHEL 6.1. I am setting up a new Scientific Linux 6.1 system, using kickstart and DHCP (via xCAT). This ...
2
votes
2answers
390 views

How is my domainname determined?

If I look into /etc/hostname/ I can see the hostname of my device. This is however not the name that shows up when I use nslookup on our network. How do I tell the DNS server which name it should use? ...
2
votes
1answer
2k views

Hosts file on server with dynamic DNS?

I am setting up a RHEL-based server that is associated with dynamic DNS from DynDNS, with a domain of, say, "abc.dyndns.org" that is dynamically updated with the server's IP address. I have read that ...
8
votes
3answers
7k views

I changed my hostname, why is my bash PS1 prompt unchanged

I changed my hostname by editing /etc/hostname and can see the new hostname using the hostname and hostname -F commands. But the shell prompt is still showing the old hostname. This is Ubuntu 11.0.4 ...
0
votes
1answer
321 views

nacl crypto installation on arch

I am trying to install nacl crypto on my system: % uname -a Linux (none) 2.6.39-ARCH #1 SMP PREEMPT Mon Jun 6 22:37:55 CEST 2011 x86_64 Intel(R) Core(TM) i5 CPU M 540 @ 2.53GHz GenuineIntel GNU/Linux ...
2
votes
1answer
515 views

Short domain name to FQDN expansion

Is it possible to configure where the system will look for the machine if I enter just a short domain name? I work in a grid environment where the machines are many and spread across multiple ...
2
votes
1answer
365 views

How to add another domain to my chrooted named server

Firstly I successfully have a domain working in a chroot named. There are files in /var/named/chroot/var/named called mydomain.com.db and named.local and named.root. Also in /var/named/chroot/etc ...
3
votes
3answers
3k views

How to request a hostname from a DHCP server on Ubuntu?

I have an Ubuntu 11.04 server virtual machine. I would like to request a specific hostname from the DHCP server at the office. Since I don't run it often, the IP changes nearly every time that I boot ...
12
votes
2answers
29k views

How to change the hostname of a linux machine using terminal?

I logged in for the first time, opened terminal, and typed in ‘hostname’. It returned ‘localhost.localdomain.com’. Then I logged as the root user in terminal using the command, ‘su –‘, provided the ...