
Script to find & disable 2nd active net adapter |
Post Reply
|
| Author | |
simanta
I'm new here
Joined: 27 Jun 2009 Online Status: Offline Posts: 2 |
Quote Reply
Topic: Script to find & disable 2nd active net adapterPosted: 27 Jun 2009 at 11:24 |
|
< ="-" ="text/; =utf-8">< name="ProgId" ="Word.">< name="Generator" ="Microsoft Word 12">< name="Originator" ="Microsoft Word 12"><>
hi, In my company I have to manage a network which comprises both wired and wireless network. Recently I have observed that despite of our repetitive instruction, some of my user connect his/her PC's both the network adapter (wired/wireless)to the company network. This creates problem in my network traffic as well as in the DNS server. Now I am looking for a script which will run with the login script and it will look for the active network adapters in the users PC. Now when it detect both the adapter active, it will give a message and disable one adapter randomly. I am not an expert in Kixtart sripting and don't have idea how to do this. This will be a great help for me if anybody provide me such a script or idea how to do so. Thanks in advance to all who help in this. |
|
![]() |
|
jvierra
MVP
Joined: 31 Aug 2006 Location: United States Online Status: Offline Posts: 6846 |
Quote Reply
Posted: 27 Jun 2009 at 17:39 |
|
There is a Group Policy setting which controls this. There is a
wireless" policy that will not allow wireless connections when connected to the corporate network. This is far more reliable and easier to manage than trying to discover the adapter in a script.
Edited by jvierra - 27 Jun 2009 at 21:16 |
|
![]() |
|
simanta
I'm new here
Joined: 27 Jun 2009 Online Status: Offline Posts: 2 |
Quote Reply
Posted: 27 Jun 2009 at 22:03 |
|
Thanks for your reply, We cannot stop users from using the wireless, as they have to use that when they are in the meeting rooms, and when they back to their desk they are suppose to use wired network. but I could not able to locate any option in GP that meet my requirement. But I could not able to locate any option in GP that meet my requirement. I feel a script will do that job. Please help.
|
|
![]() |
|
jvierra
MVP
Joined: 31 Aug 2006 Location: United States Online Status: Offline Posts: 6846 |
Quote Reply
Posted: 27 Jun 2009 at 22:12 |
|
Have you tried settting GPO to disable wireless by location. When location is desktop LAN connection then disable wireless else enable wireless for other locations.
If you stil lwant to try it the hard way then use WMI Wn32_NetworkAdapter. You can enable or disable each adapter that you need to control.
Edited by jvierra - 27 Jun 2009 at 22:14 |
|
![]() |
|
Post Reply
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |