Geekzone: technology news, blogs, forums
Welcome Guest.
You haven't logged in yet. If you don't have an account you can register now.

43 posts


Topic # 242882 18-Nov-2018 23:42
Send private message

How things are now:


I have a PC which runs Windows 7 in a headless fashion with no monitor and keyboard, etc. At home when it starts it automatically joins the home Wifi network. I can then remote into this said headless PC from another computer (the "controlling PC") which is also on the same home Wifi network. I have the router assign a reserved IP address to this headless PC, so I know what IP address to use with Remote Desktop. This is all good.




What I want to achieve:


However, there are occasions I would like to use this headless PC outside the range of the home Wifi network. When this happens, both the headless PC and the controlling PC would not be able to connect to a Wifi network, and Remote Desktop obviously will not work.




What I have tried:


Now I have read about using netsh to create "virtual" access point. I have tried the following successfully:




On the headless PC, while it is still connected to the home Wifi network:


Run Cmd as administrator


Run netsh wlan set hostednetwork mode=allow "ssid=SSID" "key=KEY" keyUsage=persistent


Run netsh wlan start hostednetwork




On the controlling PC:


Connect to "SSID" network created by netsh


Find out what IP address itself got assigned (e.g. 192.168.173.xx)


Remote desktop into the headless PC using, changing 'xx' to '1'




My questions:


The steps in the above experiment are of little use to me, as they require me setting up the virtual AP with the headless PC connected to the home Wifi network.


Even if I am to put a startup script to run netsh automatically, if the headless PC is not connected to the home Wifi DHCP, how is it going to get an IP address?


And even if it manages to get an IP address, how do I find out what it is so I can put that into Remote Desktop?


Is there some way I can automate the above process? i.e. If the headless PC fails to connect to the home network, I am hoping it will automatically turn itself into a virtual AP and giving itself a pre-determined IP such that I can remote into it?  


I hope I have made my questions clear....Any help would be very much appreciated.



Create new topic
1902 posts

Uber Geek
+1 received by user: 488

Lifetime subscriber

  Reply # 2129091 19-Nov-2018 00:23
Send private message

Wouldn't it be easiest to stick with hardware devices and avoid the virtual/software device? Simply assume that the absence of a WiFi connection at the headless PC means that the hardware AP will have automatically started. It will be easier to find scripts/batch files to automate this where you are testing for only one IP address at a time.


  • On the headless PC check if WiFi is connected. If it isn't then start the AP.
  • On the controlling PC check for the headless PC on the WiFi network - it has a set IP address. If the device isn't there then try to connect to the AP which should also have aknown IP address because you configured it too.

There should be no time when you don't know the IP address of the headless PC. It is either connected to your WiFi network with a know IP address or is an AP with a known IP address.

43 posts


  Reply # 2129134 19-Nov-2018 09:14
Send private message

The reason why I wants the virtual solution is because the headless PC is occasionally being used in a portable manner. It is a lower power 12V PC running Atom processor. At home it runs on main but there are times I need to run it on 12v battery when I am in the middle of nowhere with no mains power (The controller PC is a laptop so has its own battery). I do not want to add more hardware which will increase power consumption when it is being used in the portable setting.

I know this can be done in Linux. I have a Raspberry Pi which can join the home wifi when at home but also creates its own wifi network which I can connect to when home wifi is not available. The controlling PC can address it using a host name (e.g http://rpi.local) whether it is on the home network or on the ad hoc network. I would like to duplicate that on my headless PC but I do not have the network know how to do so (the Raspberry Pi runs a prepackaged server image not set up by me).


21910 posts

Uber Geek
+1 received by user: 4603


  Reply # 2129272 19-Nov-2018 10:42
Send private message

Add a second USB wifi dongle, many of the realtek ones have software available to turn them into an accesspoint and then just enable internet connection sharing on that second adapter so it has DHCP and a constant IP address on it.


Create new topic

Donate via Givealittle

Twitter »

Follow us to receive Twitter updates when new discussions are posted in our forums:

Follow us to receive Twitter updates when news items and blogs are posted in our frontpage:

Follow us to receive Twitter updates when tech item prices are listed in our price comparison site:

News »

Amazon introduces new Kindle with adjustable front light
Posted 21-Mar-2019 20:14

A call from the companies providing internet access for the great majority of New Zealanders, to the companies with the greatest influence over social media content
Posted 19-Mar-2019 15:21

Two e-scooter companies selected for Wellington trial
Posted 15-Mar-2019 17:33

GeForce GTX 1660 available now
Posted 15-Mar-2019 08:47

Artificial Intelligence to double the rate of innovation in New Zealand by 2021
Posted 13-Mar-2019 14:47

LG demonstrates smart home concepts at LG InnoFest
Posted 13-Mar-2019 14:45

New Zealanders buying more expensive smartphones
Posted 11-Mar-2019 09:52

2degrees Offers Amazon Prime Video to Broadband Customers
Posted 8-Mar-2019 14:10

D-Link ANZ launches D-Fend AC2600 Wi-Fi Router Protected by McAfee
Posted 7-Mar-2019 11:09

Slingshot commissions celebrities to design new modems
Posted 5-Mar-2019 08:58

Symantec Annual Threat Report reveals more ambitious, destructive and stealthy attacks
Posted 28-Feb-2019 10:14

FUJIFILM launches high performing X-T30
Posted 28-Feb-2019 09:40

Netflix is killing content piracy says research
Posted 28-Feb-2019 09:33

Trend Micro finds shifting threats require kiwis to rethink security priorities
Posted 28-Feb-2019 09:27

Mainfreight uses Spark IoT Asset Tracking service
Posted 28-Feb-2019 09:25

Geekzone Live »

Try automatic live updates from Geekzone directly in your browser, without refreshing the page, with Geekzone Live now.

Support Geekzone »

Our community of supporters help make Geekzone possible. Click the button below to join them.

Support Geezone on PressPatron

Are you subscribed to our RSS feed? You can download the latest headlines and summaries from our stories directly to your computer or smartphone by using a feed reader.

Alternatively, you can receive a daily email with Geekzone updates.