Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [hostname]

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

0
votes
0answers
12 views

What does journal hostname field refer to?

I have a question about hostname field that journalctl displays. From journalctl documentation I know that _hostname= is displaying the name of the originating host. So in that case this log: march ...
4
votes
1answer
383 views

Bash prompt takes only the first word of a hostname before the dot

I configured my machine as the following hostname ( in reshat 7.2 ) digi.master01.usa.com but my prompt is like this [root@digi ]# while we want [root@digi.master01 ]# any idea how to change ...
1
vote
2answers
57 views

NetworkManager interferes with hostname configuration

I'm running an arch system with KDE4/Plasma, wpa_supplicant, networkmanager, systemd ... # cat /proc/version Linux version 5.0.0-arch1-1-ARCH (builduser@heftig-18825) (gcc version 8.2.1 20181127 (...
0
votes
1answer
27 views

From server cannot ping server itself by its hostname while can ping by its IP

I host an ubuntu server at a data center and worked well for years till last night the server can not ping itself by host name. No config has been changed. Here are what it can/can not do now. From ...
2
votes
0answers
46 views

name resolves doesn't work in chroot for users, but does for root

I've booted a live-cd in order to download, compile and install a few packages on a otherwise working system without actually booting said system. I've created a build user on the system by issuing ...
1
vote
0answers
97 views

While using a debian preseed how to assign hostname manually? [closed]

I made a preseed.cfg for a Debian 9.7 netinstall and add it to the initrd on the ISO. There a two things I want to assign manually during installation, the IP address and the hostname. The IP address ...
0
votes
2answers
83 views

How can I find out the hostnames of other computers in the same local network?

In my local wifi, I can find out the IP and MAC of another computer which also runs Lubuntu, and whose hostname is known to me. $ sudo arp-scan olive [sudo] password for t: Interface: ...
0
votes
2answers
89 views

Why does Python 'gethostname()' return the entire FQDN when run on a FreeNAS server console?

I get this (FreeNAS 11.2-RELEASE-U1): Python 3.6.5 (default, Dec 20 2018, 21:27:40) [GCC 4.2.1 Compatible FreeBSD Clang 6.0.0 (tags/RELEASE_600/final 326565)] on freebsd11 Type "help", "copyright", ...
0
votes
2answers
168 views

How to access a device connected in local network with hostname?

I tried accessing a webpage in a server within the local network with the host name of the device followed by its folder path and the name of the file(it is a basic php file). In first system it ...
15
votes
2answers
2k views

Does a computer system (Linux) only have one host name?

hostname is used to display the system's DNS name, and to display or set its hostname or NIS domain name. Does a computer system (Linux) only have one host name? In virtual hosting, several host ...
0
votes
1answer
175 views

Generating default DKIM keys: Cannot determine host's domain name, so skipping default key generation

I'm following this guide https://www.linuxtechi.com/configure-domainkeys-with-postfix-on-centos-7/ When I get to this section, it gives an error # opendkim-default-keygen Generating default DKIM ...
1
vote
1answer
76 views

Linux/Windows client resolve Linux hostname on LAN

According to Debian's RPi3 image wiki, I should be able to ssh into a Raspberry-Pi, with just the hostname. I shared internet from my Debian laptop, WiFi to the a Raspberry-Pi over Ethernet, but the ...
1
vote
1answer
277 views

Understanding why hostname -i returns strange IP address

I am referencing the following question because it's similar but not the same: hostname -i returns strange result in linux On my CentOS 7 system, I get a strange IP address from "hostname -i" after ...
0
votes
1answer
58 views

What is this random name in my command-line prompt? [duplicate]

I'm trying to figure out what this (obretschlt2-w7) is, from my command-line prompt. I'm using a conda environment, with the name µ_env, with my Username mu. However I can't figure out where the 2nd ...
7
votes
1answer
405 views

How to deal with underscores in hostnames?

