HTML vs XHTML

Ever wondered what HTML and XHTML is about? Long and official story can be found at W3Schools. Short story, below.

Simply put, XHTML is the same as HTML but stricter. There are rules in place that one must follow. You are no longer allowed to leave tags unclosed or place them wherever you want. And guess what, the only beneficiary from following these rules, is you, the web developer. Because your site will then be supported by most of the browsers out there; definitely more than your badly formatted HTML is today.

Quoting W3Schools, the most important differences from HTML are listed below.
Please visit W3Schools post to see examples of good vs bad code.

Document Structure

  • XHTML DOCTYPE is mandatory
  • The xmlns attribute in <html> is mandatory
  • <html>, <head>, <title>, and <body> are mandatory

XHTML Elements

  • XHTML elements must be properly nested
  • XHTML elements must always be closed
  • XHTML elements must be in lowercase
  • XHTML documents must have one root element

XHTML Attributes

  • Attribute names must be in lower case
  • Attribute values must be quoted
  • Attribute minimization is forbidden

How to convert from HTML to XHTML

  1. Add an XHTML <!DOCTYPE> to the first line of every page
  2. Add an xmlns attribute to the html element of every page
  3. Change all element names to lowercase
  4. Close all empty elements
  5. Change all attribute names to lowercase
  6. Quote all attribute values

Moreover, these guys also developed a website where you can validate your page to be XHTML (and not only) compliant. They will also tell you exactly what you did wrong and how to correct. And don’t worry, it’s free! It only costs your willingness to do it the right way.

Ok, e-books

Let’s start with some bullshit talk to tell you how this topic started. Feel free to skip it if you’re not curious.
Personally, I’m not the kind of person who reads books not related to IT; think I can count all books I read throughout my lifetime and there are no more than 10, but this is not something to be proud of. Anyway, since all my books are IT related and I mainly read them in front of a computer, after having some sleep issues last year, I decided I need to read something else before going to bed. Well, before falling asleep… So, I bought a Kindle e-book reader, yey!

Next issue, what a hell to read?! My wife only reads crime novels, so she couldn’t help in this matter. Although I thought about reading what she reads, mainly to see if she’ll prepare me something to eat from a crime book we’re good though, just had our 9th wedding anniversary!
I remember that when I was a kid I read something from Jules Verne, in Russian, and I liked it… Searching the web for some e-books I found a very nice webstore (www.bestseller.md) from Moldova that offers lots of free e-books. I downloaded a few and started reading in bed. That’s what I started with, Jules verne. It was so boring, I started falling asleep within minutes; mission accomplished!
After few chapters things started to get interesting in the book so I was reading more and more each day. I finished the book and I was proud of my fantastic achievement, lol.

I started the second book, also from Jules Verne, downloaded from same website (thanks, guys!). Here things started moving from reading side to IT side… mainly because first book I read had a nice handy feature that let me know how many minutes I have from current chapter or book. The second one, didn’t. It only said how much I have till end of the book. Well, well, well… why, what’s wrong?! I started digging… and this means I was no longer reading before going to bed, instead I was web-ing over this issue. Apparently, this second .mobi file was not formatted properly, specifically its chapters. Hmm…

Reading more and more about e-books, and how they’re created and published, seemed interestingly so I started testing how this works. I found no real step by step guide on how to do it. Lot’s of general articles covering this on a high level with steps to follow, blah, blah and in the end asking you to buy their e-books where they explain everything step by step. Well, gracias, what can I say.

Then I stumbled upon one publisher’s website with some info online (posted way back in 2013) and the rest of it in the e-book sold on Amazon (updated in January 2018). It was cheap, so I bought it. Of course, my eagle eyes immediately found many typos and errors in the book, that I emailed author about but… anyway, let’s get back to the point. Overall, that book is enough to get you started. Since I’m an IT guy, it was easy for me to understand everything, especially HTML and CSS things. Reading that book, I understood that this is what an e-book is all about – HTML, CSS and some XML. In fact, did you know that if you take an .epub file and change the extension to .zip, you will have an archive with everything in it (css file, html file, table of contents etc.)!? When I found out about it, I felt just like I did last decade – holy cow! This was when Microsoft first introduced their new XML based files (docx, xlsx etc.), and someone showed in a training that if you rename .docx to .zip, you get a nice structured zip file. technology, I love it!
Enough talking, let’s get started. Head of over to my next post, Creating an e-book. Part 1.

