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

learn more… | top users | synonyms

2
votes
3answers
34 views

Where does `hostname` store the hostname that I've set?

This is quite puzzling. Does anyone know where the hostname command stores and reads hostname from? I thought it was /etc/hostname but there is no such file on this Linux system that I'm using. I ...
5
votes
2answers
84 views

How to permanantly change hostname in Fedora 21

I've heard that changing the hostname in new versions of fedora is done with the hostnamectl command. In addition, I recently (and successfully) changed my hostname on Arch Linux with this method. ...
4
votes
1answer
128 views

linux hostname -f command is not working on RHEL

I am running a RHEL 5.7 and the hostname command gives me the correct hostname. But hostname -s and hostname -f return: Unknown host. Why?
0
votes
1answer
33 views

Get hostname to show fqdn without --fqdn

I would like the hostname command to show the fqdn by default on CentOS Linux. What must be done to get this behavior? I am not looking to alias hostname to 'hostname --fqdn' I am looking to modify ...
1
vote
1answer
28 views

Create FQDN in LAN for Windows systems without samba

I just set up my raspberry pi. It is working great and I can easily access it from my local Windows machine using SSH. I gave it a custom hostname. I can acces the pi with this hostname only when the ...
0
votes
2answers
62 views

Can two hosts have the same IP address in /etc/hosts?

can two hosts share the same IP Address without a conflict. This is how my /etc/hosts looks like :- $ cat /etc/hosts 127.0.0.1 localhost 127.0.1.1 debian 127.0.1.1 mini Now as can be seen ...
1
vote
2answers
60 views

how to scp to host connected on a wifi?

I have my MAC on a wifi and am connected via ssh to a linux host. I want to copy some files from the linux host over to my MAC. I know, I can simply run scp on the mac to fetch each file via mac> ...
1
vote
0answers
95 views

Could not open X display after hostname change

I need to change the hostname of my Computer from localhost.localdomain to DESKTOP. However, I can't manage to do this, even after browsing some of the net. I've changed my hostname with hostname ...
0
votes
2answers
205 views

Can ping Debian VM via IP but not via hostname

On my work's network, my new debian headless VM is not visible via its hostname. I'm using: Debian Jessie Virtualbox bridged adapter I can see other VMs on my machine from the headless VM, and I ...
3
votes
1answer
140 views

What is the difference between hostname, hostname --fqdn, and hostname -A

I have a machine I changed the hostname of. I changed it in /etc/hosts, /etc/sysconfig/network, and with hostname command. hostname returns the correct shortname, hostname --fqdn returns the expected ...
0
votes
0answers
53 views

Chrome OS: Crosh Window and Hostname

I have a couple of questions regarding Chrome OS: By default Ctrl+Alt+T opens a crosh window within the Chrome browser. I have the Crosh Window extension, which I would like Ctrl+Alt+T bound to - ...
3
votes
1answer
117 views

Spoofing or removing DHCP client hostname in response to DHCP server

In linux, when my machine requests an IP address it also sends the hostname back to the DHCP server. How can I stop my machine from sending back this hostname? I use dhclient, possibly via ...
2
votes
2answers
12k views

How to change hostname on centos 6.5?

Hi can't seem to change the hostname on my centos 6.5 host. I am following the instructions I found here: http://www.rackspace.com/knowledge_center/article/centos-hostname-change I set my /etc/hosts ...
0
votes
2answers
152 views

Give every IP address a different hostname?

I have a Debian server with 4 IP addresses. All IP addresses use the same hostname. Is it possible to give every single IP address its own unique hostname?
5
votes
2answers
311 views

Determine FQDN when hostname doesn't give it?

In another question, I found that Puppet was generating certificates for my machine's FQDN but not the simple host name. In that example, kungfumaster was the hostname and was the value retrieved by ...
2
votes
1answer
234 views

How to set the tab name to an alias hostname of the remote host I'm connected to?

As you might know, by default, the hostname of an AWS instance is something like ip-12-34-56-78.us-west-2.compute.internal, so when I ssh to this host, the tab name is changed to root@ip-12-34-56-78 ...
1
vote
0answers
22 views

how to ensure stable domain names for newly-provisioned cloud server instances?

I've been playing with server configuration management tool Ansible, whose use often depends on reference to a local inventory file containing arbitrary host names. For example, # file: my_hosts ...
0
votes
1answer
175 views

Cannot resolve hostname

I'm using a Debian on a RaspberryPi and the problem that I'm having is that I can't connect to the Internet. Every time I try I see a message that says "cannot resolve hostname". From the terminal, I ...
1
vote
2answers
108 views

How to change the name of localhost to a custom name which is available to other users in LAN

I need to use the a custom URL name which is accessible from all devices in a LAN. I know that it can be set in the /etc/hosts file 127.0.0.1 myname 127.0.1.1 system09-System-Product-Name # The ...
1
vote
1answer
493 views

Why does hostname --fqdn only return the domain name?

Relevant files (slightly anonymized): heinzi@d2:~$ cat /etc/hostname d2 heinzi@d2:~$ cat /etc/hosts 127.0.0.1 localhost <myexternalip> d2.<myname>.at ...
1
vote
1answer
3k views

Postfix email bounced (mail for domain loops back to myself)

