Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

Questions tagged [hostname]

The unique name by which any device attached to a network is known by.

Filter by
Sorted by
Tagged with
0 votes
0 answers
29 views

problem with ping host only adapter from host machine

I have a VirtualBox installed Linux and I added it to my already having bridge adapter(enp0s3), and host-only adapter(enp0s8). I tried to ping it from my host machine, I used ping to enp0s3 it worked ...
user avatar
0 votes
0 answers
9 views

Prevent Domain Users from changing Hostname

I recently domain-joined a laptop that uses Ubuntu 20.04. Part of the steps to allow domain users to sudo was to do what is shown in the image below. The issue with doing the step above is that it ...
user avatar
  • 1
0 votes
1 answer
29 views

How to set up servername.local in Ubuntu server

I'm trying to set up an Ubuntu server with a fixed IP address. I've set up a reserved ID in my firewall and that works - the server uses DHCP to retrieve the 192.168.1.200 IP address fine. However, ...
user avatar
0 votes
0 answers
19 views

Hostname mismatch between Hostname -a, Hostname -A and Hostname -fqdn

I set up Ubuntu Server 20.04 LTS 64bit on my raspberry pi 4 using the Raspberry Pi Imager software. I set my hostname to be rpi but when I went to ssh in I found that it couldn't resolve that name. ...
user avatar
  • 1
1 vote
0 answers
12 views

Got 2 Ethernets one on WAN the other LAN. but LAN Could not resolve hostname

I keep getting Could not resolve hostname but I can put in the IP and it works. I could not open the port to WWW on my LAN so just using a router and it gets on like that. Then another router for my ...
user avatar
0 votes
0 answers
43 views

Command "host 127.0.0.1" does not return localhost on Ubuntu 20.04

Command "host 127.0.0.1" does not return localhost on Ubuntu 20.04. Is it possible to have it return localhost like it does in Ubuntu 18.04? We've got some tests that require this to work ...
user avatar
-3 votes
1 answer
38 views

bash: change the hostname displayed without running the `exec bash` command

I have: lohacker@john:~$ I have a function: test1 () { sudo hostname philip echo something } If I try: lohacker@john:~$ test1 something lohacker@john:~$ hostname philip lohacker@john:~$ As ...
user avatar
1 vote
1 answer
296 views

ssh known_hosts file not using hostnames anymore

I'm running into this weird issue when I ssh into a new machine but my known_hosts file gets updated with a hash of sorts but not the hostname. This ends up with me not being able to autocomplete when ...
user avatar
1 vote
0 answers
253 views

Ping to avahi device does not work all the time

I just added a NAS to my home network and gave it the hostname mynas. I tried to access the NAS from Kubuntu 20.04 (especially via Samba). It works fine when using plain hostname, but it fails when ...
user avatar
0 votes
0 answers
96 views

Any way to preseed hostname and domain name for net install?

This is from my preseed file: # Any hostname and domain names assigned from dhcp take precedence over # values set here. However, setting the values still prevents the questions # from being shown, ...
user avatar
  • 731
0 votes
1 answer
55 views

Host name access not working

Ubuntu Server 20.04.3 LTS Linux 5.4.0-88-generic Hostname : plexserv All was working fine, Plex and Samba set up, could access files on the server from Windows and MacOS machine no problem. Then I ran ...
user avatar
1 vote
1 answer
2k views

hostname: No address associated with hostname

Good day! I am using 20.04.3 Ubuntu server on my Raspberry Pi 4, I am using my Rp4 as Pi-hole w/ unbound as well as a docker, everything went fine except for 1 which is the the title of my post I did ...
user avatar
0 votes
1 answer
150 views

can not change hostname

I want to change the hostname of a Ubuntu 18.04 server. I did: hostnamectl --set-hostname newname --static changed /etc/hostname file to newname changed /etc/hosts file to newname rm -f /etc/machine-...
user avatar
0 votes
1 answer
655 views

nmap is not showing hostnames

I am new to linux, and I am trying to get all the hostnames from the hosts of my local network. I was trying the command: sudo nmap -sn 192.168.0.0/24 and also: sudo nmap -sn -R 192.168.0.0/24 but ...
user avatar
  • 1
0 votes
3 answers
540 views

How to find the username who performed SSH?

When one does ssh oracle@hostB on a local host say A, will the hostB know the user who performed SSH on host A? Is there a way to find out the username who performed SSH?
user avatar
0 votes
1 answer
353 views

hosts: files mdns4_minimal [NOTFOUND=return] resolve [!UNAVAIL=return] dns myhostname

Aloha, i'm on Ubuntu 18.04 and i recently executed a deadly git clean command that was meant to clean the Hard Drive Cache and that whipped out nearly every thing on my hard disc. Now i can't license ...
user avatar
2 votes
0 answers
378 views

cloud-image passes default hostname to dhcp server despite cloud-init script

