Tagged Questions

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

learn more… | top users | synonyms

0
votes
2answers
38 views

CentOS 7 hostname will not change

I have two CentOS 7 VM's running in virtualbox. On each of the machines I want to set the hostname and a static IP address. VM1 works just fine. VM2 does not. I did the same thing on both servers so ...
1
vote
3answers
34 views

What will be prioritized in a conflict between ~/.ssh/config hostname and /etc/hosts?

What if one host is defined in /etc/hosts like: 192.168.0.100 server and one is defined in ~/.ssh/config like: Host server HostName 192.168.0.100 and you ssh into server: ssh ...
1
vote
1answer
22 views

Correct hostname doesn't change in entire system

I have a very strange problem with my hostname on Debian 7+. I've changed the hostname on my new server but for some reason it doesn't change in wierd places. Right now I get the old hostname when I ...
-2
votes
0answers
28 views

no ping to newly added /etc/host [closed]

I just added some cat /etc/host 127.0.0.1 google.com goo ping goo ping: unknown host goo ping google.com | head -1 PING google.com (109.194.169.113) 56(84) bytes of data. Nothing changes after: ...
2
votes
2answers
91 views

Understanding hostnames

I was recently setting up an MTA on a VPS, and while configuring it I realized I’m quite confused about the concept and implementation of hostnames in Unix. I have a solid understanding of the DNS, ...
2
votes
1answer
34 views

Dig command: Is the output guaranteed to be sorted?

Let's say I'm trying to lookup the IPs mail.yahoo.com, gmail.com and mail.google.com If I execute: dig @8.8.8.8 +nocomments +noquestion \ +noauthority +noadditional +nostats +nocmd \ ...
6
votes
4answers
187 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
152 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
210 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
43 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
43 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
91 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
87 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
142 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
282 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
193 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
66 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
152 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 ...
3
votes
4answers
21k 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
184 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
408 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
306 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
23 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
218 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
127 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
727 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
629 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
32 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
429 views

Change elementary os hostname?

How do I change my hostname in Elementary OS? I've tried vi /etc/host didn't do anything.
3
votes
1answer
654 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
92 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
636 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
7k 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
144 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
1k 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
188 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
600 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
2k 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
621 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. ...
4
votes
1answer
424 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
90 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
567 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
227 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
240 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 ...