I got DNS set up on my company's server and it works just fine, except I got problem with some phones. For example one of the phones is “Huawei P9 lite”, and it's hostname (set on the phone, no chance ...
2
votes
0answers
366 views

dnsmasq is not resolving local hostnames

I have a local Linux server running dnsmasq for my LAN. It has been working without issues for the last several years. I keep the operating system and packages regularly updated. After yesterday's ...
2
votes
1answer
1k views

How do I fix my problem with hostnamectl command. It cannot connect to dbus

I am running Debian 9.4. hostname works. $ sudo strace -f hostnamectl ...snipped... connect(3, {sa_family=AF_UNIX, sun_path="/var/run/dbus/system_bus_socket"}, 33) = -1 ENOENT (No such file or ...
0
votes
0answers
194 views

ssh to another user of the same host using dns domain

Is it a problem to ssh to another user of the same host using dns domain? I cannot conigure it. I cannot configure it to passwordless connection. Also when I am trying to connect with password the ...
2
votes
2answers
283 views

uptime Script help [closed]

I am looking to build a script that will log in to multiple servers using a host file and run uptime, hostname -I and hostname Script so far echo"" ; echo "hostname:" $(ssh $HOST hostname) ; echo "...
1
vote
0answers
697 views

ssh does not recognize host name defined in config file [closed]

My ssh can no longer resolve my hostname. Everything was working fine until I did a security update on my ubuntu v16.04. I try to do ssh <myhost> and receive the error ssh: Could not resolve ...
1
vote
3answers
344 views

macOS Sierra (10.12.6) hostname command not appending “.local”

To be brief: From what I understand the hostname command has an option -f. From the man page: -f Include domain information in the printed name. This is the default behavior. As it's the ...
1
vote
1answer
40 views

SSH connects but stays on the same machine [closed]

I've got an unusual problem at hand that I couldn't solve for 2 days. I've got two KVM running on my real machine. One of them is named headnode and the second is named computenode. These machines ...
14
votes
2answers
4k views

What's the point of the hostnamectl command?

As opposed to editing /etc/hostname, or wherever is relevant? There must be a good reason (I hope) - in general I much prefer the "old" way, where everything was a text file. I'm not trying to be ...
3
votes
1answer
72 views

How to change `ping from` value when pinging Linux server?

Content of hostname file in my server is: # cat /etc/hostname sub.mysite.com But when I ping my CentOS 7 server it says: # ping sub.mysite.com 64 bytes from sub ... Even: # ping ns1.mysite.com ...
1
vote
1answer
25 views

How to attach domain to RHEL7 using the shell?

I would like to know what files must I edit in order to add a domain on a RHEL7 machine? Example: Hostname: Server1 Domain Name: qwer.tyu.iop Result: Server1.qwer.tyu.iop
0
votes
1answer
327 views

CentOS Application Installer Updates failed “Cannot resolve hostname”

I attempted to run updates from the Application Installer and ran into the following error. failed to download https://extensions.ognome.org//extension-query/?shell_version=3.22.3&page=1&...
2
votes
1answer
225 views

BIND as a DNS server host command is refused

I am attempting to run my host machine as a DNS server, it will also function as the gateway. My /etc/named.conf is as follows: options { directory "/var/named/"; allow-query {127.0.0.1;...
1
vote
1answer
30 views

Is there a canonical method a host can use to self-rename?

Naming hosts and keeping track of them is a lot of work on a home network or on a test cluster of VMs. Is there a canonical way to make a host self-rename from whatever name it was initially set with ...
1
vote
1answer
250 views

Suppress “Name or service not known” on ping

I have several Raspberry Pi's named numerically (pi0, pi1, etc). They have static IP addresses, but I wanted a simple tool to check on them and make sure they were online even if they got the wrong IP ...
0
votes
1answer
54 views

Set hostname via ssh error SCRIPT

im using this script to change hostname via ssh but i got some errors. read -p "Insira o IP : " ip read -p "Insira o nome do utilizador : " host read -s -p "Insira a palavra passe : " oldpass ...
-1
votes
1answer
119 views

Setting up hostname, hosts & domain correctly [closed]

I'm new to this platform but I try to be as specific as possible. I researched quite a lot but every new answer just adds to the confusion at the moment. I am running Debian on my first server with a ...
1
vote
1answer
50 views

Is it possible to display a different hostname, when a user logs in?

I have an issue where my customer used a different hostname naming convention than my company did, for the devices they purchased from us. Example: We named the devices Lenny1, so the FQDN is lenny1....
0
votes
0answers
244 views

Cannot change hostname of raspberry pi in local network

I have a clean install of the debian-based OSMC os on a raspberry pi. I've manually set a static IP: $ ifconfig wlan0 wlan0: flags=-28605<UP,BROADCAST,RUNNING,MULTICAST,DYNAMIC> mtu 1500 ...
0
votes
1answer
34 views

What is the best approach to find a system's domain name?

I use the following syntax in order to find the domain name on a Linux machine: hostname | sed s'/\./ /g' | awk '{print $2}' hostname master02.sys65.com hostname | sed s'/\./ /g' | awk '{print $2}' ...
1
vote
0answers
99 views

Is changing the system hostname on a server with a running MySQL / MariaDB service harmful?

I want to change the hostname of a running CentOS 7 server which is running MySQL (mysql Ver 15.1 Distrib 10.0.33-MariaDB, for Linux (x86_64) using readline 5.1). Although I can't find any sources ...
1
vote
1answer
52 views

How can I ping my dhcp server using hostname?

I've just configured a PC with a dhcp server and an apache server on it. I want to set a hostname to my server (i.g "myserver") in order to be able to access its web server by writing on the browser "...
0
votes
0answers
187 views

UFW blocks hostname lookup on LAN for ssh and ping

I'm experiencing a problem connecting to hosts on my LAN via their hostname only when UFW is enabled. When UFW is enabled: ssh <machine> gives the message: ssh: Could not resolve hostname &...
1
vote
2answers
7k views

Could not reliably determine the server's fully qualified domain name

I was following this tutorial to setup two virtual hosts in Centos 7. The issue is i am getting the following error while restarting the httpd. [userme@server ~]$ sudo systemctl restart httpd....
1
vote
1answer
69 views

Changing system hostname makes samba being unaccessible

I found something weird in my debian 9 config. I changed my hostname by editing /etc/hostname and rebooting from "myhost" to "myhost-hello". Since this modification connecting to the machine via it'...
3
votes
1answer
2k views

Is /etc/init.d/hostname.sh still an option for debian stretch?

I changed the host name and went to make it stick, but my previous solution didn't work. I am using Linux raspberrypi 4.9.59-v7+ #1047 SMP Sun Oct 29 12:19:23 GMT 2017 armv7l GNU/L. Is there a new ...
1
vote
1answer
2k views

How the hostname resolution / lookup happens in Linux? [closed]

I am new to Linux and need to know how nslookup command resolves hostname? what are the configuration files that are used by nslookup command - I need to know the exhaustive list of files that are ...
1
vote
1answer
2k views

SUSE Linux Enterprise 12: Change Hostname permanently

I want to change the hostname for a VM, but struggle to do it permanently. Already changed it via /etc/hosts and /etc/hostname, but did't work out. Does anyone have an advice? Thanks in advance.
1
vote
2answers
248 views

How can I log into a running docker instance?

poking docker to see how it works: ubuntu@ip-172-31-14-19:~$ ubuntu@ip-172-31-14-19:~$ sudo docker run --net=host -d -t jmar71n/freepbx ...
1
vote
1answer
54 views

openSuSE prompt on AWS configuration

On an Amazon aws ec2 openSuSE instance: thufir@ip-<ip>:~> thufir@ip-<ip>:~> echo $PS1 \u@\h:\w> thufir@ip-<ip>:~> how do I set the prompt to something more friendly? ...
1
vote
1answer
1k views

Why isn’t the hostname command getting the FQDN from /etc/hostname? [duplicate]

I set the hostname. # more /etc/hostname kafka01.ocff4.com The hostname is still as follows. hostname kafka01 I restart using the following command. systemctl restart systemd-hostnamed But ...
0
votes
1answer
243 views

Postfix myhostname change

I'm currently trying to change the myhostname field. So, I have this situation: My server doesn't need an Internet domain anymore, since it will be a local host server. But I want to serve mail ...
0
votes
1answer
126 views

How do I change hostname in trueos

I want to change the hostname that was generated during installation. How do I do that in Trueos?
1
vote
1answer
163 views

How a Virtualbox ubuntu VM able to resolve another ubuntu VM's hostname.?

I have 2 Virtualbox VM's on which I have Ubuntu 15. The hostnames are: Machine 1: satya-VirtualBox Machine 2: sam1-VirtualBox Hosts file on machine 1- But I am able to ping machine 2 from 1 using ...
0
votes
1answer
74 views

My Linux server forgets its host name every day

I have a Linux server # uname -a Linux site 3.12.39-47-default #1 SMP Thu Mar 26 13:21:16 UTC 2015 (a901594) x86_64 x86_64 x86_64 GNU/Linux # lsb_release -a LSB Version: n/a Distributor ID: SUSE ...
7
votes
1answer
17k views

How to filter by host name in Wireshark?

Display filter in form ip.src_host eq my.host.name.com yields no matching packets, but there is traffic to and from this host. DNS name is resolved successfully, and filters using ip addresses like ip....