Thursday, May 17, 2012

ISA 2006 vs Cache Log vs liveupdate.liveupdatesymantec.com

So removing the ISA proxy @ work noticed while investigating who is still using the 'old' proxy.  Enable  reporting and the daily report for cache use always says "Information not available"

After thinking about  and then googling for the solution to this, didnt get any joy.

Logically it has to be what is set in the web proxy logging options. I remove a heap reduce the data in logs.
there is a options called 'cache information' , enabled that stuff now just need to wait till tomorrow to see if I have WIN.

reviewed the live log notice that' symatec live updates'   liveupdate.liveupdatesymantec.com are loggin as  cache information = 0x106
http://msdn.microsoft.com/en-us/library/aa503433.aspx


0x00000002 Request includes the IF-MODIFIED-SINCE header.
0x00000004 Request includes one of these headers: CACHE-CONTROL:NO-CACHE or PRAGMA:NO-CACHE.
0x00000100 Request includes the CACHE-CONTROL: MAX-AGE, or CACHE-CONTROL: MAX-STALE, or CACHE-CONTROL: MIN-FRESH header.

not so cool.

Think I need to force caching of this website. off to investigate


Tuesday, April 24, 2012

Powershell - Citrix


load citrix ps adding  :  Add-PSSnapin Citrix.XenApp.Commands

Get the number of sessions in the farm:

$FarmRaw = Get-XAFarm
$FarmRaw.SessionCount

Get the number of sessions per app:

$Sessions = Get-XASession -BrowserName "Notepad"
$SessTotal = $sessions.count

Tuesday, April 3, 2012

Powershell : Active Directory user update and rename in 1 line

# tested and used on powershell v3
# 1 Grab username\password
# 2 Grab all users without admin in the name
# 3  For each user
#     a  Modify display name to include (admin)
#     b  Rename AD object to include (admin)
#
#It’s setup to run in a single line because I can
#
$ninja=Get-Credential ; get-aduser -filter 'name -notlike "*Admin*"' -searchbase 'OU=Security - Administrator Accounts,DC=Coolkids,DC=local' -Properties DistinguishedName | %{set-aduser -credential $ninja $_ -displayname ($_.name + " (Admin)"); rename-ADObject $_.DistinguishedName -credential $ninja -NewName ($_.name + " (Admin)")} 



expanded

#get the admin passwords

$ninja=Get-Credential 
#
get-aduser -filter 'name -notlike "*Admin*"' -searchbase 'OU=Security - Administrator Accounts,DC=Coolkids,DC=local' -Properties DistinguishedName | %{set-aduser -credential $ninja $_ -displayname ($_.name + " (Admin)"); rename-ADObject $_.DistinguishedName -credential $ninja -NewName ($_.name + " (Admin)")} 

Wednesday, March 28, 2012

vhd install windows 8


after downloading the window8 (and converting to usb stick )
Insert and reboot
Follow the installation wizard until you get to the point where to select the partition
Hit Shift + F10 to bring up a Dos prompt window.
Type diskpart and press enter. Then,
DISKPART:>create vdisk file=C:\vhd\win8preview.vhd maximum=20000
DISKPART:>select vdisk file=C:\vhd\win8preview.vhd
DISKPART:>attach vdisk
exit and refresh
choose the new disk, ignore any errors about unable to boot

Sunday, March 18, 2012

batch ffmpeg convert mp4 mp3

Not my best FOR loop, quick and nasty.
Had a stack of mp4 videos to convert for the ride home.

mp4mp3.cmd <batch file>

for /f "delims=." %%a in ('dir *.mp4 /b') do G:\music\ffmpeg.exe -i "%%a.mp4" -vn -ar 44100 -ac 2 -ab 192000 -f mp3 "%%a.mp3"

stop that pesky Startup Repair


bcdedit /set {default} bootstatuspolicy ignoreallfailures

Thursday, March 15, 2012

Java vs Terminal Server 2003 - CLSID


Users were experiencing a Red Cross for the applet, yet my administrative account was able to load the applet.

Looks like java or the installation process for java is not writing all the registry keys to HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Wow6432Node\CLSID\{CAFECA-00xx…..

In IE, Java has a catch all applet version – which will always work (aka the latest version)
<OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93


But most java call specific versions of java (for example).
<OBJECT classid=”clsid:CAFEEFAC-0015-0000-0013-ABCDEFFEDCBA


The server(s) for some reason didn't have all the keys in classes root, where compared to my windows 7 desktop.

I believe the install for some reason is writing the keys to HKCU instead of HKLM \classes...etc.

So fix is to add all the version to HKEY_LOCAL_MACHINE\SOFTWARE\Classes

http://pastebin.com/YhmwPTq7 contains my fix for 1.6u24 version


btw, Monitoring the registry when tick/untick the “use next generation java” in the java control panel, it just write all the entries to HKCU.