Questions tagged [hosts]

host is any machine or computer connected to a network and can offer information, resources, services and applications to users or other nodes in the network.

Filter by
Sorted by
Tagged with
3 votes
2 answers
2k views

If localhost is called 'localhost', why is the gateway not called 'gateway'? [closed]

If you run server services in your computer, it is very easy to configure the same computer to use it: just point the client to localhost. Now the gateway often runs your DHCP, DNS, proxy, firewall, ...
William C's user avatar
  • 2,479
13 votes
1 answer
45k views

How to change IP address to point to localhost?

A sandbox enviroment of a web app is reachable directly by an IP address: http://<my_ip_address> without a login name. Is there a way to make a virtual host in my local machine, named as <...
Michele's user avatar
  • 253
3 votes
1 answer
4k views

Are asterisks in /etc/hosts supposed to have any effect?

I have something like this in /etc/hosts: 192.168.0.1 example.com 192.168.0.1 *.example.com example.com is pinged to 192.168.0.1 as expected but pinging say sub.example.com outputs: unknown host ...
Desmond Hume's user avatar
  • 2,590
0 votes
1 answer
1k views

Mac OSX localhost does not resolve

Trying to access localhost no longer works on my new Macbook air. It used to work just fine on my old Macbook Pro which was also running Mountain Lion. I have tried most suggestions found in other ...
Amit's user avatar
  • 101
6 votes
2 answers
25k views

How to block IP Address via Windows Host

I want to block access to a certain ip address via windows host. This is the ip address 41.190.8.17. And this is the content of my host file. # localhost name resolution is handle within DNS itself....
Mob's user avatar
  • 407
-2 votes
2 answers
296 views

Virtual machine and virus on Host [closed]

The answer should be obvious but I ask anyway. If the host is virus infected with a keylogger and you do sensitive stuff on a virtual linux client, that information is being logged by the keylogger. ...
Petere's user avatar
  • 1
0 votes
1 answer
119 views

find out which program edited my hosts file

I have this line in my hosts file: x.x.x.x www.google.com For many times, I saw this line missing from my hosts file while everything else in it stayed untouched. in this case I would add this line ...
SparedWhisle's user avatar
  • 4,155
2 votes
2 answers
4k views

Cygwin netcat nc doesn't resolve hosts through /etc/hosts

I'm trying to use ssh to log into remote servers, and I have a ProxyCommand setup in ~/.ssh/config to use a proxy (setup through PuTTY to connect to a VPN). The ProxyCommand uses nc to connect ...
Rusty Lemur's user avatar
2 votes
1 answer
181 views

Host file entries are ignored when accessing my University's WLAN

I set up my hosts file in Windows 7, so I can't access certain time-wasting sites. It works fine when I am back home, but as soon as I connect to my University's WLAN, I can still access all sites ...
TrashyMcTrash's user avatar
1 vote
0 answers
88 views

Trying to reconcile global ip address and Vhosts

I have been using my local machine as a web server for a while, and I have several websites set up locally on my machine, all with similar Vhost files like the one seen here /etc/apache2/sites-...
puk's user avatar
  • 717
0 votes
1 answer
3k views

Allow all websites for administrator account and block all websites (but a few) for limited accounts

At my work we have a PC which runs Windows XP and is used by all employees. This PC is mainly used for our company website: a trailer booking website. At the moment there is one account: an ...
Duco's user avatar
  • 221
4 votes
2 answers
12k views

Unblocking blocked site with hosts file

I have www.somesite.com blocked in my country. But I have another domain www.another.com that points to the same server and it's not blocked (Apache Virtual Host) and works fine. I put an entry in ...
Umair A.'s user avatar
  • 441
1 vote
1 answer
2k views

/etc/hosts deleted on restart

