Redigera hosts-filen på OS X

DNS-servrar håller reda på vilka domännamn som ska kopplas till vilket IP. Ibland kan man vilja överlagra dessa på sin egen maskin, t ex när man utvecklar en testsajt eller liknande.

Hur man gör för att ändra sin hosts-fil på Windows har vi skrivit om tidigare.

På OS X är förhavandet liknande i senare versioner av operativstemet, här är Apples guide.

Man måste ha rättigheter till rooten för att kunna se private-mappen filen ligger under. Vi har tidigare skrivit om hur man visar gömda filer på OS X.

När man väl har tillräckliga rättigheter navigerar man till mappen /private/etc/hosts och öppnar man den får upp något som liknar detta.

##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting.  Do not change this entry.
##
127.0.0.1	localhost

Man måste dock vara inloggad som root-användare för att spara ändringar, så det räcker inte bara att öppna den i en textredigerare och försöka spara. Här är två sätt man kan ändra den.

1. Ändra hosts genom att skriva över med kopia

Kopiera filen och lägg den på skrivbordet. Redigera spara. Dra den sen till /private/etc/hosts och släpp. Nu får du skriva in ditt lösenord för att bekräfta att du har rättigheter att modifiera filen.

2. Ändra hosts med textredigerare i Terminalen

Med detta sätt behöver du inte slå på att visa gömda filer som vi skrev inledningsvis om. Här använder vi en redigera som startas från terminalen. Finns en del men i detta exemplet använder vi en som heter GNU nano 2.0.1.

Öppna först teminalen.

Skriv: sudo pico /private/etc/hosts

Bekräfta ditt lösen för att få root-rättigheter.

Nu får du upp textredigeraren och du kan modifiera filinnehållet. Spara ändringar genom ctrl-o och stäng ner editorn med ctrl-x.

Comments

Tack för denna HowTo hjälpen. Super bra för oss som är ganska nya med Mac

High school biology classes need to be revamped to include human anatomy and other subjects which usually take up time in medical school. The same exams given in medical school should be administered at that level. There is no reason why so much educational time must be wasted in American schools. medical student guide

It is taking over the weight loss industry by storm and is becoming globally renowned as the wonder ingredient that aids in fat and weight loss. naturalweightloss

If your grocery budget is tight, you may need to adopt some new strategies for reducing your grocery bill. The overall key to saving money on groceries is planning.  shopingguru

Once your skills and experiences are identified you can then move on to identify the opportunities available to you. Jobs and career

g-shops.co.uk a portal of daily newspapers covering Philippine news headlines, business, lifestyle, advertisement, sports and entertainment.

Verdict good quality books to read in the stimulate store are a huge confront! Where do you start? And how can you get recommendations that are genuine, and relevant to you?

Verdict good quality books to read in the stimulate store are a huge confront! Where do you start? And how can you get recommendations that are genuine, and relevant to you? dissertations.superiorpapers

We all understand gambling is the new very popular past time. Land casinos get genuine engaged. occasionally it is very tough to find a table game or slot machine in your play-range - not so at dwelling. casino nz

Yet another issue is that video games usually are serious in nature with the principal focus on learning rather than entertainment. Although, we have an entertainment feature to keep the kids engaged, each and every game is often designed to develop a specific experience or curriculum, such as mathematics or scientific disciplines. Thanks for your article. their explanation

There are two primary means to adapt the hosts book in Mac OS X. The aboriginal is by application Text Edit, aback the hosts book is alone a simple apparent argument document. However, you can’t accessible the book directly, aback it resides in a adequate breadth of the book system. Instead, we charge to archetype the book to an caught location, like the Desktop, adapt it, and again archetype it back.

I lite närmare examcollection EX0-117 tidsperspektiv kan jag definitivt se många användningsområden för prediktiv analys. Man borde t ex kunna räkna ut när sannoliken är EX0-117 vce questions som störst för att en kund kommer gör en ny beställning. Och då skicka ut lite extra reklam och erbjudanden för att främja detta vce EX0-117

I like your acclimation and accumulated you allocation with us is acclimatized and complete informative, I address to bookmark the album rushessay.com so I can accepting adeptness from you that you accepting done a air-conditioned job. I accepting with you. This acclimation is absolutely inspiring.

Still these solutions are brilliant one, everyone must follow these procedures wisely to have a great termed knowledge

wordpress, joomla, drupal, vBulletin, Concrete 5, magento, opencart, WooCommerce, Prestashop Graphics,Vectors Template Desk

If your grocery budget is tight, you may need to adopt some new strategies for reducing your grocery bill.thanks http://www.onlinepromotionuae.ae

Thanks for sharing nice information.

hp printer helpline number

epson printer helpline number

