Archive for Servers

SQL Express Backup Utility

The “Express” version of Microsoft’s SQL Server comes with limits, such as 10GB max database. But since it is free, for many small businesses and small database requirements, it fits the bill.

One thing lacking is the ability to do scheduled full and incremental backups of the database.

I’ve used a tool that one of my MVP buddies recommended to me several years ago called Sql Backup And Ftp.

It is one of the easiest utilities to install and setup that I’ve encountered. It comes in both a free and paid version – with the free version limited to backing up a maximum of two SQL databases. The utility allows you to direct backups to a network folder, or to a remote server via FTP, or to a cloud service location, such as OneDrive, DropBox and others.

Give it a try!

Here’s a screen shot of the log of a backup using this utility:

image

2012 R2–We Couldn’t Complete the Updates

I’m setting up two brand new Windows 2012 R2 guests servers on a Hyper-V system. When running Windows Updates, I ran into the following frustrating error:

We couldn’t complete the updates
Undoing changes
Don’t turn off the computer

Well, after waiting an hour for this to reset, I went hunting for a solution. Thanks to my MVP friends, Boon Tee and Susan Bradley, I found out the cause and the fix! You can read Boon’s blog post here.

The issue is a conflict with some updates when your guest VM is configured as Gen2 virtual machine in Hyper-V and you have Secure Boot enabled for that VM. The fix is relatively easy:

  • First, you need to force a power off of your hung VM
  • Once it is stopped, go to the Hyper-V Settings for that VM, and disable (uncheck) the option “Enable Secure Boot”
  • Restart your VM and rerun your Windows Updates.

Please note, I generally do updates in batches – 10at a time, doing security updates firsts, then other other updates, then rollups, then .Net updates.

Renew SSL Certificate for 2012 R2 Essentials

These are the steps I recently followed to renew a third party (GoDaddy) SSL certificate on a 2012 R2 Essentials server. Although these steps have been documented many, many times over the years, it doesn’t hurt to review the process and make sure it works properly.

The overall process has three major parts to it:

  • Generate SSL request on the server
  • Request and rekey the certificate on GoDaddy’s site and download new certificate
  • Install the intermediate cert and your domain SSL cert on the server

Part One – Server

  • Open up the Essentials dashboard, click on Quick Status from the left column of the screen, then click Anywhere Access from the middle column, and finally click “Click to configure Anywhere Access” from the right column of the screen.
    image
  • In the next window ( Settings – Anywhere Access) click on the Configure… button. Please note, there’s a red X in my screen shot. That’s because my SSL certificate is about to expire. However, DO NOT click on the “Repair…” button. Just click on the “Configure…” button
    image
  • In the next windows (Set up Anywhere Access) make sure that you UNcheck the option labeled “Skip Domain name setup. I have already set up my domain”
    image

            image

  • In the next window, select “Import a new trusted SSL certificate”
    image
  • In the next window, first verify your domain name to be registered, which should already be correct as we are renewing an existing SSL certificate. Then click to enable the option “I want to purchase a trusted SSL certificate for this domain”
    image
  • The next screen is the important one. It should display for you automatically the certificate request that you will need. If you need to , open up Notepad and then copy everything inside the box, starting with “—-BEGIN NEW CERTIFICATE” all the way to the very end.

    image

If you wish, leave this window open while you go to Part Two and request the new certificate from GoDaddy