Getting back online

After many years, giving this blog a rebirth.

I lost my backup files and only found very few posts and those mainly about ConfigMgr 2012. Will post them below anyway; better few than nothing.

Next planned articles will be about e-books and plain html maybe, we shall see Smile Stay tuned!

Also need to create/update “About” page. Things have happened, so to speak… jobs changed, places changed etc.

Object Replication Manager failed to process Object changes.

Symptoms

Did your SMS_OBJECT_REPLICATION_MANAGER component shows a lot or 6004 MessageIDs with the following description: “Object Replication Manager failed to process Object changes. These changes will be retried on next processing cycle.?

Cause

By design, maybe.

Resolution

Run the following query in SQL Management Studio (Warning! modifying the database directly may not be supported by Microsoft. Do this on your own risk.):

SELECT ca.UniqueID,c.CollectionName
FROM vClientSettingsAssignments as ca LEFT JOIN collections AS c ON ca.CollectionID=c.SiteID
WHERE CollectionName = NULL

This will show collection name/s for all active assignments to collection/s that do not exist anymore.

If you have any, copy the UniqueID and run the following query:

DELETE FROM vClientSettingsAssignments
WHERE UniqueID = ‘{UniqueId here}’

Credit goes to: https://social.technet.microsoft.com/Forums/en-US/2e9ba246-194d-47d4-adc9-eb3b1717bfdc/object-replication-manager-failed-to-process-object-changes?forum=configmanagergeneral

Step-by-step guide to install Configuration Manager 2012 SP1 R2

Steps to perform on primary domain controller (DC)

Extend AD schema

  1. Log in using a domain admin account
  2. Insert ConfigMgr 2012 SP1 DVD
  3. Open a command prompt window
  4. Type D:\SMSSETUP\BIN\X64\EXTADSCH.EXE and press Enter. Wait for a confirmation message in CMD window and then check for the existence of ExtADSch.log file in the root of C: partition on the DC. Open the file and see if “Successfully extended the Active Directory schema.” message is present.

Assign permission to System OU in AD

  1. Open Active Directory Users and Computers
  2. From the View menu select Advanced Features
  3. Right click on the System container and select Properties
  4. Go to Security tab and click Advanced
  5. Click Add in the Permission tab
  6. Select Object Types and check the box for Computers. Click OK
  7. In the Enter the object name to select field enter the name of the ConfigMgr server and click Check Names
  8. After the server name is recognized, click Ok
  9. In the Permission Entry for System window check the box for Full control and select This object and all descendant objects in the Apply to list box. Click OK three times to close all open windows

Create service accounts

  1. Open ADUC and create the following 3 service accounts (select complex password for each account):
    1. SQL Server Service Accountsqlsrvacct
    2. ConfigMgr Client Push Service Accountcfgmgrclpush
    3. ConfigMgr Network Access Service Accountcfgmgrnetacct
  2. Make cfgmgrclpush account member of Domain Admins group or Workstation Admins group if this exists.

Create GPO to add security groups to local Administrators group on servers and workstations

  1. Server local admins
  2. Workstation local admins

Steps to perform on Configuration Manager server

Install Report Viewer 2008 SP1 Redistributable

  1. Login with a domain admin account, preferably not Administrator.
  2. Download and install Report Viewer 2008 SP1 Redistributable from http://www.microsoft.com/downloads/en/details.aspx?familyid=BB196D5D-76C2-4A0E-9458-267D22B6AAC6&displaylang=en