I have problem when i send a mail to example@orbialia.es for example2@orbialia.es My emails has bounced for this error: status=bounced (mail for orbialia.es loops back to myself) May 9 09:33:58 ...
1
vote
2answers
526 views

How to edit /etc/hosts without sudo?

I have a machine that I can only access using SSH. I was messing with the hostnames, and now it says: ssh: unable to resolve hostname I know how to fix it in /etc/hosts. Problem is, I need sudo ...
32
votes
2answers
2k views

How is it that missing 0s are automatically added in IP addresses? (`ping 10.5` equivalent to `ping 10.0.0.5`)

I accidentally typed ssh 10.0.05 instead of ssh 10.0.0.5 and was very surprised that it worked. I also tried 10.005 and 10.5 and those also expanded automatically to 10.0.0.5. I also tried ...
0
votes
1answer
3k views

CentOS 6 not regestering new hostname on Windows Server 2003

I rebuilt a Windows 7 Workstation with CentOS 6.5. The Windows 7 had a host name aaa attached to domain ddd.local. The new CentOS hostname is bbb. When I try to ping it: $ ping bbb ping: unknown ...
0
votes
0answers
23 views

User made host aliases [duplicate]

I would like to set up aliases for hosts /etc/hosts style, but I don't have root privileges. Would I be able to set these up from within my /home directory? How?
1
vote
1answer
31 views

Which kind of additional cleanup may be required after removing manually added entries from /etc/hosts?

My system is "Unable to resolve" removed entry from /etc/hosts. During development, I needed to add the custom domain entry to /etc/hosts, stating it resolves to 127.0.0.1. This mapping worked fine. ...
0
votes
1answer
375 views

Change elementary os hostname?

How do I change my hostname in Elementary OS? I've tried vi /etc/host didn't do anything.
2
votes
1answer
564 views

rsyslog using short hostname

I'm using CentOS 6.5 and rsyslogd: Name : rsyslog Arch : x86_64 Version : 5.8.10 Release : 8.el6 In rsyslog.d's conf file I have: $PreserveFQDN on and ...
0
votes
3answers
53 views

Why does hostname -h return 255

"No news is good news", which, sticking with the normal convention should return 0. Why does hostname -h return 255, especially when, 255 by convention, is meant to mean "Exit status out of range" ...
2
votes
1answer
90 views

Why when I enter the command “hostname” it returns something other than my computers name?

I am using a macBook Pro I enter: new-host-2:~ Justin$ hostname And it returns: new-host-2.home Why is this when it says in setting/sharing my computers name is "Justin's macbook pro" and computers ...
1
vote
0answers
581 views

Getting Samba 4.1's “internal DNS” to update hostnames from dhcpd

Samba 4 comes with its own "internal DNS" which can be used rather than BIND. Since Samba 4's main new feature is AD replacement, I would figure that its DNS would function similarly to Windows ...
1
vote
2answers
5k views

Hostname and IP address mapping in /etc/hosts

In my linux machine, when I run hostname, it shows mongodb, but when I run host mongodb, it shows: mongodb@mongodb:/var/hadoop/hadoop-1.2.1/bin$ host mongodb Host mongodb not found: 2(SERVFAIL) My ...
1
vote
1answer
131 views

AIX cifs hostname with underscore

I am trying to type this comand but for some reason it takes the first and not the second version. I have entered both the host names in the host file, FYI. This command works (hostname zq13c1): ...
1
vote
1answer
914 views

One ubuntu machine in LAN cannot access internet

I have 4 ubuntu machines connected in a LAN network by a single switch.Their IP address is from 192.168.10.10-192.168.10.13.But after I restarted one of them since disk problem,I find that this ...
3
votes
1answer
170 views

How to deny access to specific port when destination is NOT a specific host?

I'm trying to DENY access to port 1000 when it is being accessed through any host or IP that is NOT a specific host. I.e. If I try to access the service on sub.domain.com:1000 I should get in. If I ...
5
votes
3answers
507 views

Preseed.cfg ignoring host setting

I am installing Debian Wheezy (netinstall) in VirtualBox using preseed.cfg. I tried both d-i netcfg/get_hostname string somehost and d-i netcfg/get_hostname string somehost, but in both cases the ...
0
votes
2answers
1k views

URL with hostname doesn't work but it works with IP Address

I have a very basic question here. This thing is puzzling me a little bit. I have one Ubuntu machine which is running 12.04 and I am connecting to that machine from putty in my desktop (which is ...
0
votes
1answer
479 views

Changing hostname doesn't change the terminal name

I had set my hostname while installing linux as "ankit". i want to change it to "ankit.centos". I tried changing hostname in /etc/hosts, /etc/sysconfig/network and sysctl kernel.hostname=ankit.centos. ...
3
votes
1answer
372 views

Display hostname in GDM3 on Fedora 19 at login screen

I'm managing almost 100 lab PC's running Fedora 19. It's difficult to manage because it seems like no where that I can display the hostname at the login screen. GDM version: gdm-3.8-3.2
1
vote
0answers
86 views

Value of /proc/sys/kernel/hostname

I've set computer hostname in /etc/hostname a while ago (also there are record in /etc/hosts). Everything worked fine, but recently I've noticed that value of hostname (and /proc/sys/kernel/hostname) ...
1
vote
1answer
439 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
208 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
4k 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
225 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
240 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
518 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
77 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
2k 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 ...