Wednesday, January 23, 2013

How to migrate the DHCP service to Windows 2012

One of my customers asked me to dismiss an old Windows 2003 R2 server which is running the DHCP service for a bunch of workstations and to replace it with a new Windows 2012 server we installed last December.

Seen the fact that this DHCP service is configured with many options and a lot of reservations, and that I am totally lazy about recreating all these settings manually, I found a way to dump its configuration to a text file and to import it back to Windows 2012.

Let's start exporting the DHCP database from the server that is running Microsoft Windows Server 2003 with the command:

netsh dhcp server export C:\dhcp_config.dat all
This generates the binary file C:\dhcp_config.dat. After this operation has completed, stop the DHCP service:
net stop "dhcp server"
Now let's log on to the Windows 2012 server and, after having set it up with a manually assigned IP address, install the DHCP service using Powershell, of course:
Import-Module ServerManager
Add-WindowsFeature -IncludeManagementTools dhcp
As you can see we need to happend the "IncludeManagementTools" switch, otherwise just the DHCP server role would be installed and not the management console.

The next step is to authorize the DHCP server in Active Directory, otherwise it will be considered as rogue. To do so:
Add-DhcpServerInDC  dhcpservername  dhcpipaddress
The last step is to import the dump of the configuration from the old server:
netsh dhcp server import \\dhcpservername\c$\dhcp_config.dat all
A restart of the DHCP service and that's all:
restart-service dhcp
Hotpe this helps and feel free to comment.

Crucial M4 and Samsung 840 performance review

The SSD market is one of the thing I have found interesting to follow last year, and, while I know this blog is oriented on system administration topics, I am always pleased to share the results of the tests I do on new hardware.

To start off, I must say I am happy with my new NAS configuration (based on a underclocked Intel G530, 4 GB of low cost RAM and a Crucial M4 64 GB). Nonetheless, I took the chance to test three new SSD when I was offered to, also because the model I got are some of the best on the market and many people could be interested in a comparison.

The three disks I tested with the freeware AS SSD (which is to me the best workstation SSD benchmarks available at the moment) are:
As a reminder, the results I got one month ago with the Crucial M4 64 GB (model M4-CT064M4SSD1) in AHCI mode under Windows 2012 where:
  • 504 MBs in sequential read
  • 110 MBs in sequential write
  • 727 as final score
Needless to say, this drive was outperformed by the three new drives I have received.

Let's start with the Crucial M4 128 GB.
The main difference between the 64 GB and the 128 GB version is the noticeably higher sequential write of the 128 GB (and if you want to know why, you better read this excellent article on Tomshardware):
  • 509 MBs in sequential read
  • 201 MBs in sequential write
  • 810 as final score

Moving to the Samsung 840, which boasts  the 4th generation tri-core Cortex-R4 controller, I was even more impressed:
  • 525 MBs in sequential read
  • 253 MBs in sequential write
  • 1045 as final score
Here you can see that the 840 is faster than the other tested drives in every run.

As for the Samsung 840 Pro, it outspaced all the other drives in terms of sequential write speeds.
  • 524 MBs in sequential read
  • 505 MBs in sequential write
  • 1232 as final score
Now that you know all these figure, know also that these values in sequential read and sequential write are not what you should be interested in if you are going to buy a new SSD to use for storing the operating system. This is because random 4k speeds reads are the kind of operations OS and other software do most. It is the ability to perform 4K reads quickly that makes SSDs feel so fast if compared to HDDs, not the doubling of sustained transfer which most drives are advertised on.

So back into comparison mode, but for random reads and writes this time:

Crucial M4 64 GB
  • 4K reads    23 MBs
  • 4K writes    57 MBs
Crucial M4 128 GB
  • 4K reads    27 MBs
  • 4K writes    86 MBs
Samsung 840 250 GB
  • 4K reads    30 MBs
  • 4K writes    116 MBs
Samsung 840 PRO 256 GB
  • 4K reads    38 MBs
  • 4K writes    124 MBs
Here's the screenshots from AS SSD, for more details.

Cucial M4 128 GB

Samsung 840 250 GB

Samsung 840 PRO 256 GB
The Samsung 840 PRO was by far the real winner of my tests, almost doubling the random read speed compared to my Crucial M4 64 GB. So I decided to keep it as operating system drive, also because the power consumption fell of ~1 watt. Now I am peacefully sitting to 26 watts at idle!

Ok I have to go: Owncloud 4.5.6 is out. and I am going to test it out right away!

Wednesday, January 16, 2013

Real world data deduplication savings under WIndows 2012

I have been testing Windows 2012 Data Deduplication for quite a long time now (starting from last October when I wrote for the first time on the topic). What I think I was lacking more was real world information about what one could expect from the DeDuplication process on well-known filetypes.

Though Microsoft provided a tool that gives a generic preview of the results a system administrator can expect from this new mechanism (the tool I am talking about is ddpeval.exe), I think that sharing real world statistics on a filetype basis can greatly help the understanding of its usefulness.

So I have decided to use a bunch of disks in a one-to-one relationship with one type of file and enable deduplication at filesystem level.

I had in my stock four 50 GB SATA disks which I formatted with NTFS (remember that Windows 2012 new ReFS doesn't support Dedupe for the moment).

Tuesday, January 15, 2013

Tracking logon events to Owncloud with Powershell

If you have followed my blog recently, you already know that I am interested in the new on-premise cloud solution names Owncloud. I have spent many hours testing this software and, though young, it has some interesting features which make me willing to keep going on with it. Unfortunately for me, the version running on Windows Server has many known bugs and many missing features. 

In this post I will detail how to force OwnCloud on Windows to keep a log of authentication events, which is a feature of primary importance to me. To do it, I'll show you how to modify the PHP code, as well as how to put in place a Powershell scheduled task aimed to sending e-mail alerts upon authentication events.

Monday, January 7, 2013

How to encrypt your data for the Cloud

Today there are plenty of reasons for moving your important personal data into the Cloud, but I am not here today to treat an already widely discussed subject. I will instead focus on its major drawback: once you upload your data to Cloud services such as Dropbox or iCloud, you are no more the owner of your files. Which means that you must blindly trust your storage provider without having nothing more than a general idea of the infrastructure and the security mechanisms in place.

So, when storing data on a public cloud, users should be especially wary because the content is not in their control, but in someone else’s.

The countermeasure to this possible problem is to use a simple encryption mechanism.

Related Posts Plugin for WordPress, Blogger...