Since yesterday, my /etc/hosts file disappears "magically" on restart. When I recreate it via sudo vim hosts everything works, but it's gone once I restart. I'm on Mac OSX 10.6.8, running MAMP 1.9.4 (...
Christian Macht's user avatar
1 vote
0 answers
1k views

How to redirect a URL to a certain IP, as with /etc/hosts?

Someone on my shared server has messed with some setting such that gethostbyname('www.google.com') (PHP) gives me the IP for his website, rather than Google. I believe this can be done via the /etc/...
mpen's user avatar
  • 12.1k
1 vote
1 answer
152 views

Hosts not recognized?

Basically, nobody can establish a connection to anything I host. The website, teamspeak, and game servers. I think it may have something to do with the hosts file or network configuration, but I have ...
Ivan's user avatar
  • 13
4 votes
3 answers
1k views

Editing /etc/hosts on Mac OS X Lion to use shorter host for ssh-ing

I keep having to type out ssh [email protected] a lot. Instead of an alias, I just want to shorten that host name. I tried editing my hosts file to include shorthost ...
user1541477's user avatar
3 votes
2 answers
11k views

Access a local web server from a mobile phone? [closed]

I am developing a website and I'd like to look at it from my mobile phone (which is right next to the dev computer, on the same LAN). The development is on a dev computer with XAMPP. The local domain ...
camcam's user avatar
  • 589
-1 votes
1 answer
72 views

Can not access www.websaru.com

I am unable to access the website www.websaru.com. I'm in China, is the website blocked? I don't think so, because it is not a sensitive website. How can I access it? Please help.
Steven's user avatar
  • 147
6 votes
5 answers
5k views

Firefox not taking note of /etc/hosts?

I've set foo.com to 127.0.0.1 in my /etc/hosts file in (located here on Windows: C:\Windows\System32\drivers\etc\hosts). Though Chrome loads foo.com with the one hosted locally on port 80, Firefox ...
A T's user avatar
  • 791
2 votes
1 answer
617 views

Make IP Address point to webroot instead of virtual hosts' documentroot

I used to have a one-to-one domain name and IP. Recently I've paid for a second domain name and decided to host it on the same box and IP. As such, I added virtualhosts to point each domain name to a ...
Reuben L.'s user avatar
  • 1,052
13 votes
3 answers
22k views

How come hosts file redirection fails?

I am trying to redirect google.com to my local machine for fun and learning with this /etc/hosts file on my Mac. 127.0.0.1 www.google.com However, www.google.com still maps to the Google home page ...
David Faux's user avatar
  • 4,829
12 votes
2 answers
4k views

Is there a utility to ping a server using aliases in ssh config (instead of /etc/hosts)?

I'm trying to standardize my server aliases across projects by linking together ssh config files that I can keep under version control. I'd like to be able to just define machine aliases along with IP ...
Peter Groves's user avatar
2 votes
1 answer
3k views

MAMP PRO on Lion: why can't I see any changes in httpd-vhosts.conf?

After adding a local virtual host in MAMP PRO (os x lion) everything works as expected. Out of curiosity I had a look at httpd-vhosts.conf file placed in MAMP/conf/apache/extra and to my surprise this ...
JaneVi's user avatar
  • 91
3 votes
2 answers
6k views

how to get the name of current host?

This may be a pretty dump question! So how do I get the host name so that I can ssh into my machine (which is a Mac)? For instance : ssh myusername@<hostname> Is there any command to find out ...
One Two Three's user avatar
2 votes
1 answer
1k views

Weird Terminal error when opening TextEdit.app

I was trying to edit my host file with the command sudo /Applications/TextEdit.app/Contents/MacOS/TextEdit /etc/hosts I got the following error: Sending synchronize message <dictionary: ...
citruspi's user avatar
  • 160
0 votes
1 answer
72 views

Corrupted data from terminal to Host

Ive got a terminal which sends data to a host that is wrapped with <stx> and <etx>. However when it enters the network it always has 5/6 bytes of junk data in place of the <stx> and ...
Axle's user avatar
  • 7
1 vote
2 answers
2k views

How to use multiple localhosts

On my local development machine (Windows 7), I am using IIS and XAMPP to develop websites. Because it is unclear when I have multiple websits running, I am tried to rewrite the hosts file (C:\Windows\...
System.Data's user avatar
2 votes
1 answer
4k views

Redirect a url to another url

I need to redirect a url to another url. THe PC where this should be done has Linux but no server program such as Apache. When the user type www.mycomerp.com, it should redirect it to http://localhost:...
Noor's user avatar
  • 266
0 votes
1 answer
2k views

create intranet website on windows 7

I want to create a web site in my LAN, but instead of using my laptop or PC as the hostname of the web site, users should be able to use something like css.domain.com. I'm doing this because I want ...
undone's user avatar
  • 842
0 votes
5 answers
2k views

How can I create shorter URLs to sites on my computer?

I was wondering if I could use my Windows 7 hosts file to create shorter URLs for sites? OR is there another way. I tried ones like the following but I'm guessing it only works with IP Addresses? ...
davidmcd's user avatar
  • 339
0 votes
2 answers
4k views

DNS resolves without adding the host IP and name to etc/ hosts file

Is there any way to resolve a hostname without adding it to the hosts file? In order to access an internal site in my company, I have to add the hostname and IP in the .../etc/hosts file. Is there any ...
Mekko's user avatar
  • 1
2 votes
1 answer
3k views

how to properly edit hosts, hostname and resolf.conf?

I have been searching the Internet for a real nop tutorial on the subject but could not found any direct info. on how to edit these files the proper way. I have a Debian Internet server that I use to ...
Firewall's user avatar
4 votes
2 answers
1k views

Why do some applications run faster on a 32-bit guest VM than on the 64-bit host machine?

I have a Windows 7 x64 laptop with a Windows XP x32 guest virtual machine installed using VirtualBox. Once I ran an app on the guest and found that it ran noticeably faster than it did on the host. ...
user125900's user avatar
7 votes
3 answers
28k views

Custom host file for Firefox

Instead of changing my host file I'd like Firefox to think my domain is on my own server while my other browser uses the real IP address. I used to edit my host files but that forces both browsers to ...
user avatar
11 votes
2 answers
32k views

Can a router map a URL to a local ip?

I'm setting up a facility with many different computers where I don't have access to their hosts files. How would I map test.com to a local server without using the hosts file? Can this be done using ...
Sauce McBoss's user avatar
  • 2,155
2 votes
1 answer
721 views

How can I prevent users from circumventing the Windows hosts file?

I realized Windows hosts entries can easiliy be circumvented by just setting a system proxy or use a webproxy like hide my ass. How can prevent my kids from circumventing my hosts file that blocks ...
user670186's user avatar
7 votes
2 answers
9k views

Quickly edit / change hosts file on Windows

I routinely need to add / remove / update hosts on a Windows 7 machine to add links to staging / test servers. On Mac I can use ghosts with the syntax ghost add staging-server.local 67.207.136....
Tom's user avatar
  • 411
3 votes
2 answers
381 views

Windows - hosts file resets without my interference

I have a pretty long list of time-wasting sites in the hosts file and it is working just fine, however I'm experiencing a very strange behavior - every day or two (my PC turns on automatically every ...
Alec Mev's user avatar
  • 659
11 votes
3 answers
5k views

Mac OS X "hosts" file, can I include other files with it?

I am working on some automation scripts to configure my network settings, hosts file contents, and /etc/resolver files, when accessing different networks I frequent between. There are some ...
Lasse V. Karlsen's user avatar
4 votes
4 answers
34k views

Permissions for editing hosts file on Windows 7 Home Edition

I am running Windows 7 Home Edition on my laptop. I also have an instance of Apache Server running and am trying to create a virtual directory. I have updated apache's vhost-httpd file and now need ...
cdub's user avatar
  • 247
1 vote
1 answer
3k views

nsswitch.conf - cannot modify (read-only)

I am attempting to modify nsswitch.conf from: hosts: files dns to hosts: dns files But, it is read-only. I have tried using: sudo vi /etc/nsswitch.conf And even with :w! It is unable ...
Serodis's user avatar
  • 442
3 votes
2 answers
261 views

How can I use the computer name in this situation?

I have the following scenario: Windows 7 64-bit, hosting an XP Mode, on the host machine there is Oracle 10g installed. On the XP Mode there is Oracle Client installed. From XP Mode I am able to ...
karla's user avatar
  • 259
5 votes
2 answers
1k views

In your ssh config is it possible to have one host entry for multiple machines on the same domain

I'd like to be able to do something like Host * HostName *.mydomain.com ... So I can type something like ssh test ssh ci ssh dev Instead of having to type ssh test.mydomain.com ssh ci....
Joshua Olson's user avatar
1 vote
1 answer
217 views

Chrome cannot find the host entry for website

When I try to load a website, I get the following error in Chrome, Chrome could not find img.mzsites.com But on another computer, the site has no problems loading. I have tried ipconfig /flushdns, ...
Adam C.'s user avatar
  • 123
1 vote
1 answer
2k views

My facebook redirect to localhost

I am in strange condition right now. I am not able to access facebook. Once I open the facebook it just loads the localhost. I know we can set it from host file. But just have a look at my host ...
Avinash's user avatar
  • 111
0 votes
1 answer
1k views

hostname and hostname -s differ

My /etc/hostname has: name.domain.net Previously, it was: old.domain2.net If I do hostame I get name.domain.net. But doing hostname -s returns old. According to the man page: -s, --short ...
blueFast's user avatar
  • 2,706
4 votes
2 answers
7k views

Can I chown /etc/hosts so my user owns it so I can edit it without sudo?

It's a bit inconvenient to have to sudo emacs /etc/hosts whenever I want to make a change to my hosts file, especially since I don't use a Terminal-based editor primarily. Could I change the ownership ...
Weston Ruter's user avatar
0 votes
1 answer
730 views

hosts file ignored

This is very strange issue. I'm on Windows XP. I have tried to put 41.41.41.41 facebook.com 41.41.41.41 www.facebook.com into C:\WINDOWS\system32\drivers\etc/hosts. When I tried to save the file, ...
genesis's user avatar
  • 288
2 votes
3 answers
1k views

What unresolvable IP address should I use to block adverts?

I don't want to depend solely on in-browser ad blockers. I therefore created my own block list of advertisers' domains and pointed them all to a 0.0.0.0 IP address. I now started a project and need ...
Mikhail Kashkin's user avatar
0 votes
1 answer
122 views

How can I get other computers to see my new host name?

I recently set up my VM to have a machine name like this : sudo /bin/hostname jax sudo dhclient However, my host machine cannot ping "jax" ? I would assume this is all thats needed.... am i ...
jayunit100's user avatar

1
4 5
6
7 8