Host De Windows

0 views
Skip to first unread message

Billie Kjergaard

unread,
Aug 4, 2024, 9:14:40 PM8/4/24
to lailausnowin
Occasionallyyou may need to edit the hosts file on your machine. Your host file might have been edited maliciously in an attack, or as a prank. Alternatively, you may just want to control access to certain websites or control network traffic.

The hosts file was used to resolve host names for decades before the DNS system was implemented, since way back in the ARPANET days. Since they were used to aide in network name resolution, hosts files grew to become massive documents.


Microsoft, Apple, and other operating system developers have kept the hosts file around, which is why it varies very little between Windows, macOS, and Linux. The syntax stays mostly the same across all platforms. Most hosts files will have several entries for loopback. We can use that for the basic example for the typical syntax.


The first part will be the location to redirect the address to, the second part will be the address that you will want to redirect, and the third part is the comment. They can be separated by a space, but for ease of reading are typically separated by one or two tabs, or the equivalent amount of spaces. The general format is:


Make sure to change the select to "All Files (*.*)" rather than "Text Documents (*.txt)." The hosts file doesn't have a file extension, so it won't show up if you're only displaying text documents. After you change that setting, locate the "hosts" fileand click open.


We also were not able to get to it in Google Chrome... (check notes at the end). Also for more info on editing your Hosts file, check out The Geek's article on how to create a shortcut to quickly edit your Hosts file.


In Ubuntu (and most Linux distributions) you can edit the hosts file directly in the Terminal. You can use your favorite command-line editor or your favorite GUI text editor. For this example we will use Vim, since it is one of the traditional text editors in Linux. Ubuntu's hosts file location is the /etc/ folder. The hosts file is protected, much like in Windows, and your regular user account will not be able to edit it.


All of the major modern browsers offer DNS Over HTTPS (DOH). DOH encrypts your DNS requests so that they can't be intercepted and read by third parties that might be snooping --- in general, this is a great thing.


For our purposes here, it limits the utility of the hosts file. The hosts file can only be used to block internet traffic if your browser is deferring to the DNS Server specified in the Windows operating system. A lot of browsers will enable DNS Over HTTPS automatically and use their own DNS servers. That results in the browser completely bypassing the hosts file. It is possible to force your browser to use the DNS Server Windows specifies, but you'll have to dig through your browser's settings.


This should get you started in understanding the Hosts file and how it can help protect your computer. Under the right circumstances, you can use it to block sites that you don't want a PC to be able to access.


This brings me to my question: is it possible to setup a local server (I already have two local Hyper-V host servers) that can download and serve all these updates to my LAN PC's, so that the LAN PC's can use it, and it can download all these updates once instead of each LAN PC downloading it's own set of updates?


In terms of serving updates locally and managing which updates are downloaded and made available, then WSUS is the answer you're looking for. The restriction is that WSUS itself only serves content to those machines which request it, it doesn't control which machines on the network do so. Put another way, you GET updates from WSUS, not the other way round.


Outside of AD your options are to configure it on each individual machine using either local group policy, or via the registry. Details of the settings and both methods are available here - -gb/help/328010/how-to-configure-automatic-updates-by-using-group-policy-or-registry-s - but crucially you will need admin permissions to set them up, which may be an issue if they're already domain joined to a work network.


I don't think there's any easy way to block any guest machines on your network from connecting to Windows Update, or force them to connect to your WSUS server without changing the configuration on them. The IP addresses used for Windows Update are hard coded into Windows, so you can't just redirect requests for certain addresses to another IP. From what I remember it doesn't even use any special port numbers to connect, so without blocking guests from accessing the internet entirely from your connection, or only allowing specific connections to be made, you can't stop their machines from connecting to Windows Update.


The only real option I can think of to control guests usage would be to setup QAS and bandwidth limits on your connection, and then restrict their download speed. That way allowing them enough bandwidth to have basic access, but without being able to use it all to get updates.