thanks for provide a good information........ www.andamandiscover.com"> www.andamandiscover.comlink text

Nice blog.. Thank you for sharing..The best way to resolve all the issues of Dell Printers is calling Dell Printer Support Number UK. By calling our executives you will be able to seek assistance for all the issues of Dell Printers. Our executives are available at our help desk round the clock so that they can help you out any time you need support. If you need technical support for antivirus get in touch with Canon Printer Support Number UK, Epson Printer Support Number UK, HP Printer Help Number UK

HP Help Number UK

HP Support Number UK

HP Contact Number UK

HP Helpline Number UK

Great blog! I really love how it is easy on my eyes and the information are well written. We Provide for Hotmail user Technical Support Number UK more help touch here: Hotmail Support Number UK Hotmail Help Number UK Hotmail Contact Number UK

this is outstanding and great post! i really like it. thank you so much.

toshiba laptop support

Hii, Thanks for the sharing nice posting with us. i’m really impressed.

Windows Support Number

this is outstanding and great post! i really like it. thank you so much

Windows 10 Support

Today I learned a lot from your website. thank you Hp printer helpline number

Hii, Thanks for the sharing nice posting with us. i’m really impressed. toshiba support

Thanks for this awesome web page, i like it. Norton helpline number

we are offered new latest support for kaspersky support number.

we are offered new latest support for epson printer support number.

very very nice article, thanks for the sharing with us. Call@ 0800-098-8569 for Windows Support Number, Windows XP support, Windows 10 Support, Windows 8 help, Windows Phone Support, Windows Tech Support, Windows 7 Support.

Windows Customer Service

Very Very nice post. its a very useful and outstanding article. Thanks for that. hp helpline

Get free GTA 5 money online generator online free money generator these cheats for gta 5 cheats for ps3 and xbox can be used easily.with free RP using this online hack.

Very Very nice post. its a very useful and outstanding article. Thanks for that. epson helpline,

i loved this post and this is so awesome post so thanks to this article and if you want another support click on this link...hp printer service

this is outstanding and great post! i really like it. thank you so much.

Microsoft Support Number

i love this article and this is so awesome post so thank to this article.

Toshiba Customer Service

Hi.. I am really a great follower of this site. The Title what you have chosen for this series is great. Thank you for updating.

Lenovo tech support

Hi.. I am really a great follower of this site. The Title what you have chosen for this series is great. Thank you for updating.

Norton helpline number

Hi.. I am really a great follower of this site. The Title what you have chosen for this series is great. Thank you for updating.

Toshiba helpline

Hii, Thanks for the sharing nice posting with us. i’m really impressed.

norton support phone number uk Norton customer care UK

Hii, Thanks for the sharing nice posting with us. i’m really impressed.

Microsoft Windows Support

very very nice article, now Take a look at my page apple Laptop support

this is outstanding and great post! i really like it. thank you so much.

Canon Help

Very nice articles. This is very useful especially for me. Thanks for sharing articles with us.

network solution contact

Thanks for taking the time to discuss this...

You have a wonderful site with lots of useful data in it...

Canon Printer Helpline Number UK

Hi, Thanks for the sharing nice posting with us. i’m really impressed.

Awsome posting and topic is very nice . Good posting.

Awsome posting and topic is very nice . Good posting.

Hi, Thanks for the sharing nice posting with us. i’m really impressed.

windows support phone number

windows customer service

this is a awesome post, thank you.

Avg Antivirus Technical Support

hii superb post, thank you.

Norton Support Number

hii very useful post, thank you.

Kaspersky Support Number

hii this is a superb post, thank you.

Epson Support

Also you may require services for a laptop or printer

yahoo mail contact

Nice Blog and Great article…its always working for me well…Keep going !Lenovo Laptop Customer Support

Thanks for giving important information to training seekers,Keep posting useful information. Lenovo Laptop Customer Support

Thanks for sharing this blog its very informative and useful for us. Escorts in greater kailash

Very impressive post. Good work. call at 0808-238-7544 Adobe Contact Number UK for online live chat support.

http://www.hermeshandbags1837.com/hermes-evelyn-pm-green-with-silver-hardware-p-210.html Tod's Gommino Leather Black Driving Shoes For Women Sale http://www.1todsstore.com/tods-gommino-leather-black-driving-shoes-for-women-sale-todsi797-p-797.html"> http://www.1todsstore.com/tods-gommino-leather-black-driving-shoes-for-women-sale-todsi797-p-797.html

Thank you for your post, I look for such article along time. myself very happy to read it because it can give me more insight, thanks. http://www.callgirlsnumbers.in/locations/delhi"> http://www.callgirlsnumbers.in/locations/delhi

Please fill out all the fields.

*
*