DHCP Windows 2008 R2 – providing IP, subnet mask, DNS, and Gateway

DHCP is extremely common and is used by nearly every company out there. Windows Server 2008 R2 is also a very popular server for this kind of operation. These two facts identify this topic as ‘old news’ and is therefore more just for my benefit than anyone else. As usual though, I would be all the more excited if it did turn out to be beneficial for someone else.

Intro: As the heading tells, the goal here is to install DHCP service on a server and push out an IP, subnet mask, DNS address, and a gateway all through DHCP.

Here we go then:

Continue reading

Advertisements

Active Directory-creating a domain with Windows 2012 and 2008 R2 Servers

As a future resource for myself and a resource for others, I thought it might be nice to write a blog post on this. There are a few tricks and features that I have discovered in my quest to create this domain. I hope you are able to benefit from them in some way.

To start, I will be referring to the Windows 2012 server as server 1 and the Windows 2008 R2 server as server 2.

The idea here is to create Windows server 2012 as the first domain controller and then add Windows 2008 R2 later. To start, there are a few things that you should keep in mind:

  • DNS – When you install the domain forest for the first time, you have the option of creating that domain controller as a DNS server as well. This is the option I will be using as it is the most simple and integrates well.
  • Functional Level – You ALWAYS want your functional level to be set the the OLDEST server you have as a domain controller (DC).  More on that later but for right now, just make sure you keep in mind which server is your oldest.
  • Computer Name – The computer name of domain controllers are, as far as I am aware, nearly impossible to change after it has been added to the domain. You should change this before walking through this if you so wish.
  • Options – There are many ways to go through this process. This walk-through will allow you to get a gist as to how this can be done. Weather you start with 2008 R2 or 20012.
  • Pro – I do not consider myself a pro at any level. In fact, I hope that if there are any improvements that can be made, I would expect and appreciate them to be placed in comments below. I believe it your duty (if you find errors) to report  them in the comments as my intentions are to help as yours should be.

So, lets start:

Continue reading

Windows 8 ad hoc

In my initial stages of developing for android, I was told time and time again that using an emulator was no way to go about it. Due to my lack of understanding I decided I would use the emulator to start. Then I got tired of the slow Eclipse emulator and decided to hook up my Android phone and use it instead. I found, after watching a tutorial (The only thing that was missing in this tutorial was downloading the right sdk in the sdk manager so you may have to look that up yourself), that the phone was MUCH faster. The problem was, my app no longer would communicate to the server. This is obviously crucial to the development of the app so I did some research and found that its because of my network blocking the access to my server even while connected to the same wifi. I read that the best way to solve this problem is to create an ad hoc network. Here is where I ran into the issue that shocked me the most.

I have set up ad hoc networks time and time again in Windows 7. However, Windows 8 has taken away the easy way of setting it up (or at least the way I knew how). After a little bit of stumbling around on Windows 8, I couldn’t get past the window that said that I must be in ‘Private’ network mode in order to set up an ad hoc network. I read on some blog page that it based the selection on whether your have your file sharing or network discovery. However, no matter how much I altered the settings, I still had no success.

That is when I came across this site. While it is already on this site, I thought I would repost just in case it ever went away. There is a tool that has been implemented into windows for a while now call “Network Shell.” This tool allows you to do many things like run ad hoc, as long as your driver supports it. The down-side to this tool is that it is strictly command line based. you should have the command prompt opened as administrator before beginning (right click cmd and choose ‘as administrator’).

The first thing is to find whether your driver is capable of ad hoc. You do this through typing:

 netsh wlan show drivers 

At this point, its very helpful to have a picture to see just what I am referring too but it should have some text where somewhere it says ‘ hosted network supported : yes’.  This means that your laptop is capable of doing an ad hoc environment without making any driver changes. Otherwise, you may need to update your wireless drivers.

Next is setting up your ad hoc network. You set up this other network by typing these commands:

 netsh wlan set hostednetwork mode=allow ssid=<?>  key=<?>
netsh wlan start hostednetwork

Here you will notice the <?> in the first command. You replace these with the ssid of your choice as well as the password of your choice. Once these two commands have been run, you are ready to connect with, in my case, your android phone. By the way, all I had to do after that was change the ip address for the server and it worked great!

PS.. I also started to have problems with restarting this ad hoc network. For your information, you may have to go into your ‘device manager’ and go to your network adapters. When you get there, you expand that category and look for the virtual adapter for wifi. You right click and say ‘enable’. This at least solved my problem. The error I was getting looked like this:

The hosted network couldn’t be started. The group or resource is not in the correct state to perform the requested operation.

Hope this helps!