Add Server Features

  1. Open Server Manager and add the following features:
    1. NET Framework 3.5.1 Features, BITS, Group Policy Management and Remote Differential Compression
    2. From Web Server (IIS) select WebDAV Publishing, ASP.NET, ASP, Windows Authentication, Dynamic Content Compression and IIS 6 WMI Compatibility

Configure WebDAV

  1. Open Internet Information Services (IIS) Manager
  2. Expand server name and select Default Web Site
  3. Double click on the WebDAV Authoring Rules and select Enable WebDAV from the right side panel
  4. From the right side, click Add Authoring Rule
  5. In the Add Authoring Rule window select the checkboxes for: All Content, All Users, Read and click OK
  6. From the right side, click WebDAV Settings
  7. Modify the following components as follows and click Apply when finished:
    1. Allow anonymous property queries – True
    2. Allow custom properties – False
    3. Allow property queries with infinite depth – True
    4. Allow hidden files to be listed – True

Add SQL Server ports exceptions

  1. Open Windows Firewall with Advanced Security
  2. Right click Inbound Rules and select New rule
  3. In the New Inbound Rule Wizard window make the following modifications:
    1. Rule Type – Port
    2. Protocol and Ports – TCP, Specific local ports: 1433
    3. Action – Allow the connection
    4. Profile – no modification
    5. Name – SQL TCP 1433
  4. Repeat step 3 to add another inbound rule with the following settings:
    1. Rule Type – Port
    2. Protocol and Ports – TCP, Specific local ports: 4022
    3. Action – Allow the connection
    4. Profile – no modification
    5. Name – SQL TCP 4022

Install SQL Server 2012 SP1

  1. Insert SQL Server 2012 SP1 DVD
  2. Select New SQL Server stand-alone installation
  3. Select features: Database Engine Services, Reporting Services – Native, Client Tools Connectivity, Management Tools, Integration Services (optional)
  4. Select default instance
  5. Add sqlsrvacct domain account to the local Administrators group on the ConfigMgr server
  6. Use the SQL service account for all SQL Server services
  7. Set SQL Server Browser to Automatic
  8. Add current user as the SQL Administrator (preferably not domain Administrator account)
  9. After installation, open Management Studio and configure maximum memory allocation.

Install Windows Deployment Services

  1. Open Server Manager and install the Windows Deployment Services role using the default settings

Install Windows Server Update Services

  1. Open Server Manager and select the Windows Server Update Services role. Click Next twice and then Install
  2. Install WSUS using the following settings:
    1. Select Update Source – select a disk with more disk space
    2. Database options – Use an existing database server on this computer
    3. Web Site Selection – Create a Windows Server Update Services 3.0 SP2 Web Site (http://servername:8530)
  3. When installation is finished, close the wizard by pressing Cancel button
  4. Create a Group Policy Object for windows update settings.
  5. If you have Windows Server 2008 R2, install KB2720211
  6. If you have Windows Server 2008 R2, install KB2734608

Install Windows Assessment and Deployment Kit (ADK) for Windows 8.1

  1. Download Windows Assessment and Deployment Kit (Windows ADK) for Windows 8.1 from Microsoft website http://www.microsoft.com/en-us/download/details.aspx?id=39982
  2. Select to install only the following:
    1. Deployment Tools
    2. Windows PE
    3. USMT

Install Configuration Manager 2012 SP1

  1. Insert Configuration Manager 2012 SP1 DVD
  2. Click Install link Configuration Manager 2012 SP1 Setup Wizard window.
  3. Install ConfigMgr and make only the following modifications:
    1. Available Setup Options – Install a Configuration Manager site server
    2. Updated Prerequisite Components – Check for updates and download…
    3. Site and Installation Settings – enter a Site code and Site name

Install Configuration Manager 2012 R2

  1. Insert Configuration Manager 2012 R2 CD
  2. Click Configuration Manager 2012 R2 link from the Install section
  3. Install the R2 add-on accepting the default settings in the wizard

Configure Configuration Manager as needed

Deploy Configuration Manager 2012 R2 hotfix to Clients using your preferred method and settings.

Despooler failed to merge delta to the compressed package. Error 112.

Symptoms

You make changes to a package and update your distribution points. Shortly you receive error messages in Component Status for SMS_DESPOOLER component.

image

Status message details is similar to the following:

image

Cause

The destination drive where site server is uncompressing the package is full.

Resolution

If you don’t know the drive where the package is uncompressing to, open the despool.log file from the site server system where this error occurs. In the log file look for the following lines:

Received package PackageID version 12. Compressed file –  F:\SMSPKG\PackageID.DLT.11.12 as F:\Program Files\Microsoft Configuration Manager\inboxes\despoolr.box\receive\PKG8l1ab.TRY
Old package storedUNC path is \\SiteServerFQDN\F$\SMSPKG\PackageID.PCK.
Use drive F for storing the compressed package.
No branch cache registry entries found.
Uncompressing F:\SMSPKG\PackageID.PCK to F:\SMSPKG\PackageID.PCK.temp
WriteFile failed, 0 bytes written
FileWrite failed; 0x80070070
decompression failed for F:\SMSPKG\PackageID.PCK to F:\SMSPKG\PackageID.PCK.temp
CContentBundle::ExtractContentBundle failed; 0x80070070
Failed to extract contents to the content library. 0x80070070
Failed to extract package contents from F:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\INBOXES\DESPOOLR.BOX\RECEIVE\PKG8L1AB.TRY. Error = 112

So, looks like we have a low disk space problem on disk F:. Clean it up to create more space and monitor Component Status again. Shortly, you should see the following:

Received package PackageID version 12. Compressed file –  F:\SMSPKG\PackageID.DLT.11.12 as F:\Program Files\Microsoft Configuration Manager\inboxes\despoolr.box\receive\PKG0auju.TRY
Waiting for ready instruction file….
Old package storedUNC path is \\SiteServerFQDN\F$\SMSPKG\PackageID.PCK.
Use drive F for storing the compressed package.
No branch cache registry entries found.
Uncompressing F:\SMSPKG\PackageID.PCK to F:\SMSPKG\PackageID.PCK.temp
Content Library: G:\SCCMContentLib
Extracting from F:\SMSPKG\PackageID.PCK.temp
Extracting package PackageID

Extracting content 1c4c0f71-e7a3-4cda-813f-dc7baff8d6a7
Extracting content 93f2ea53-fbf5-4082-98c3-a2b3887dd658
Extracting content 73a4fc00-02da-4e32-824d-957053338834
………
Extracting content 79267f60-69a5-465c-8a40-a6a8db8b1416
Extracting content 1181a482-c797-451c-9468-e2bf1bc8d68d
Package PackageID (version 11) exists in the distribution source, save the newer version (version 12).
Stored Package PackageID. Stored Package Version = 12

This time, our package uncompressed fine and it was stored successfully in the content library.

Status message details will now show this message:

image

Uncheck “Install new versions automatically” in Internet Explorer 10 during deployment

IF you during deployment you want to easily uncheck “Install new versions automatically” feature, there is a registry setting you can configure prior to actual IE setup.exe or msi, whatever you use.

clip_image002

Copy the following text to a notepad and save it as a REG file. Then use REG IMPORT “Disable_AutoUpdate.reg” before you deploy your IE and that’s all.

Windows Registry Editor Version 5.00
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main]
"EnableAutoUpgrade"=dword:00000000

For example, here’s our script to deploy IE and disable auto update:

: - - - - - - Uncheck "Install new versions automatically" - - - - - - -
REG IMPORT "Disable_AutoUpdate.reg"
: - - - - - - Install Application - - - - - - -
MSIExec /i "IE10-Setup-Full.msi" /qn /norestart /l*v C:\Windows\Temp\Microsoft_IE10_x64_ENG_R1_Install.log
EXIT

Uninstall software on remote computers using WMIC

Recently, I wanted to install Nokia Ovi Suite to several computers in a company that started to have problems with their internet provider; it’s a third day when they do not have internet connection. So I thought it’s a good idea to show them how they can use their Nokia E72 phones to connect their laptops to internet.

Well, prior to installing Nokia Ovi Suite I had to uninstall old versions of Nokia PC Suite from 4 systems, remotely. I decided to do it using WMIC instead of ConfigMgr as the Nokia PC Suite was installed on small number of computers. After this, I can proceed with installing Ovi Suite using ConfigMgr. Till then, here is how I uninstalled PC Suite using WMIC.

  1. In a command prompt window, type Runas /user:YourUsername@UPNsuffix cmd.exe (or Runas /user:domain\username cmd.exe) where YourUsername is your domain admin username or any username with admin privileges on the remote computer and UPNsuffix is your UPN suffix. Let’s suppose I use Administrator@domain.com
  2. In the command prompt window type the password for user Administrator@domain.com and press Enter
  3. Type WMIC
  4. Now, list all Nokia software on a specific computer using the command /node:COMPUTERNAME product where vendor=”Nokia” get name, version
  5. Once we know the software name, we can uninstall specific product using the following command /node:COMPUTERNAME product where name=”Nokia PC Suite” call uninstall. You will see a message like Execute (\\COMPUTERNAME\ROOT\CIMV2:Win32_Product.IdentifyingNumber=”{225DB4AA-3CFF-47E8-B3C8-6DAD713E986E}”,Name=”Nokia PC Suite”,Version=”7.1.51.0″)->Uninstall() (Y/N/?)?
    Type Y and wait for the result.
  6. To make sure Ovi Suite will install successful, I’m going to uninstall all Nokia software (except the runtime) using the same command just replacing the software name.
  7. Now, I can proceed and install Nokia Ovi Suite 3.1.1.78 using ConfigMgr Software Distribution method. By the way, program’s command line for silent install is Nokia_Ovi_Suite_webinstaller_ALL.exe /SILENT=”1″

If vendor name contains spaces, use the following example: wmic product where vendor=”Microsoft Corporation” get name

Uninstall KB 2823324 using ConfigMgr

  1. Create a CMD file with the following content
    @echo off

    :: - - - - - Check if KB is installed - - - - - - - -

    systeminfo | findstr 2823324

    :: - - - - - If not installed (1), exit - - - - - - -

    IF %errorlevel% EQU 1 GOTO NOTFOUND

    GOTO FOUND

    :NOTFOUND

    Echo %date% - %time% KB 2823324 was not found. Exit. >> C:\Windows\Temp\Microsoft_Uninstall_Patch_KB2823324.log

    GOTO EXIT

    :: - - - - - If installed (0), uninstall - - - - - - -

    :FOUND

    Echo %date% - %time% KB 2823324 was found. Attempt uninstall. >> C:\Windows\Temp\Microsoft_Uninstall_Patch_KB2823324.log

    wusa.exe /uninstall /kb:2823324 /quiet /norestart /log:C:\Windows\Temp\Microsoft_Uninstall_Patch_KB2823324_WUSA.log

    Echo %date% - %time% KB 2823324 uninstall complete. Restart might be needed for operation to complete successfully. >> C:\Windows\Temp\Microsoft_Uninstall_Patch_KB2823324.log

    :EXIT

  2. Deploy this CMD file by creating a new package and program. Keep in mind that a restart is required to fully uninstall this patch.

Find computer name for a remote computer using PSExec

Let’s say you know the IP address of a computer but you don’t know the hostname. Seems to be an easy task with ping –a, if you have a working DNS Smile

If not, you can try the following approach:

  1. Create a cmd file on client’s computer. Say in \\IP\C$\Windows\Temp\FindHostname.cmd
  2. Edit FindHostname.cmd. Type in: echo %computername% >> C:\Windows\Temp\Hostname.log
  3. Run PSExec: C:\PSTools\PsExec.exe \\IP C:\Windows\Temp\FindHostname.cmd
  4. Look into \\IP\C$\Windows\Temp\Hostname.log, you will have the computer’s name.