You are not logged in.

#1 2015-05-18 17:53:42

Hectrin2
Member
Registered: 2015-01-26
Posts: 9

Deleted my hosts file. Need a replacement!

So I deleted my hosts file.like an idiot and I need to replace it. Is there any way to regenerate it or does anyone have a link to a default hosts file?

Any help would be appreciated!

Offline

#2 2015-05-18 17:58:57

Malkymder
Member
Registered: 2015-05-13
Posts: 258

Re: Deleted my hosts file. Need a replacement!

#
# /etc/hosts: static lookup table for host names
#

#<ip-address>	<hostname.domain.org>	<hostname>
127.0.0.1	localhost.localdomain	localhost
::1		localhost.localdomain	localhost

Last edited by Malkymder (2015-05-18 17:59:23)

Offline

#3 2015-05-18 17:59:23

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 4,092
Website

Re: Deleted my hosts file. Need a replacement!

You can find it in the "filesystem" package.

The package is already on your computer in the pacman cache, and Arch Linux packages are simply compressed ".tar.xz" files.

Offline

#4 2015-05-18 18:03:12

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: Deleted my hosts file. Need a replacement!

Malkymder wrote:
#
# /etc/hosts: static lookup table for host names
#

#<ip-address>	<hostname.domain.org>	<hostname>
127.0.0.1	localhost.localdomain	localhost
::1		localhost.localdomain	localhost

You need to add the host name to that:
https://wiki.archlinux.org/index.php/Be … e#Hostname

Delays in starting up certain packages (eg, Firefox) have been reported otherwise.

Offline

#5 2015-05-18 18:21:23

Hectrin2
Member
Registered: 2015-01-26
Posts: 9

Re: Deleted my hosts file. Need a replacement!

drcouzelis wrote:

You can find it in the "filesystem" package.

The package is already on your computer in the pacman cache, and Arch Linux packages are simply compressed ".tar.xz" files.

Yup, that did it. For some reason I didn't have that package in the pacman cache so I had to

 pacman -Sw filesystem

and untar it from there. Thanks!

Offline

#6 2015-05-18 18:33:52

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Deleted my hosts file. Need a replacement!

Find out why you don't have it in your cache. Caching packages is useful.

Please remember to mark the thread as solved https://bbs.archlinux.org/viewtopic.php?id=130309

Offline

Board footer

Powered by FluxBB