How do I get the Ubuntu 20.04 Cloud Image to send an individual hostname along with its initial dhcp request? I am deploying Ubuntu 20.04 Cloud Images on vSphere using Nutanix Calm and a cloud-init ...
user avatar
0 votes
1 answer
49 views

Add an alias for LAN/WLAN IP

Right now Apache server is listening on port 80. I want people on the same network to access the site as random.xyz but without making that my actual hostname (which is ubuntu right now). The manual ...
user avatar
  • 299
0 votes
1 answer
505 views

How do I change the hostname in a cutomized live-cd Ubuntu 20.04

I have customized a 20.04 live-cd using Cubic. I need help with changing the hostname to obo. No matter what method I've tried it always defaults back to 'Ubuntu'. Using Cubic's CHROOT terminal, I'...
user avatar
1 vote
2 answers
926 views

ssh-ing in to ubuntu comp by hostname suddenly stopped working (`Could not resolve hostname [ubuntu_comp_hostname]: Name or service not known`)

(see EDIT added to end, bout avahi stuff) It just does this: > ssh -v [ubuntu_comp_hostname].local => OpenSSH_8.2p1, LibreSSL 3.0.2 debug1: Reading configuration data /home/o1/.ssh/...
user avatar
  • 341
0 votes
1 answer
97 views

File system check at boot time fails

My Ubuntu 20.10 installation was showing a blank screen after booting, so I started it in recovery mode and tried sudo fsck -f /. The error it gave was: sudo: unable to resolve host dk: Temporary ...
user avatar
0 votes
0 answers
24 views

Multiple host names on vServer

I'm using two nginx files - one for the vue frontend and one for the nginx backend (proxy_pass). The current spcecified host name in /etc/hosts which I'm using in the nginx vue config. Like: ...
user avatar
  • 111
1 vote
0 answers
24 views

Why does default-string appear after hostname in etc/hosts?

Referencing: This question The author is asking how to change hostname when it includes the appendage ´default-string´, If root is required to change the file in the path etc/hosts should this be ...
user avatar
  • 69
0 votes
1 answer
96 views

I changed the hostname on Ubuntu 20.04 and now I am locked out

I changed hostname and it locked me out from VNC, putty or RDP.(timeout) Yet the server is running and can be accessed with IP address. Hostname cannot be resolved and cannot go back to change it ...
user avatar
-1 votes
2 answers
2k views

SSH hostname command on remote server shows hostname of local server

I run this SSH command from server1 on server2 : ssh server2 echo pasword | su - root -c "echo this is the `hostname`" I expected the result to be host name of server2 but instead I get ...
user avatar
  • 43
0 votes
1 answer
154 views

Recognising Ubuntu VM hostnames on my local network