I have tried following the instructions in the Designate an Alternative Host page =zm_kb&sysparm_article=KB0067027 but there is no option for adding an alternative host at the bottom of the (old version) Advanced Options or (new version) More Options > Advanced, it just ends with the option for specific country restrictions.


@roymeo - Can you please screenshot what you see when you open the advanced options link? (I am on the latest version, 6.1.1, and it still shows advanced options). If you can see it on the other applications, it should still be there on the windows app (as I verified on my machine).


And that's all, the (NEW) Try new version ( o) (blue, it's selected) is below that with [Cancel] [Save] buttons on the line below that. No amount of scrolling, page downing, tabbing, or resizing the window to full screen reveals the Alternative Host selection dialog the KB0067027 says should be there & the web interface has.


My suggestion would be to click on the question mark with a circle in the upper right corner of your Zoom app and select report a problem since I cannot replicate your issue, but assuming you have a license, you definitely should be seeing the Alternative Host option.


This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.


This question is more suited to Super User, but the command you're looking for is nslookup. Both are (at their most basic) used to look up IP addresses for hostnames. You can run cmd and do nslookup hostname the same way you'd do host hostname. If you need something other than the IP address, the command-line arguments will differ. Run nslookup with no arguments and type help at the prompt for details.


Use the command "Nslookup" followed by your business domain to look up its server's IP address. If the server has multiple IP addresses associated with the name, the command will list all of them. As an example, you might enter "nslookup google.com" to find a list of Google's IP addresses.


for me it solved the problem (it was set on Disabled), I had some machines working some not, so i checked settings in working ones they had bidirectional clipboard. Dont know if this was upgrade issue or... just double check your shared clipboard options.


Start your VM then install Virtualbox Guest Addition

You can find this option under "Devices" on virtual box 4.2 or you can follow the explanations at How do I install Guest Additions in a VirtualBox VM?


Start the Ubuntu instance, then in the VirtualBox menu at the top of the running instance window, Machine > Settings..., Advanced tab, change Clipboard Sharing to Bidirectional. It's set to Disabled by default for some reason - not clear on why I'd ever want that.


I marked some text from firefox and tried to paste it into a terminal and it didn't work. I had guest additions installed, and also enabled bidirectional copy and paste and it still didn't work, but now I found the reason.


Apparently when I marked the text in firefox, additional information is also stored like the font and style. The terminal can not interpret this, so it doesn't seem to accept it. I pasted the text into a plain text editor (notepad++ in my case) then selected the text again and copied it. Now when I pasted it into the terminal it worked.


You can do that by going to Devices > Shared Folders > Shared Folder Settings in the alt menu on the VM window. After you set up a folder in the host, you can access it inside the VM in My Network Places:


In my personal experience, this actually seemed to be rather random. Sometimes the VM would be able to boot back up, sometimes not. I found that it was not actually the shut down of the VM, but if the host machine enters a sleep state, while the VM was shut down, after having run at least once.


The root issue I suspect has less to do with how Linux is treating the GPU, but the behaviour of the Windows OS while it is a guest. Mainly the Windows guest OS is not sending a signal to the GPU to shut-down or start up while it is running in a VM. I assume this is because when on bare-metal, when a Windows OS shuts down, power is actually killed to the GPU from the motherboard/PSU but when in a guest VM, this does not happen, leaving the GPU in an initialized state. Then if/when the host machine enters a low power state, and power is significantly reduced to the GPU, it enters a non-responsive state after the host machine wakes up.


Now create the second bat file. I called this one disablegpu.bat and saved it in the same location as the first one. It is exactly the same as the first bat file but it disables the GPU instead of enabling it.


Then, navigate to Local Computer Policy > Computer Configuration > Windows Settings > Scripts (Startup/Shutdown) and select Startup. Click the Add button and select your enablegpu.bat script. Repeat this process for your disablegpu.bat script via the Shutdown item in the Scripts (Startup/Shutdown) section.

3a8082e126
Reply all
Reply to author
Forward
0 new messages