Part Two – GoDaddy

  • Open up a browser, go to GoDaddy’s web site, login, and go to your registered SSL for your domain and select to purchase/renew it. I’m not including screen shots of this process. Go Daddy will generate an email to verify you are the owner of this certificate.
  • Once that is done and approved you can proceed on the GoDaddy site to rekey your certificate. It will ask you to copy/paste in the certificate request info we just generate (that starts with “—-BEGIN NEW CERTIFICATE REQUEST…”
  • After you paste and submit this information, GoDaddy will generate another email to you with the link to download the certificate and instructions for installing it.
  • When you are at the screen to download your certificate, you must select what Server type you will be using this on. From the drop down, select IIS. Then download the generated zip file. If you are not doing this step from the server, then you will need to copy the zip file over to the server.
  • Unzip the zip file on the server. You will have two files, one with a  .p7b suffix and the other with a .crt suffix
    image

Part Three – Server

Before we go back to the Essentials  dashboard that we left open, we first need to go to MMC and insert the new p7b intermediate file from GoDaddy.

  • The steps to do this is provided by GoDaddy (click here). In short:
    • Run C, add the Certificates add-in, select Computer Account, select Local Computer.
    • Once Certificates is added, drill down to Certificates > Intermediate Certification Authorities, right click and select All Tasks > Import.
      image
    • Click to browse, change the file extension in the browse window to “all files”, then locate the .p7b file that came from the zip file, and load it. Once done, you can close MMC.
  • Now we return to the Essentials dashboard that we left open. If it’s still sitting on the “Generate a certificate request’ window, go ahead and click Next.
  • On the next window (“A trusted SSL certificate is in progress…”), click on the first option: “I have the trusted SSL certificate…” and click Next
    image
  • On the next screen (Import the trusted certificate), click to Browse, change the file extension again to “all files” then locate the file ending with .crt that you unzipped, and click Next.
    image
  • Wait while the new certificate is installed. You will get a green check window indicating that the domain is set up. You have one final step – to add this to Anywhere Access
    image
  • On the next screen, you can select to enable VPN access and/or Remote Web Access. I only select Remote Web Access, as I use my network firewall/router box for VPN connectivity.
    image
  • Go ahead and select what you need, and you will be all done. You will also see that the red X we saw earlier should now have disappeared, since the SSL certificate is now up to date.
    image
    image

Windows 10 Workstation Shows Offline Status and No Backups from 2012 R2 Essentials Dashboard

It’s been well documented that updates for Windows 10 (such as the 1607 Anniversary update) will cause issues with interfacing to the 2012 R2 Essentials Server. Two things in particular:

  • Workstations will have a status of Offline on the Essentials Dashboard
  • More importantly, client workstation backups are not up to date

Until now, the process that I had taken to resolve this on each workstation was as follows:

  • Drop workstation to Workgroup
  • Login as local administrator (not domain)
  • Run http://{servername}/connect
  • Use domain admin login and password to proceed, when prompted
  • Approve (acknowledge) you want to use the domain admin login
  • Complete rejoining to the server
  • Reboot workstation and login as domain user

Well, now, it comes to pass that we can make this process a bit faster, as we can eliminate the first two steps (dropping workstation to a workgroup, and logging in with the local admin account).

So here’s how the steps now look, while remaining logged in as the current domain user account:

  • Run http://{servername}/connect
  • Use domain admin login and password to proceed, when prompted
  • Approve (acknowledge) you want to use the domain admin login
  • Complete rejoining to the server
  • It’s possible to just logoff and log back in as the current domain user. However, I still like to reboot the workstation just to make sure all is fine.

Shrink ShareWebDB Log File on SBS 2008

There’s a well known issue on SBS 2008 servers where the SharePoint Config Log file continues to expand. This SQL log file can rapidly grow in size, eating up valuable disk space on your system C: drive.

I first blogged about this back in December 2008 (view blog).

I posted a second blog post 4 years late in December 2012 (view blog) which provided the recommended Microsoft fix (KB 2000544) to truncate the log file, creating a batch command file and an associated SQL command file to truncate this log file.

I only have a few SBS 2008 servers still installed out in the field. But recently I discovered that there is another similar SQL log file that can grow in size: ShareWebDB_log.ldf file.

On this particular server, the ShareWebDB log file had grown to over 200GB in size. Ouch! Ouch! Ouch!

image

The solution is to mimic the two files created for the SharePoint log file solution, but have it truncate the ShareWebDB log file instead.

STEP 1: Create the SQL command file

Download the SQL file from my web site (logshrink2.sql.txt), save it to the root of your C: drive, and then rename it to logshrink2.sql

declare @ConfigDB varchar(255);
declare @ConfigDBLog varchar(255);
declare @ConfigDBCmd varchar(255);
select @ConfigDB =  name from sys.databases where name like ‘ShareWebDb%’;
set @ConfigDBCmd = ‘BACKUP database [‘ + RTRIM(@ConfigDB) + ‘] to disk=”C:\windows\temp\before2.bkf”’;
execute(@ConfigDBCmd);
set @ConfigDBCmd = ‘use [‘ + RTRIM(@COnfigDB) + ‘]’;
execute(@ConfigDBCmd);
set @ConfigDBCmd = ‘BACKUP LOG [‘ + RTRIM(@ConfigDB) + ‘] WITH TRUNCATE_ONLY’;
execute(@ConfigDBCmd);
set @ConfigDBCmd = ‘use [‘ + RTRIM(@COnfigDB) + ‘]’;
execute(@ConfigDBCmd);
select @ConfigDBLog =  name from sys.database_files where name like ‘ShareWebDb_log’;
set @ConfigDBCmd = ‘use [‘ +  RTRIM(@ConfigDB) + ‘] DBCC SHRINKFILE([‘ + RTRIM(@ConfigDB) + ‘_log],1)’;
execute(@ConfigDBCmd);
set @ConfigDBCmd = ‘BACKUP database [‘ + RTRIM(@ConfigDB) + ‘] to disk=”C:\windows\temp\after2.bkf”’;
execute(@ConfigDBCmd);
go

STEP 2: Create the DOS batch command file

Next, download the DOS batch command file from my web site (logshrink2.cmd.txt), save it to the root of your C: drive, and then rename it to logshrink2.cmd

dir c:\windows\sysmsi\ssee\mssql.2005\mssql\ShareWebDb* /s
pause
sqlcmd -S \\.\pipe\mssql$microsoft##ssee\sql\query -E -i c:\logshrink2.sql
pause
dir c:\windows\sysmsi\ssee\mssql.2005\mssql\ShareWebDb* /s
pause

STEP 3: Run the command file with administrator rights

Finally, open up File Explorer, right click on the logshrink2.cmd file, and click to “Run as administrator”

RESULT: Here is a screen shot of running this on the server with a 200GB log file:

image

Cannot RDP into Windows 10 Computer

Working with a customer that has SBS 2008 and upgraded a local computer to Windows 10. We discovered that we could not RDP into that workstation either locally using “mstsc” nor remotely using Remote Web Workplace (RWW).

Turns out the fix is very easy.

By default, Windows 10 has Remote Desktop turned off in the firewall settings for the local workstation.

Here’s how to fix it:

  • Open up Control Panel and go to System & Security –> Windows Firewall
  • Click on “Allow an app or feature through Windows Firewall” option located in the left frame
  • Click on the Change settings button
  • If you do not have administrator access to this workstation, you will be prompted to enter an administrator username and password
  • Scroll down and locate Remote Desktop. Click on the box to select it, and then click on the appropriate boxes under the Domain and Private columns.
    image
  • Click OK.
  • I suggest you then run gpupdate /force from a command prompt, first on the server, and then from the workstation. For the workstation, you may be prompted to logout to apply the update.

Hard Drive Reliability Report for 2015

2015-4tb-drive-fails-barchart[1]Backblaze, a cloud storage company, recently posted their 2015 hard drive statistics and reliability report (click here), which may be interesting reading for some.

Backblaze

Keep in mind this is a report based on their own internal findings and use of disk drives in their datacenter, and is not a broad survey of hard drive reliability from various users and organizations.

So, for example, if you read through the report, you will see that they have nearly 30,000 various Seagate hard drives in use, versus over 12,000 HGST drives, but only 46 Western Digital drives.

This is not to knock their report … in fact, I found it quite enlightening.

Enjoy!

SBS 2011, Windows Server Backup, and VSSAdmin List Writers Issue

One of my customers runs a SBS 2011 server with Exchange 2010. I consider it a very clean server. Suddenly, after three years, I had issues with the Windows Server Backup.

Opening the WSB console, I would get the message Reading Data, please wait….

I knew that the first thing I should check was the VSS writers. When I tried to run vssadmin list writers from an admin level command prompt,  I would get the message: Waiting for responses. These may be delayed if a shadow copy is being prepared.

Rebooting the server didn’t help.

I tried the wbadmin delete catalog command, but that didn’t help.

I then found this blog post from ServerFault.com which provided instructions for stopping specific services, reregistering VSS related DLL’s, and then restarting service. Eventually this solution worked for me!

Here’s a look at each of the looking at each of these three parts of the solution:

Step 1 – Stop specific services

You can run these commands one at a time from a command line prompt, or put them into a  batch file and run them:

net stop “System Event Notification Service”
net stop “Background Intelligent Transfer Service”
net stop “COM+ Event System”
net stop “Microsoft Software Shadow Copy Provider”
net stop “Volume Shadow Copy”
net stop VSS
net stop SWPRV

Note #1: Stopping the COM+ Event System will also cause several other dependent services to be stopped. Take a note of these dependent services so you can make sure they are restarted later on

Note #2: When I ran these commands, the COM+ Event System service did not successfully stop — it will have a status of  “Stopping…”. But it needs to be successfully stopped for the rest of the solution to work. If this happens to you, here’s how to stop it:

    • Open up another command prompt window
    • Type: sc queryex eventsystem and press Enter
    • Note the associated PID# for this service. Let’s say the PID# is 408
    • Next type:  taskkill /pid 408 /F  and press enter’’

Step 2 – Reregister DLLs

Now copy the following commands into a batch file and run it from the command line

regsvr32 /s ATL.DLL
regsvr32 /s comsvcs.DLL
regsvr32 /s credui.DLL
regsvr32 /s CRYPTNET.DLL
regsvr32 /s CRYPTUI.DLL
regsvr32 /s dhcpqec.DLL
regsvr32 /s dssenh.DLL
regsvr32 /s eapqec.DLL
regsvr32 /s esscli.DLL
regsvr32 /s FastProx.DLL
regsvr32 /s FirewallAPI.DLL
regsvr32 /s kmsvc.DLL
regsvr32 /s lsmproxy.DLL
regsvr32 /s MSCTF.DLL
regsvr32 /s msi.DLL
regsvr32 /s msxml3.DLL
regsvr32 /s ncprov.DLL
regsvr32 /s ole32.DLL
regsvr32 /s OLEACC.DLL
regsvr32 /s OLEAUT32.DLL
regsvr32 /s PROPSYS.DLL
regsvr32 /s QAgent.DLL
regsvr32 /s qagentrt.DLL
regsvr32 /s QUtil.DLL
regsvr32 /s raschap.DLL
regsvr32 /s RASQEC.DLL
regsvr32 /s rastls.DLL
regsvr32 /s repdrvfs.DLL
regsvr32 /s RPCRT4.DLL
regsvr32 /s rsaenh.DLL
regsvr32 /s SHELL32.DLL
regsvr32 /s shsvcs.DLL
regsvr32 /s /i swprv.DLL
regsvr32 /s tschannel.DLL
regsvr32 /s USERENV.DLL
regsvr32 /s vss_ps.DLL
regsvr32 /s wbemcons.DLL
regsvr32 /s wbemcore.DLL
regsvr32 /s wbemess.DLL
regsvr32 /s wbemsvc.DLL
regsvr32 /s WINHTTP.DLL
regsvr32 /s WINTRUST.DLL
regsvr32 /s wmiprvsd.DLL
regsvr32 /s wmisvc.DLL
regsvr32 /s wmiutils.DLL
regsvr32 /s wuaueng.DLL

Step 3 – Scan these DLL’s

Next, we will check the integrity of the following three DLLs

sfc /SCANFILE=%windir%\system32\catsrv.DLL
sfc /SCANFILE=%windir%\system32\catsrvut.DLL
sfc /SCANFILE=%windir%\system32\CLBCatQ.DLL

Step 4 – Restart Services

Finally, let’s restart the services we stopped

net start “COM+ Event System”
net start “System Event Notification Service”
net start “Background Intelligent Transfer Service”
net start “Microsoft Software Shadow Copy Provider”
net start “Volume Shadow Copy”

Step 5 – Rerun VSSADMIN

Go ahead and try to rerun the vssadmin list writers command and see if it works.

Review Microsoft License Terms

If you did not know, Microsoft provides a handy web page to view the licensing terms for all of its current products:

https://www.microsoft.com/en-us/useterms

Drop downs allow you to select the product, the version and the language.

image

Error Occurred During Port Configuration – Access is Denied

2015-12-02_15-44-12 XEROX 7830Customer is running Windows Server 2012 R2 Essentials, and just had a Xerox WorkCentre 8530 delivered to their office.

Working with the local Xerox printer tech, we got the driver installed on the server and tested printing.

But he wanted to show me some things under the “Configure Port” option, but when we tried to do so, we got the following error message:

An error occurred during port configuration. Access is denied.

I was stumped, as I knew we were logged on as an administrator. I even tried using Print Management service.

I then found a helpful step-by-step solution to this problem over on the GeeksOnTech website. Their post includes screen shots, but here is a summary of the steps:

  1. Open up Devices & Printers
  2. Highlight the printer you want to change, then click on Print Server Properties from the menu bar
  3. On the next window, click the Ports tab, and then at the bottom of that same window click Change Port Settings
  4. Now select your printer, and then click Configure Port…

Hope this helps!