NEED HELP about Command Terminal sudo nano /private/etc/hosts

Discussion in 'Mac / Hackintosh' started by beaucarty, Aug 30, 2017.

  1. beaucarty

    beaucarty Newbie

    Joined:
    Oct 19, 2011
    Messages:
    100
    Likes Received:
    0
    Location:
    Paris - France
    I don't understand how to write this command/
    1.Install the software.
    2.Run Terminal.
    Input the command.
    $ sudo nano /private/etc/hosts (I press enter or not?))
    Add the line ( what does it mean just write the following text with space or without space,...on the same line or under ??)
    127.0.0.1 www.swamengine.com.
    Save & Exit.( write this text or use a fonction in Terminal to save and exit ??)
    Input the command. ( I open Terminal at new write the text and and press enter ?)
    $ dscacheutil -flushcache
    Hosts patch is done!

    Thanx to help me I don't know how to use Terminal :disco:... maybe some tutto ?
     
  2.  
  3. tzzsmk

    tzzsmk Audiosexual

    Joined:
    Sep 13, 2016
    Messages:
    3,249
    Likes Received:
    1,989
    Location:
    Heart of Europe
    just use Little Snitch and block connections using it :)
     
  4. beaucarty

    beaucarty Newbie

    Joined:
    Oct 19, 2011
    Messages:
    100
    Likes Received:
    0
    Location:
    Paris - France
    Do you mean I don't need to do the patch on terminal ? Just use the keygen ?
     
  5. SineWave

    SineWave Audiosexual

    Joined:
    Sep 4, 2011
    Messages:
    4,320
    Likes Received:
    3,418
    Location:
    Where the sun doesn't shine.
    Let me explain a bit what you're doing here, to make it easier for you...

    sudo - command that says "I'm an administrator". it is necessary to use it when messing with system files.
    nano - command to start "nano" text editor.
    /private/etc/hosts is the path to the "hosts" file.

    Commands in a terminal are entered as a sequence of commands [with a space between commands] and executed by pressing "enter". So you are using an administrator command to start the "nano" text editor to edit the "hosts" file.

    Putting "127.0.0.1 www.swamengine.com" in the host file and saving it with "ctrl+o", then exiting nano or just closing the terminal, means you want to block this website by routing it to a local address, which is a common practice for blocking the OS from being able to reach a certain internet address.

    easy-peasy, eh? :)

    Cheers! :wink:
     
    Last edited: Aug 30, 2017
  6. beaucarty

    beaucarty Newbie

    Joined:
    Oct 19, 2011
    Messages:
    100
    Likes Received:
    0
    Location:
    Paris - France
    Wow ! Got it! Now it's clear Thanx
     
Loading...
Loading...