12 May, 2010

IP address convert to full numbers

Hi,

don't know about you but I keep a record of all of my IP on a spreadsheet, did you try to sort them ? - it will sort the 1 and then the 100 numbers because it sees them as test and not numbers.

Created a cool small spreadsheet that helps you convert all your IP to a structure of xxx.xxx.xxx.xxx format.
The GoogleDoc Link

Enjoy.

(By the way, it will work with xxx.xxx at at the start - my all network is 192.168 so...)

11 May, 2010

Delete all snapshots in a SR (XenServer)

Hi,

Wrote a little script to centrally delete all snapshots from a SR on XenServer.
I noticed that although you delete a snapshot an entry still remains on the SR.
Since I have 1 main SR I wrote a script to delete all of them before the backup process begins (later when it will be ready I'll post it).

================================================
echo === deleting old snapshot ===
echo Start at:
echo %date% - %time%
:start
C:\Progra~1\Citrix\XenCenter\xe.exe -s [Pool Master / Server IP] -u [user] -pw [password] vdi-list is-a-snapshot=true sr-uuid=[sr uuid] --minimal > vdi.txt
for /f "tokens=1 delims=," %%G in (vdi.txt) do (
if [%%G] EQU [] goto end
C:\Progra~1\Citrix\XenCenter\xe.exe -s [Pool Master / Server IP] -u [user] -pw [password] vdi-destroy uuid=%%G
echo.
goto start
)

:end
=================================================

and it works great...

06 May, 2010

Resizing a SR on XENServer 5.5

I needed to re-size an SR in XenServer, for some reason all the articles (including the one on citrix web site) did not work.

Finally I did the following steps and it started working...

1. Shut down all virtual machines on the SR.
2. Get the SR UUID with #xe sr-list name-lable=[SR anme]
3. Extend the Volume on the Storage
4. In CLI Run #iscsiadm -m node –R (to reinitialize the iSCSI) on the pool master
5. In the CLI run #pvresize --setphysicalvolumesize 40G /dev/sda1 (when replacing the amount of Gb and the location of the SR)
6. Run in the CLI #xe sr-scan uuid=[uuid]
7. Run #pvs to be sure the new size is here
8. Power on the Virtual Machines.



Simple, no ?

VMWare workstation virtual NIC has no access

Hi,

Had a problem with VMWare Workstation for some time now, started a vm and the nic could not connect to the network, only a restart to my laptop did the trick.

Took me a while to find that this will happen after a hibernation, looked a bit more and found the solution:


=====================================
net stop vmnetbridge
net start vmnetbridge
pause
=====================================

you can run it even if the VM is running and it will fix the NIC problem.

05 May, 2010

Microsoft Online Services Signin application will not resolve the user

Had a problem for a very long time now.
I moved few of my china users from my internal exchange server to use cloud based email provided by Microsoft.

The sign-in application should create a redirection of the auto-discovery service to the online service but it seems that they have a bug in the program, If I use the registry override for use with Closest DC (KB319206) the autodiscover override does not work. (I deployed it due to my multi-site environment).

HKEY_CURRENT_USER\Software\Microsoft\Exchange\Exchange Provider\

Changed the "Closest DC" dward to “0” and all is OK.

29 April, 2010

Symantec Backup Exec remote agent manual update

Hi,

I had problems with remote updating BackupExec remote Agent, some update went OK but others just failed.
Symantec will not give an easy way to manually deploy those updates and when they multiply it's a lot of work...

I found an easy way to it, follow this steps:

1. copy the following folder localy: "\\[BEServerName]\c$\Program Files\Symantec\Backup Exec\Agents\RAWS32\Updates" (RAWS32 should be replaced with RAWSX64 depends on your OS)

2. create a CMD file in that directory and copy the following to the file:

rem ===== this will list all BE Agent updates in dates order and will apply them ====
dir /OD /B *.msp > files.txt

for /f %%A in (files.txt) do (msiexec /update %%A /passive /norestart)

rem ==== the end (easy no ?) =====

3. run the CMD file...

08 March, 2010

Notepad++ run the script with cscript

Hi,

I needed a way to run a vbs script i was working on using Notepad++ and I all the time had to go to a cmd screen and run it.
Found a cool way to ease my pain, in the "Run" menu there is an option to save a command. Just type the following and a CMD window will open and will run the vbs in cscript.

=================================================================
cmd /k cd /d "$(CURRENT_DIRECTORY)" && Cscript "$(FILE_NAME)"
=================================================================

if you would like to leave the window open each time use the following:
=================================================================
cmd /c cd /d "$(CURRENT_DIRECTORY)" && Cscript "$(FILE_NAME)" && pause
=================================================================

Bye...