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

Questions tagged [hosts]

/etc/hosts is the configuration file with locally known mappings between domain name and ip address.

Filter by
Sorted by
Tagged with
0 votes
1 answer
32 views

force mysqld to use etc hosts for reverse lookup

I have a server hosted by hetzner running mysqld. I already setup some "ddns for poor ones" to add my dial-on IP (Telekom) to the server's /etc/hosts. Now all Users in mysql are limited to ...
user avatar
0 votes
1 answer
16 views

sendmail and pacemaker require different /etc/hosts

Trying to make run sendmail (required by fail2ban, or it takes forever to start-stop-restart it) and pacemaker on one machine. Sendmail wants machine's hostname resolved as 127.0.0.1, pacemaker - as ...
user avatar
0 votes
0 answers
32 views

How to use hostnames in smtp_bind_address in Postfix configuration?

It seems that Postfix does not allow hostnames in the smtp_bind_address config parameter. But it does allow hostnames in inet_interfaces. For SPF I want to make sure which address SMTP-clients bind to ...
user avatar
0 votes
0 answers
161 views

nginx reverse proxy not serving local domain correctly

I want to resolve a few domain names locally in my computer. To do this I added in /etc/hosts the following line: 127.0.0.1 example.com Then I configured nginx with the following config file example....
user avatar
  • 127
0 votes
1 answer
31 views

Why the IP cannot be used directly when the IP mapped to the host name as a host entry works?

I was given an API for a service through which I tried to send a post message from server A, but the connection cannot be built. Then I ping the domain name in the API. It doesn't work, so I thought ...
user avatar
0 votes
1 answer
653 views

Why are my HOSTS file changes not taking effect in Windows 10? [closed]

I made a change to my hosts file on my Windows 10 machine today, however after saving the changes in Notepad (running as admin) the changes do not appear to work. For example I would expect this entry:...
user avatar
  • 87
0 votes
1 answer
80 views

How to give alternate name to localhost for sharing on windows?

I have a jenkins production job which involves multiple nodes/slaves and when we run the job it utilizes them based on the slave mentioned. And also, it has access to some machines shared folders.So ...
user avatar
  • 339
1 vote
1 answer
296 views

How does linux resolve wildcard locahost subdomains (e.g. : `ping test.localhost`) when `test.localhost` does not exist in /etc/hosts or dns server?

For example in ubuntu 20.04 LTS where the /etc/hosts file is empty: >>> cat /etc/hosts 127.0.0.1 localhost ping still works for any subdomain of localhost: >>> ping test....
user avatar
  • 1,497
0 votes
0 answers
75 views

Configure Single OpenLDAP server to manage a Centos 8 domain with multiple hosts

This is my planned org chart to be configured in my single OpenLDAP server. I tried to find some help on google search, but not find any close help. Basic requirement to fulfil this situation; single ...
user avatar
  • 101
0 votes
1 answer
104 views

How does a node differentiate between an IPv4 and IPv6 datagram? [closed]

In a computer network, how do hosts and routers tell if a datagram is IPv4 or IPv6? Do they just look at the version number field of the packet header?
user avatar
0 votes
2 answers
164 views

Is there a way to have a PC to resolve IP for a local server while on the LAN/VPN but an external IP when not?

I have a Nextcloud server on my LAN (with an external port forward for outside access) that I am setting up WebDav connections on for a collection of Windows 10 PCs and I want the users to make their ...
user avatar
  • 101
1 vote
2 answers
472 views

How do I serve a localhost projects on a made up domain, such as mysite.test and testing.test simultaneously?

If this is possible it would save a lot of headaches. I would like to bind made up domains to localhost projects, if that is possible. I am on Ubuntu 20.10.
user avatar
  • 21
0 votes
1 answer
172 views

curl prioritize the IP provided to resolve arg (or another) over other DNS options

When attempting to use curl to get around a misconfigured DNS entry (experimenting and not known at the time), --resolve seemed like the right way to go. However, the argument didn't behave the way I ...
user avatar
  • 185
0 votes
1 answer
77 views

Which service/process fills the default value of /etc/hosts?

I'm running a custom OS based on ubuntu 18.04. I've ran into a problem - when the machine gets installed it sometimes doesn't have the value "127.0.1.1 hostname" in /etc/hosts. So it can't ...
user avatar
0 votes
1 answer
213 views

Exclude subdirectory from host resolution set in /etc/hosts (with dnsmasq, or anything else)

I have a local development tool (LocalWP) that sets the path to my local environment by modifying /etc/hosts. For example, if I set my site in Local to www.foo.com, it'll append the following to the ...
user avatar
  • 127
0 votes
1 answer
269 views

Refresh host a records for a server when changed in domain controller

In Active Directory DNS Manager, when I change the IP Address of a Host A record, how can I ensure the changes are replicated to all or specific computers in the domain. When I change the IP Address ...
user avatar
  • 101
