Showing posts with label SCCM 2003. Show all posts
Showing posts with label SCCM 2003. Show all posts

Friday, 11 January 2013

Propagating SCCM DB for "Hardware 2A - Estimated computer age by ranges within a collection" report

As you know or have just found Microsoft hasn't been updating the LU_CPU table in SCCM since 2006. So running a computer age report  "Hardware 02A - Estimated computer age by ranges within a collection" shows Not Available for computers have CPUs launched after 2006.

But you can update this data manually if you really need to run these reports. I did it in 1 day, it was boring but seeing the result was a big relief. Now I know I will not have to import hundreds of records again.

Result :

11-01-2013 13-29-47

Steps? Here : )
1. Find discovered CPU information in v_GS_Processor, and exclude CPUs already exist in LU_CPU table.
SELECT DISTINCT
.[v_GS_PROCESSOR].CPUHash0 AS CPUHash,
.[v_GS_PROCESSOR].Manufacturer0 AS Manufacturer,
.[v_GS_PROCESSOR].BrandID0 AS BrandID,
.[v_GS_PROCESSOR].PCache0 AS PCache,
.[v_GS_PROCESSOR].NormSpeed0 AS NormSpeed,
.[v_GS_PROCESSOR].IsMobile0 AS Mobile,
.[v_GS_PROCESSOR].Name0 AS Name
FROM
.[v_GS_PROCESSOR]
LEFT JOIN
.[LU_CPU] as LC
ON
.[v_GS_PROCESSOR].CPUHash0 = LC.CPUHash
WHERE
LC.CPUHash is null

After running query and seeing the results you might want to add something like these to make it shorter by excluding bad looking ones to check them at the and.
AND
.[v_GS_PROCESSOR].Name0 Like '%[0-9]%' /* Exclude rogue entries */
AND
.[v_GS_PROCESSOR].Manufacturer0 Like '%Intel%'
AND
.[v_GS_PROCESSOR].Name0 Not Like '[" "]%' /*Exclude duplicates and rogues*/

Now you have as much as usable data from the view, Column names match the LU_CPU as well.
 11-01-2013 13-42-49

 2. Now you can take the query output to excel or to a temporary sql table to work on it, choice is yours. I used Excel to trim some information, because CPU names don't have a standard pattern to automatize parsing/filling.

11-01-2013 13-46-26

I duplicated the Name Column and deleted all information by Find/Replace to leave CPU Model alone.

11-01-2013 13-48-37

 3. Then visited Intel's ARK ( http://ark.intel.com/search/advanced/ ) website to obtain a detailed CPU list, and imported it to another sheet.

 11-01-2013 13-53-08

 4. Converted Launch dates to yyyy-mm-dd format, I written this to do that.
" DATE((CONCATENATE(20,RIGHT(B3,2))),(3*(MID(B3,2,1)))-2,1) "
  11-01-2013 13-56-45

 5. Copied values of Processor Number and CPU_Birth to the Sheet I created at first with data from the first query. (VLOOKUP caused me problem when I used it in multiple sheet)

I added a column next to Name and with " =VLOOKUP(H2,P:Q,2,FALSE) " formula, P:Q here is the two columns from ARK table.
  11-01-2013 14-01-24

 6. And added other necessary columns, also checked models names with eye and corrected names like M 430 to 430M etc. (Boring bit)
  11-01-2013 14-04-56

7. Rest is the inserting the table to LU_CPU, you can do that as you wish. You can concatenate columns and use with SQL's Insert Into.
   11-01-2013 14-09-47

This is lazy - non-creative way but very useful for future updates, as you can only add a new cpu and run it's command on SQL to add it. You can try to import from Excel file directly to LU_CPU too.
   SCCM Computer Age

For remaining CPUs don't have CPU_Birth information you can use the SCCM reporting to find machines by clicking the Not Available on the top of the report, search machine with the query below
 SELECT * FROM v_GS_PROCESSOR where SystemName0 = 'JK04-LT'

Add your findings to your table and find birth date manually on the web, ( I recommend http://www.cpu-world.com/ ) then insert you DB LU_CPU again.

You can also query LU_CPU table for NULL CPU_Births
SELECT DISTINCT [LU_CPU].Name 
From [LU_CPU] where CPU_Birth is NULL

then find the Launch date manually on the web and update the column via Name
UPDATE [LU_CPU]            
SET CPU_Birth = '2005-03-01'
Where Name = 'Intel(R) Celeron(R) M processor 1.50GHz'

Good luck !

Friday, 16 November 2012

How to disable password requirement in SCCM PXE Service Point

You set a password before and unset by removing the tick, but it still asks for a password, the problem here is removing the tick is not enough to disable password protection, so delete passwords first then remove the tick, apply settings and click ok.

Monday, 16 May 2011

SMS/SCCM Report - Access Denied / ASP 0178 : 80070005 Error

If you have got a SMS 2003 Server which runs on Windows Server 2003 with SP1 installed and if you gave access rights to a non-administrator user for SMS Reports , probably you are getting Error : Access is Denied error on IE. If you have already added this user to SMS Reporting Users local group on the SMS Server and if you are getting the error below
SMS_Rep_Error_2
Server object error 'ASP 0178 : 80070005'
Server.CreateObject Access Error
/SMSReporting.SiteCode/Report.asp, line 64
The call to Server.CreateObject failed while checking permissions. Access is denied to this object.
The reason is hardened DCOM settings in Windows 2003 SP1

To resolve this problem run Component Services which is under Administrative Tools and find the SMS_REPORTING_POINT as shown below

SMS_Rep_Error_3

Now select Security tab

SMS_Rep_Error_4

Select Customize option for Launch and Activation Permissions then select Edit

SMS_Rep_Error_5

Now add SMS_Reporting_Users local group and clear Local Launch option and select Allow for Local Activation, then aprrove all setting by click OK.

If you want to read more information about DCOM changes in Windows 2003 SP1 I recommend you to visit DCOM Security Enhancements site.

Saturday, 6 February 2010

SMS ile paket yaratma

Bu yazimda SMS ile nasil paket ve program yaratilabilecegine deginecegim, daha sonraki yazilarimda ise bu yaratacagimiz paketi nasil Deploy edecegimize yani yayacagimiza, raporlarini nasil cekebilecegimize de deginecegim.

Anlatimlari yaparken bol bol screen capture kullanarak adim adim neler yapacagimizida gormenizi diliyorum. Ornek paket olarak SMS Advanced Client'a ait oldukca onemli bir Hotfix olan KB937882 hotfix paketini kullanacagiz, eger SMS Advanced Client kullaniyor ve clientlarinizda yavaslama yasiyorsaniz ve bunun sebebi wmiprsve.exe nin task manager da gozlemlediginizde %50 ye varan islemci kullanimi ise sizlerede asagidaki SMS Advanced Client guncellemesini yuklemenizi oneririm.

1. Oncelikle SMS yonetim konsolunu acip Packages kismina gelmeniz gerekmekte, sizlere tavsiyem Packages altinda bit hiyerarsi yaratmaniz olacaktir, ornegin
Applications , Patches, gibi ana klasorler altinda Office, Windows, Security vb. klasorleri daha sonra yaratacaginiz paketler icin gerekli klasorleri belli bir duzende olmasi icin agac yapisinda duzenlemeniz sizin icin faydali olacaktir.

Paketler kismina gelerek Yeni Paket secenegini secerek Package Properties penceresini aciniz.

paketyaratma1

2. Gelecek olan Package Properties penceresinde General Tab inda Name kismina paketinizin ismini yaziniz, eger varsa Version, Publisher ve Language gibi bilgileri de yazmanizda fayda var. Eger bu bilgileri ayri ayri yazacaksaniz , yazarken Name kisminin kendiliginden olustugunu farkedeceksiniz. Comment kismina dilediginiz aciklamalari ve unutmamaniz gereken notlari yazabilirsiniz, unutmayin ki uzun surecte kullanacaginiz bir sistem olacaginizdan gerek dokumantasyon gerekse notlarinizi kaybetmemelisiniz.

paketyaratma2

3. Data Source Tab'ina geldiginizde This Package contains source files secenegini seciniz bu secenegi secerek program icin gerekli kaynak dosyalarin oldugunu belirtmis olacaksiniz, normalde bu secenek secilmemis gelir cunku SMS paket icin Distribution Point kullanmamaktadir henuz. Bu secimi yaparak SMS in bu paket icin Distribution Point kullanacagini da belirtmis olursunuz.

Devaminda Set Source Directory secenegini secerek paketinizin bulundugu klasoru tanimlamalisiniz. Bu klasor hem SMS sunucunuzun lokalindeki bir klasor olabilir hem de bir network share deki klasor olabilir, bu ornekte SMS Advanced Client Patch i servis masasi elemanlari direkt SMS Client klasorunden de elle istemcilere yuklediklerinden ve patch kendini buraya yerlestirdiginden Network Share secili. Ben sahsen yaymakta oldugum tum paketleri SMS uzerinde ayri bir diskte SMS teki folder yapisina paralel bir yapida tutmakta oldugumdan Always obtain files from source directory secenegini kullaniyorum, ancak sizin program dosyalarinizin kaynagi gecici bir sure icin var olacak ise Use a compressed copy of the source directory secenegini secerek SMS in dosyalari alip compress ederek saklamasini saglayabilirsiniz. Ayrica Distribution Point lerinizin belli araliklarla guncellenmesini istiyorsaniz bunu da bu pencerede ayarlamaniz mumkun. Ancak siz kaynak klasordeki uygulamanizi devamli guncellemiyorsaniz bu isleme gerek duymayacaksinizdir. Sunu da belirtmekte fayda var ayni isimdeki bir kurulum dosyasini guncellemek yerine dosya isimlerini versiyonlandirmanizi tavsiye ederim , aksi takdirde tek bir dosya icin farkli versiyon numaralari tutacak olan SMS daha sonra is dagitima geldiginde onceki bir dagitima ait bir uygulamayi bulamadim veya dagitmak istedigim dosya degismis diyebilir.

paketyaratma3

 

paketyaratma4

4. Data access kisminda ise paketin Distribution Store larda nasil saklanacagini belirlemekteyiz, eger paketi SMS in default olarak yarattigi paylasimda tutacaksak varsayilan seklinde asagidaki gozuken secim sizin icin yeterli olacaktir, ama siz Distribution Pointlerde ayri bir ag paylasim klasoru yaratilmasini istiyorsaniz onu Share Distribution Folder secenegi secerek belirtebilirsiniz de. Ornek : \DPsunucuismiPackagesPatches

paketyaratma5

5. Islemi onayladiktan sonra Paketinizin yaratilmis oldugunu goreceksiniz, diger tablardaki ayrintilara farkli yazilarda yer verecegimden su an atliyorum , ancak ben yazmadan once bu bilgilere ihtiyaciniz olursa bana email yazabilirsiniz.

paketyaratma6

6. Simdi yayacagimiz programcigi yaratmamiz gerekmekte bunun icin asagida gozuktugu gibi paketimizin icinde New Program secenegini sececegiz.

paketyaratma7

7. Program Properties penceremiz acilinca burada programimizin istemci tarafinda nasil ve hangi komutla calistirilacagini ayarlayacagiz, screen capture da net gorunmeyen kisimlari yazi ile yazacagim.

Command Line : bilgisi sizin programinizin client da calistirilirken kullanilacak olan komutu belirler, su an hazirlamaya calistigimiz patch icin bu komut su sekilde olacak,
msiexec.exe /p SMS2003AC-SP3-KB937882-x86.msp /q REINSTALL=ALL REINSTALLMODE=mous
msiexec ile ilgili parametreleri msiexec komutunu calistirarak gormeniz de mumkun.
Yukaridaki ornek te /p ile paketin install edilmesi , /q ile sessiz yapilmazi, mous ile parametrelerdeki m o u s paratmetrelerinin secili oldugu, yeniden kurulma icin tumu seceneginin secildigini gorebilirsiniz.

paketyaratma8

paketyaratma14

8. Bu ekran goruntusunde ise programin penceresinin hangi modda calisacagini Run kismindaki seceneklerden secebilirsiniz.
paketyaratma9

9. Programin kurulduktan sonra alinacak aksiyonlari secebilirsiniz, ornegin bilgisayarin yeniden baslatilmasi veya baslatilmamasi, kullaninicinin oturumunun sonlandirilmasi gibi. Ayrica Requirements kismindan gerek duyulan bos disk alani ve ne kadar sure kurulumun zaman asimina ugraycagini belirleyebilirsiniz. Hangi isletim sistemlerinde kurulumun calisacaginida ayarlayayabilirsiniz, bu ozellik cok faydalidir soyle ki, 32 ve 64 bit surumu olan bir uygulamayi bu secenegi konfigure ederek yaydiginizda 32bit istemcilerde sadece 32bit platformlar icin konfigure ettiginiz programin gozuktugunu veya calistigini goreceksiniz, aynisi 64bit icin de gecerli, boylece mimariye gore farkli koleksiyon yaratmadan basit bir sekilde yayma islemi yapabilirsiniz.

paketyaratma10 paketyaratma11

10. Environment tab'i ise programimizin hangi haklar ile hangi durumda calisacagini belirtmek icin kullandigimiz onemli bir tab Program can run : menusunde gorebileceginiz secenekler ile ;

  • Only when user is logged on : sadece kullanici oturum acmis durumda ise



  • Only when no user is logged on : sadece kullanici oturum acmamis durumda ise



  • Whether or not a user is logged on : kullanici oturum acmis durumda ise veya oturum acmamis durumda ise


programinizin hangi durumlarda kurulabilecegini secebilirsiniz, bu secenekler gercek cok onemli bir rolu ustleniyor cunku bu secenekler sayesinde programinizin oturum acmis kullanici haklari ile mi yoksa Software Installation Account kullanilarak mi, ya da Administrative haklarlarmi kurulacagini secebiliyorsunuz, yani dagitimi yaptiginiz istemcilerde kullanicilar lokal yonetim haklarina sahip degilseler bu secenekler sizin icin ktirik olacagi gibi uygulamanin Advertisement yerine Assignment yontemi ile dagitilmasi gerektiginde de onemli olacaktir.

Ornekte dagitmak icin tanimladigimiz uygulama bir patch oldugu icin burada Only when no user is logged on secenegini seciyoruz , boylece guncellemenin herhangi bir kullanici Windows'ta oturum acmadigi zamanlarda yuklenmesini istemis oluyoruz, halkar da ise Run with Administrative Rights secerek guncellemenin yonetici haklari ile istemcide calismasini saglamis oluyoruz.

paketyaratma12

11. Advanced tab'in da ise Run another program first secnegini kullanarak calistirmak uzere oldugumuz uygulamadan once calistirmak istedigimiz baska bir uygulama var ise onu tanimliyoruz. Tabii ki bu yine SMS uzerinde olusturdugumuz baska bir paket olmali , bu secenek te bazi durumlarda cok kullanisli olacaktir, ornegin kuracaginiz bir uygulamanin calismasi icin ayri bir programin kurulu olmasi gerektigi durumlarda veya hazirladiginiz custom bir msi paketini calistirmadan once calistirmak istediginiz bazi seyler var ise.

Ayrica When this program assigned to a computer secenegi ile egere programi assign yontemi ile yayiyorsaniz, o bilgisayar da bir keremi calissin gibi ayari menuden secebilirsiniz, ve Suppress program notifications secenegi ile de programin kurulurken bilgilendirme mesajlarini gostermemesini saglayabilirsiniz.

Ok ile program olusturma islemi tamamlandiginda artik bir kac kucuk ayara daha yaparak . yaymak icin Advertisement yaratmaniz gerekecek bir programiniz var.
paketyaratma13

Friday, 8 January 2010

SMS 2003 Policy sini Client'da cekip, uygulamak

Doug Eby'nin yazdigi asagidaki script araciligi ile SMS Advanced Client (versiyon 2004) yuklu bir istemcinin SMS sunucunuzdan son kullanici policy i cekerek uygulamasini hizlandirabilirsiniz, ozellikle test asamasinda cok faydali olacagindan tavsiye ederim.

On Error Resume Next

Dim objCPAppletMgr
Dim objClientActions
Dim objClientAction
Dim strActionName
strActionName="Request & Evaluate User Policy"
set objCPAppletMgr = CreateObject("CPApplet.CPAppletMgr")
set objClientActions=objCPAppletMgr.GetClientActions
For Each objClientAction In objClientActions
If objClientAction.Name = strActionName Then
objClientAction.PerformAction
End If
Next

Sunday, 20 May 2007

SMS'de Child Site Silmek

SMS 2003'de bir child site i kaldirmak istediginizde, Parent site tarafinda elle silmek istediginizde bu islemi basitce SMS\bin\i386 klasorunde bulunan preinst.exe araci ile gerceklestirebilirsiniz.

Ornegin
Parent site IST ve kaldirmak istediginiz child site ANK olsun
preinst.exe /DELSITE ANK IST komutu, ANK child siteini IST dan silecektir, komutu parent olan SMS sunucunuzda calistiriniz.

Bu arac ayni zamanda asagida listelenmis olan yararli olabilecek isleride yapmakta.

  • /DUMP [SiteCode]                   Dumps all site control images (or just the one specified) to the root of SMS drive

  • /SYNCPARENT                        Forward all subsites to parent site /STOPSITE Stops all the services at this site

  • /DELSITE SiteCode ParentCode       Remove a site from the database

  • /UPGRADE SiteCode                  Upgrade a secondary site of the current site

  • /CDUPGRADE SiteCode                Upgrade a secondary site of the current site using a local CD

  • /DEINSTALL SiteCode                Deinstall a secondary site of the current site

  • /SYNCCHILD SiteCode                Synchronize the child site

  • /DELJOB SiteCode                   Delete all jobs that are targeted to the site


Exporting Keys:

  • /KEYFORPARENT   Dump this site's public key into the file .CT4 at the root of the SMS drive.  Copy this file to the parent site's hman.box" inbox  (No t "hman.box\pubkey")

  • /KEYFORCHILD    Dump this site's public key into the file .CT5. Copy this file to the child site's "hman.box" inbox.

  • /CHILDKEYS      Dump this and all child site's public keys into the file .CT6. Copy this file to the parent site's "hman.box" inbox.

  • /PARENTKEYS     Dump this and all parent site's public keys into the file .CT7. Copy this file to the children site's "hman.box" inbox.