I have been successfully editing my hosts file in the containing folder for quite some time. I've never had to move it out of the "etc" folder to make changes. and before making a change, I usually copy and paste to the same folder with a diff name like "hosts_old" so I have last working as a backup. But as for copying and moving and pasting to get to edit it.. Not necessary at all.
Homegroup removed! How to get network sharing work with Windows 10 v1803.
Here is short description how I get my network sharing work with Windows 10 v1803.
(I haven't never use Homegroup so I start directly from step 2.)
- Only for those PC's which are still using Windows 10 v1709 or older:
Disconnect from non-existing Homegroup if you have used it.
2.1. All PC's: Check Network profile and Network discovery and Share settings
Sometimes this selection to change between Private and Public network profile is missing from Settings / Networks page. In that case profile must change by PowerShell. Right Click Windows Icon (Start button) and open PowerShell (Admin) and use following commands to get interface index number and change profile to Private (or Public):
Get-NetConnectionProfile
Set-NetConnectionProfile -InterfaceIndex <index number> -NetworkCategory Private
2.2. All PC's: Check Network Discovery and Share settings
- All PC's: Set Start type to Automatic and start following services that allow PC's to be visible on Network. (Reboot.)
Push Win Key and type "Services", locate these services.
- Function Discovery Provider Host
- Function Discovery Resource Publication
- SSDP Discovery
- UPnP Device Host
- Setting shares.
4.1. Check your current shares.
Open file explorer and type \localhost to address bar to see what shares are made in this computer.
4.2. Create new share (here I use folder "Test").
(Setting "Turn on sharing so anyone …" in Step 2.2. make share for folders in C:\Users automatic.)
Folder is now shared and Network share path is: \PCNAME\Test
4.3. Safe way to share folders.
Create user account to all users on your network to whom you want to give access to shared resources.
Use same user ID and password which they have on their own computers.
Right click "Test" and open Properties and select Security tab to see current settings.
Default security settings are shown in next picture.
Those settings allow access to shared folder(s) only for those users who have user ID on that computer.
4.4. Sharing folder "Test" to Everyone" (Very unsafe setting! Think carefully do you need to select this!)
If you want that everyone have access to that share then go to Security tab and:
- Click Edit
- On Permission dialog click Add.
- New dialog open and you can add "Everyone" to that list https://learn-attachment.microsoft.com/api/attachments/c1f22caa-ec01-4f49-8c76-01b18ed8061f?platform=QnA
- When back to Permissions dialog select which rights you want to give to "Everyone".
Now anyone on your home network should have access to shared folders without credentials or having user account on your computer.
- Now when click Network on File Explorer all your PC's should be visible in Computer and Network sections.
This should be cover the essentials to sharing your data over local network. This share is not limited to C:\Users folder, every folder can be handled like shown in steps 4.
Now your PC's should visible, but if not then try to reset all network settings:
Go to Settings / Network & Internet / Status, scroll down to find "Network reset, on next window click "Reset Now" button.
It will takes about 5 min to perform this reset and then PC reboot automatic.
When you sing in first time you get notification something like "Do you want your PC to be access by other computers", click Yes for that.
If you get error message "Windows cannot access \PC_NAME" when you try to connect shared folders then continue to step 6.
- There is some bug on Windows 10 1803 and because of that PC's can't always connect to each other by Name.
If you get error "\PCNAME path not found" you can solve this by adding your PC's and IP-addresses to hosts file.
6.1 New routers (or modems) may have feature to remember which IP-addresses are assign to each device, but with older routers (or modems) you have to check that your router or modem is set give predefined IP-addresses linked to each PC's MAC-address.
This way PC's will get same IP-address every time when it ask IP-address form router (or modem) DHCP-server.
There should be some kind of list of PC names with MAC addresses and given IP-addresses of each connected PC.
Picture show that list on my router. In my case with old router I had to select manual assignment in each line.
6.2. Add all PC's IP-addresses and Names to hosts file (C:\Windows\System32\drivers\etc\hosts).
You can check your IP-address and PC's name by opening command prompt (CMD)
For IP-address type command: ipconfig you get line like this: IPv4 Address ………. 192.168.100.101
For PC name type command: hostname
Write down IP-address and Name of each PC and add those to that hosts file.
To edit copy hosts file to some another location, right click it and use notepad to edit and save it. Replace original file with edited file. Because hosts file is located on system folder replace will ask administrators rights to perform it.
localhost name resolution is handled within DNS itself.
# 127.0.0.1 localhost
# ::1 localhost
192.168.100.101 PC1 # Ethernet
192.168.100.102 PC2 # Ethernet
192.168.100.202 PC2 # Wi-Fi
Windows for home | Windows 10 | Files, folders, and storage
Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.
326 answers
Sort by: Newest
-
Anonymous
2018-12-18T17:56:51+00:00 -
Anonymous
2018-12-18T13:20:32+00:00 My apologies as I obviously missed that small, but important step in my mounted frustration to get this resolved. Everything else I followed and just finished updating the hosts file, rebooted both computers and am now able to see each computer from the other and access files as desired.
I appreciate all of your help and again apologize for causing you to have to repost information I should have noted the first time.
Michael
-
Anonymous
2018-12-18T05:40:01+00:00 "You don't have permission to save in this location. Contact the administrator to obtain permission."
Didn't you follow my instructions? You can't edit it directly in protected system folder.
Here is my original instructions.
"To edit copy hosts file to some another location, right click it and use notepad to edit and save it. Replace original file with edited file. Because hosts file is located on system folder replace will ask administrators rights to perform it."
Create one hosts file containing all PC's on your network and copy that to all of those PC's. If you wife don't have user ID on your PC then she can have access only C:\Users\Public by default.
You have to create user ID for your wife to your computer. Use same User ID and password she have on her own PC. When you create share(s) add her User ID to permissinon list of those folder(s) she need to get access from her own PC.
-
Anonymous
2018-12-18T02:28:09+00:00 Do it in safe mode, run msconfig and then change boot to safe mode. Change back to normal boot after changing the hosts file.
-
Anonymous
2018-12-18T01:53:10+00:00 My hosts file will not allow me access despite running as an administrator. I get the message "You don't have permission to save in this location. Contact the administrator to obtain permission."
I've done everything I can Google to give myself permission, but nothing works; I still get the same message. Any help on this issue would be appreciated as well.
Michael