17 votes
1 answer
8k views

How to manually trigger an update of /etc/hosts in WSL? [closed]

When I start the first WSL terminal (ubuntu 20.04 bash in my case), WSL generates the /etc/hosts file based on the host file of my windows system %WINDIR%\System32\drivers\etc\hosts. If I now change ...
user avatar
2 votes
2 answers
4k views

Wireguard VPN connection not resolving local host names

I have setup a Wireguard VPN on my raspberry pi and I can connect to it via client app on my mobile phone. I can access the internet though the phone and I confirm that the phone is using the same IP ...
user avatar
  • 131
0 votes
1 answer
71 views

If an SSL certificate's name must match the name entered into the browser, what do you do with SSH Local Port Forwarding?

If the SSL certificate must match the name entered into the browser; what if the name entered into the browser is https://localhost:8080, in the case of accessing a server that is behind an SSH ...
user avatar
  • 4,767
0 votes
2 answers
1k views

Ansible: How to Remove /etc/hosts entries on the remote server using Ansible playbook. I need only the default entries to be present [closed]

How to Remove /etc/hosts entries on the remote server using Ansible playbook. I need only the default entries to be present. I need only below entries to be present: 127.0.0.1 localhost localhost....
user avatar
0 votes
2 answers
190 views

what IP should be used in hosts when setting up the mail server?

I'm setting up a mail server on my debian by following the tecmint tutorial. In step 4 the ip should be added in the hosts file. # hostnamectl set-hostname mail.mydomain.com # echo "192.168.0.102 ...
user avatar
  • 101
0 votes
1 answer
720 views

How to avoid HSTS error by hosts redirect with self-signed certificate? [closed]

I created this records in windows hosts file 127.0.0.1 a.domain.name 127.0.0.1 b.domain.name 127.0.0.1 c.domain.name where 127.0.0.1 - ip of my server [a,b,c].domain.name - domains wich from i ...
user avatar
0 votes
2 answers
1k views

Can cloudflare cause /etc/hosts entries to be ignored? [closed]

I've frequently used /etc/hosts to hop back and forth between servers for a domain and also to test if it's serving correctly before a deployment. However, in this latest case I've used cloudflare ...
user avatar
-1 votes
2 answers
3k views

Can one have 2 Domains pointing to the same IP and / or 2 IP's resolving to the same Domain?

I am going to attempt to rewrite the initial question so that it makes more sense. The issue I was being faced with is that I have my Company's website hosted on Site Ground but unfortunately ...
user avatar
2 votes
0 answers
1k views

docker-compose containers do not resolv hosts /etc/hosts entries

On my host machine (arch linux) I have a somewhat long list of entries in the /etc/hosts file resolving to remote machines (that are not under my control). The Docker containers of a development ...
user avatar
-2 votes
1 answer
439 views

Block URL with path in /etc/hosts? [closed]

I am working on OSX and I want to block access to an individual URL (a twitter profile) in /etc/hosts. Is this possible? I've tried adding: 127.0.0.1 twitter.com/mypath 127.0.0.1 www....
user avatar
  • 253
1 vote
2 answers
310 views

What to use for a hostname on a dedicated Linux server?

I've recently run into Debian wiki not recommending to set exim's primary_hostname explicitly. From what I can gather, here's the code that chooses primary_hostname. Basically, either I have FQDN in /...
user avatar
  • 1,715
-1 votes
1 answer
387 views

isc-dhcp host using files

I configured ise-dhcp-server, which works fine, but my dhcpd.conf is starting to become very big. I'm trying to find information (without results), on whether it's possible to use something like ...
user avatar
0 votes
1 answer
1k views

Why proxy server don't use the ip in client hosts file but do dns query?

A website changed DNS server,unable to get the correct ip with the normal dns query. So I have to write domain&ip to etc/hosts (macOS). I can only access this site faster if I use a proxy. Local ...
user avatar
2 votes
0 answers
93 views

Correct form of /etc/hosts

I've always thought that the correct format of /etc/hosts was 1.1.1.1 fully.qualified.name shortname alias We're upgrading our core software and some of the vendors utilities are failing as they ...
user avatar
-1 votes
1 answer
112 views

How do I setup Sendmail and the FQDN for use with server images

I have loadbalancer sitting infront of serveral webservers. The website served up has a contact form that uses sendmail. I have installed sendmail on one of these webservers: web-01 This is the ...
user avatar
0 votes
1 answer
1k views

Why does name resolution work for a .local adress without DNS?

Recently, I added a FreeNAS server to my local network. I can reach its web interface by opening freenas.local in a browser on my main Windows machine. However, when I do a nslookup freenas....
user avatar
3 votes
6 answers
3k views

Setting a custom /etc/hosts or resolver for one process only in Linux

