IOS Upgrade on 2960S,X

archive download-sw /leave-old-sw /reload tftp://ip/file.tar


Where is the SMSTS.log located?

Pretty handy while testing OSD

SCCM Guy's Blog

As we all have had to troubleshoot our task sequences before we need to refer to the smsts.log file troubleshooting. However depending on what stage of the task sequence you are at the log file will move on you.

Below are the locations the log file will be in depending on the stage you are at.

During OS Deployment


Before your hard drive is formatted and partitioned             



After your hard drive is partitioned formatted                 

X:smstslog and then is in C:_SMSTaskSequencelogssmstslog


Within Windows

Within Windows before the SCCM agent is installed:        



Within Windows after the SCCM agent installed:            



When the Task Sequence completes on a x86            



For x64 Systems


View original post

VMM Event ID 19999, M.V.E.W.COMPort..ctor

Thats the second time I’m having this problem in 3 years and again i have wasted some time to find solution for that. It’s time to blog it so i want forget it ;].

VMM service want start because invalid entry about COM Ports in SQL. This can happen if some magic happens to VM’s in VMM and the data get inconsistent.

The symptoms are:

Event ID 19999
Clear the failed status of service in scvmm so we can scale out using SCVMM 2012 SP1
Virtual Machine Manager (vmmservice:3372) has encountered an error and needed to exit the process. Windows generated an error report with the following parameters:

And the solution is:

Use SQL Management Studio to run below queries on VMM DB

SELECT v.Name, v.HWProfileID, COUNT(c.VCOMPortId)
FROM tbl_WLC_VObject v
ON v.HWProfileId = c.HWProfileId
GROUP BY v.HWProfileId, v.Name

We will get a list of all VMs along with HWProfileID. We look at the Value column and search for value less the 2. If we find such VM’s we have to use the next query so many time till we get value 2. So i we have 0 we run the query 2 times.

(HWProfileId, ParentType, PortType, PortNumber)
(‘HWProfileID’, 3, 0, 1)

We replace the HWProfileID with the one of the machine we want to increment value of COM Ports.

If by running the first query we find VM with value more then 2 we have first to reset the value to 0 with the query below and after that run the above query twice (Ofc replace the HWProfileID with respectiv VM HWProfileID).


Java Deployment as Package with PS App Depolyment Toolkit

Lately i was asked to finally implement Java Updates to our SCCM solution. I was thinking another msi, no problem. I was very wrong, spent 3 days to do it. Java isn’t like any other program you deploy via SCCM, there are 2 important points you have to remember:

  1. no web browser can be open during the installation,
  2. you have to inform the user that the web browser will be closed and give him ability to delay it.

There are many blogs on how to deploy Java Updates via Package or Application but none of them works for me. Even the simple MSI deployment don’t work anymore with the newest Java Update because of the dividing the install on msi and big cab file, do not know why but clients get only the small msi file and are missing the cab file.

Below are my findings and i have to say this little app (PS script), that let me finally install Java flawlessly, is awesome and can be used for any deployment or deinstallation process.

PS App Deployment Toolkit


Deploying Java update to computers with information to the users and ability to deferral.


CM Server Windows 2012 STD:

  • SCCM 2012 SP1

Process Overview:

  1. Download PS App Deployment Toolkit,
  2. Download MSI version of Java Update,
  3. Modify PS App Deployment Toolkit script,
  4. Copy Java files,
  5. Create Package,
  6. Deploy and enjoy.



After downloading and unpacking PS APP Deployment Toolkit we will get catalog containing some files and other catalogs. For deployment we need only the toolkit catalog with all files an catalogs that it contains. There is a great AdminGuide docx in the package too, that is pretty awesome and full of detailed info how to use and what to modify.

Now we need to download Offline installer of Java and extract the msi and cab files. Info on how to do that can be find on many blogs.

I really do not want to copy/paste content from the AdminGuide, all information on how to successfully deploy Java Interactively to your users is in that file. I can only say it works great is explained super simple and have many options to customize it the way you like it.


PowerShell Script fo host file modification

While i was implementing SCCM i nedded to add in host file of every computer in our firm records about DP’s and MP (SCCM in untrusted domain then the rest of infrastructure). Doing it manually would take great amount of time to accomplish (over 300 clients). So i have Google’d a bit and combined some codes to get the result i want.


Enabling PowerShell remoting:

The ‘Enable Powershell Remoting’ Policy

All of the settings we are using will be in Computer Configuration so if you want to disable User Configuration as I have go ahead.

  1. Create your GPO, name it what you want, place it where you want, etc.
  2. Edit your policy.

Enabling WinRM

  1. Browse to:
    Policies > Administrative Templates > Windows Components > Windows Remote Management (WinRM) > WinRM Service
  1. Open the “Allow Remote Server management through WinRM” policy setting (Server 2008 R2 and later).
  2. Open the “Allow automatic configuration of listeners” policy setting (Server 2008 and earlier).
  1. Set the Policy to Enabled.
  2. Set the IPv4 and IPv6 filters to * unless you need something specific there (check out the help on the right).

Setting the Firewall Rules

  1. Browse to:
    Policies > Administrative Templates > Network > Network Connections > Windows Firewall > Domain Profile
  2. Open the “Windows Firewall: Define inbound port exceptions” policy setting.
  3. Set it to Enabled if it isn’t already.
  4. Click the “Show…” button and add the port exception. We’re going to be opening TCP port 5985, so the exception string will look something like this:


Host mod script

$cred = Get-Credential domain\admin
#Credentials to use
$session = New-PSSession -cn (get-content “hostlist.txt”) -cred $cred
#Creating remote sessions to computers based on hostlist.txt file
icm -Session $session -ScriptBlock {copy c:\windows\system32\drivers\etc\hosts c:\windows\system32\drivers\etc\hosts.backup}
#Creating backup of host file
icm -Session $session -ScriptBlock {type c:\windows\system32\drivers\etc\hosts > c:\windows\system32\drivers\etc\hostsb}
#changing name of the host file
icm -Session $session -ScriptBlock {echo “XXX.XXX.XXX.XXX      server01.domain.local” >> c:\windows\system32\drivers\etc\hostsb}
icm -Session $session -ScriptBlock {echo “XXX.XXX.XXX.XXX      server02.domain.local” >> c:\windows\system32\drivers\etc\hostsb}
icm -Session $session -ScriptBlock {echo “XXX.XXX.XXX.XXX      server03.domain.local” >> c:\windows\system32\drivers\etc\hostsb}
#Adding lines to the host file
icm -Session $session -ScriptBlock {del c:\windows\system32\drivers\etc\hosts}
#Deleting the old host file
icm -Session $session -ScriptBlock {get-content c:\windows\system32\drivers\etc\hostsb | out-file -encoding utf8 c:\windows\system32\drivers\etc\hosts}
#Adding lines to host file changes the coding and makes the file unreadable for system so we have to change the coding back to UTF. At the same time the name is changed to hosts
icm -Session $session -ScriptBlock {del c:\windows\system32\drivers\etc\hostsb}
#Deleting the working hosts file

I hope it will help somone.

SCCM2012 DB Migration

This guide works great but it is missing one important step. Before using CM Setup to reconnect to the new DB server restart the SQL server. This way the Cert on CM server will be recreated for the new SQL server (assuming SQL is using Domain Service Account). After migration connection port in SUP config changed to the default 80, needed to change it back to 8530 (WSUS on 2012 sp1)

SCCM 2012: Access Denied while trying to download updates

Works great, remember that the computer from which you use SCCM console to create deployment need to have the SCUP cert

IT Consultant Everyday Notes

I tried to download monthly updates to my Deployment Package. The attempt failed with Access Denied for all updates. It turned out that even my account is a local admin on the SCCM server I need to add it with Full rights to the source share (both NTFS and Share permissions) where my Deployment Package is located.

As soon as I added the account implicitly and granted rights to it SCCM successfully downloaded necessary updates to the Deployment package.

View original post