I suspect this issue may have been answered somewhere already, so please feel free to patiently direct me there (also as I'm new to this community). However I have done A LOT of searching to resolve ...
user avatar
0 votes
1 answer
895 views

Static hostname not changing Ubuntu 20.04

I upgraded to 20.04 from 18.04. My hostname had an underscore (My_PC). Now, in my terminal, it says sudo: unable to resolve host MyPC: Name or service not known. I tried: hostnamectl set-hostname ...
user avatar
1 vote
0 answers
699 views

Blocking hostname and subdomains in hosts file

I have recently started using /etc/hosts to block distracting websites. For specific domains that works nicely, but is there any way to match a domain and all of its subdomains? So, this blocks ...
user avatar
  • 282
3 votes
1 answer
88 views

Why doesn't hosts file get changed after the change of hostname?

So today while installing Ubuntu 20.04 on my laptop I accidentally gave it the hostname of my desktop and then changed it. A few hours later I was losing my sanity because SSHing into my desktop PC by ...
user avatar
  • 31
0 votes
1 answer
171 views

Deja Dup Device Name Issue

My Linux desktop is 4 years old. I originally named it "foo", but 2ish years ago renamed it "bar". I turned on backups for the first time today using Deja Dup, and it used the old computer/hostname ...
user avatar
  • 285
1 vote
1 answer
926 views

Can't access by name when setting static IP

I'll do my best to provide as much information as possible, I'm still fairly new to linux, but I have Ubuntu Server 18.04.4 currently running my media server, and I'm trying to set a static IP. I ...
user avatar
1 vote
1 answer
858 views

$HOSTNAME returns empty in rc.local script

I'm executing some script on my server startup, using the rc.local file (as suggested on this SQ answer. The script sends an email to my address notifiying me that the server has started up. This is ...
user avatar
  • 11
0 votes
0 answers
63 views

showing error while starting ubuntu

I have facing some errors while starting ubuntu desktop. I can't starting ubuntu. See below screenshot: How to start my OS. Anyone please fix this issus?
user avatar
  • 163
0 votes
0 answers
3k views

ssh-copy-id testnode fails with ERROR: ssh: Could not resolve hostname testnode: Temporarily failure in name resolution

I am not able to mention the SSH Generated Key to my test node. This is the output I get whenever I run the command ssh-copy-id: aibak@aibak-Inspiron-3542:/$ ssh-copy-id testnode /usr/bin/ssh-copy-...
user avatar
  • 1
1 vote
1 answer
946 views

`hostname` result is different from "/etc/hostname" after upgrade

If I open a terminal windows in my graphical user interface, hostname command result is different from content of /etc/hostname: me@ZyXEL1:~$ hostname ZyXEL1 me@ZyXEL1:~$ cat /etc/hostname N4010 me@...
user avatar
  • 2,528
0 votes
0 answers
46 views

I want to change the command prompt

I edited hostname in /etc/hostname and in /etc/hosts; I want the command prompt to be 'new' instead of 'old'; now, what I have is old@new; is there any way to completely get rid of old? Hostname ...
user avatar
3 votes
1 answer
52 views

Removing certain file types that do not contain the hostname in the file name

I am doing a file deployment for multiple machines per site, so it is much easier for me to zip all the files once and deploy to every machine. However I would like to remove the config for all the ...
user avatar
1 vote
1 answer
3k views

UFW block by hostname

Been searching for a while now, but I still can't find a simple answer to my simple problem. I run an FTP server and for security reasons I want to allow access (port 21) only from thispartvaries....
user avatar
  • 11
4 votes
2 answers
242 views

Why does host name have 'child' in it

When I installed Ubuntu 18.04 into this computer I picked a username = 'test' and computer name = 'abc'. However it set my hostname to be abc-child. So on my terminal I see test@abc-child:~$ Why did ...
user avatar
  • 251
1 vote
1 answer
679 views

Ubuntu 18.10 and 19.04 - Hyphen in Hostname?

I have tried setting my hostname to d-myserver1 via editing the /etc/hostname file and via 'sudo hostnamectl set-hostname d-myserver1'. If I run hostnamectl, the hostname is reflected properly. If I ...
user avatar
  • 21
1 vote
1 answer
3k views

Can't ping Windows hostname

I can neither ping nor access Windows 7 Samba shares through the hostname. As recommended at (inter alia) can not ping by host name for some computers, I have edited /etc/nsswitch.conf to include ...
user avatar
  • 125
0 votes
1 answer
866 views

Hostname (localserver.local) not working with static IP with netplan

I want to use a local hostname to access the same local server via multiple VLAN's easily. It works very well when I set netplan to DCHP, and follow these steps: https://linuxconfig.org/how-to-change-...
user avatar
1 vote
1 answer
7k views

What is the option "host-name" for in /etc/dhcp/dhcpd.conf?

I setup my ubuntu as DHCP server and specified some fixed IP addresses for certain devices using the syntax: host client1 { hardware ethernet b8:27:eb:ce:02:83; fixed-address 192.168.1.1; ...
user avatar
1 vote
0 answers
627 views

Ubtuntu 18.04 Software "cannot resolve hostname"

Just installed Ubuntu 18.04 and Ubuntu Software gives me the following error: Unable to download updates from "extensions.gnome.org": [///source/shell-extensions/] failed to download https://...
user avatar
0 votes
1 answer
364 views

how to change xyz@abc where i need to change xyz when terminal starts [duplicate]

Every time I open my terminal, I see xyz@abc where I type my sudo commands.However, my concern is this xyz and I want to change it to the name of my choice. I am unaware of the technical term for this ...
user avatar
5 votes
1 answer
179 views

Numeric Prefix in Hostname

In the Ubuntu Server Installer, we are precluded from placing a number as the first character in a hostname. However, once installed, we can issue a hostname command to rename the server to have a ...
user avatar
1 vote
1 answer
186 views

How can I set hostname as chinese?

The hostname of machine is english , but our workmates need chinese,some of them couldn't recongnize english. So, how can i do it ??
user avatar
0 votes
1 answer
483 views

hostname and /etc/hosts

I intend to purchase a domain, say for instance muppets.org, for my web server and I would like to install Postfix on the same machine for sending transactional emails. Am I expected to set as ...
user avatar
  • 1,347
0 votes
1 answer
135 views

User Account credentials, and how to change Ubuntu-Budgie

I am running into a situation where I need to change the terminal 'user' in Ubuntu-Budgie, but I am not seeing how this can be accomplished yet, mainly because I am not sure of the 'name' I need to ...
user avatar
  • 95
1 vote
0 answers
859 views

Changing hostname (with hostnamectl) in chroot environment does not work (Iso customization) Ask

I can not change the hostname in the chroot environment (Ubuntu) I tried hostnamectl set-hostname but it says: Failed to create bus connection: Couldnt find file or folder Then I tried changing it ...
user avatar
  • 11

1
2 3 4 5 6