On Linux, I want that a particular process should resolve host "xyz.com" to IP "10.1.2.3". That's easy: just add a line to /etc/hosts. However, I only want to do this for one process; I want all ...
user avatar
2 votes
2 answers
3k views

HOSTALIASES with Fully qualified domain names

I am trying to point a fully qualified domain name "example.com" to an external host such as Amazon ELB "site-xxxxxx.us-west-1.elb.amazonaws.com" using HOSTALIASES environment variable and it's not ...
user avatar
1 vote
1 answer
2k views

Can ping NAS by ip and hostname in Windows 10 console, but not find by ip or hostname in Windows explorer

I have set up a new PC with Windows 10. Now I want to access two local NAS drives but can't connect to them. With my old PC and all coworkers pcs everything is fine. There is no special access ...
user avatar
  • 11
0 votes
1 answer
95 views

Named multicast address

Is it possible to name a multicast or broadcast address? Usually for a single machine I'd put a line in /etc/hosts. Will that work for a multicast address?
user avatar
  • 165
1 vote
1 answer
555 views

DNS Resolution Sequence in Digital Ocean Droplets

I have setup multiple domains on my droplet and they cross-reference each other. Currently, when I do a nslookup for these domains from within the droplet, the DNS resolution is handled by 67.207.67.3 ...
user avatar
  • 13
9 votes
2 answers
23k views

Can host aliases be assigned to deployments in Kubernetes? If so, how?

This article describes how to assign host aliases to pods in kubernetes, is there anyway to do it for a deployment and not for a pod as such? Any other suggestions to add host entries in kubernetes ...
user avatar
  • 829
0 votes
1 answer
150 views

changed hostname - website no longer accessible

I run Centos 7 i was changing /etc/hostname "centos-512mb-blr1-01" to "srv1.domain.com" and rebooted for the changes to take place, since then all my websites are off.. i tried reversing the change.. ...
user avatar
1 vote
1 answer
224 views

Problems installing Ruby gem on Gandi VPS Debian 9 server

I have a Gandi Debian 9 server that I use for web page hosting. I am trying to install a Ruby gem on the system but it looks like I am either being blocked from installing gems or I need to setup my ...
user avatar
0 votes
0 answers
49 views

local IP redirects to public

I have a website on ubuntu vps.I can access my website through my public valid IP (185.211.88.62) but when computers on local network are not connected to internet and want use local invalid IP (172....
user avatar
  • 28
0 votes
2 answers
410 views

Fiddler-like host and port remapping using nginx on Linux

I am trying to set up host and port remapping on Linux using nginx as a reverse proxy. So far, I've got a working ghetto hack solution using the if directive, which is evil. Is there a better ...
user avatar
1 vote
0 answers
17 views

Solaris 10 app server operating on two company domains

I have a Solaris server hosting Apache and Tomcat web servers, it originally operated on one company domain: appname1.company1.com With a change in company, this original domain must still be ...
user avatar
  • 111
2 votes
5 answers
4k views

Add temporary entry to hosts, when tunnelling SSH

When outside our company firewall, I use a script to tunnel via SSH and expose our internal wiki to my OSX machine. Is there a command to temporarily tell OSX to resolve to my local port when the ...
user avatar
  • 2,610
1 vote
1 answer
436 views

How to give “Network Service” permissions on another non-domain computer?

I have PostgreSQL running on a Win10 Pro box (called DBServer) on my local network. I need to allow it to read files on my Dev computer (also Win10 Pro) on the same network so it can import files. ...
user avatar
0 votes
0 answers
209 views

Access Apache VHost Domain through OpenVPN

In my company, we're using OpenVPN to connect to our network for remote-working We have a local server that our employees can access (so through the VPN too), which contains a lot of local websites ...
user avatar
1 vote
1 answer
4k views

How to write my /etc/host to have MySQL access available from other machines from lan

EDIT: I am trying to Mysql from a remote Host: mysql -u root -p -h 192.168.56.147 But I have this message : ERROR 2003 (HY000): Can't connect to MySQL server on '192.168.56.147' (111) I have done ...
user avatar
  • 163
3 votes
1 answer
19k views

Is it possible to add a wildcard CNAME into dnsmasq?

I would like to let the DNS works in round robin way. So I have to put an entry into /etc/hosts. However, this does not allow wildcard domains. Is there any way that I can do this in dnsmasq? So I ...
user avatar
  • 163
0 votes
1 answer
615 views

LXC container ignores etc/hosts

I'm trying to map a hostname to a ip address on a lxc container because the hostname will not be resolvable by DNS. The lxc.conf of the container contains lxc.mount.entry = /sas/mycontainer/etc/hosts ...
user avatar
  • 31
0 votes
1 answer
75 views

Redirect website login to different IDP

My organization has a Shibboleth/IDP service set up. Now that I am getting involved, I am first setting up my own basic IDP on a test server to learn the ropes. In order to test functionality, I want ...
user avatar

1
2 3 4 5 6