Thursday 5 November 2009

Using messenger service to send Console messages

Yep sometimes we need to do that to inform the user that we are going to take over their machine (VNC etc). However the problem is on our imaged machines the messenger service is not running by default. So I got this script together. It will ask you for the remote IP address, ask your for the message to send, start remote messenger service, send the messege, then stop the remote messenger service.

Ofcourse you need admin rights on the remote machine. and also your local messenger service should be running as well.

here is the script:
just copy and paste save as a .bat file and run.




cd \
cls

REM sc start messenger

cls

REM ===========================================
REM ============Nadeem Sarwar==================

REM Script to send console message to specified
REM terminal. User inputs IP address and message
REM Will Only work if you have admin rights on
REM target PC.

REM ===========================================



@ECHO OFF

ECHO.
ECHO.
ECHO.

REM :BEGIN

echo Enter Target IP Address:
ECHO.

set /p Address=

ECHO.
ECHO.
ECHO.

echo Enter Message to Send:
ECHO.

set /p Message=


sc \\%Address% config messenger start= demand
sc \\%Address% start messenger

PAUSE

NET SEND %Address% "%Message%"


sc \\%Address% config messenger start= disabled

sc \\%Address% stop messenger

REM sc stop messenger

PAUSE




REM =======================================

Sunday 16 March 2008

Installing esx 3i on usb stick

From http://communities.vmware.com/message/825686#825686



ESX Server 3i - USB flash drive boot possible!
Dec 21, 2007 11:55 AM

I successfully booted ESX Server 3i from a USB flash drive on a machine with no local disks attached. It´s unsupported, but it works!
Requirements:
1 GB USB flash drive
WinImage
IZArc Of course you can use your favourite tools and larger USB flash drives, but 1 GB is enough space for the boot image.
Perform the following steps to create a bootable ESX Server 3i USB flash drive:
Download ESX Server 3i Installable ISO
Extract INSTALL.TGZ from the root directory of the ISO image using an IZArc
Extract /usr/lib/vmware/installer/VMware-VMvisor-big-3.5.0-67921.i386.dd.bz2 from INSTALL.TGZ using IZArc
Extract VMware-VMvisor-big-3.5.0-67921.i386.dd from VMware-VMvisor-big-3.5.0-67921.i386.dd.bz2 using IZArc
Attach the USB flash drive and make sure you no longer need the data on it
Use WinImage to transfer VMware-VMvisor-big-3.5.0-67921.i386.dd to the USB flash drive
Disk->Restore Virtual Hard Disk image on physical drive...
Select the USB flash drive (Warning: If you select the wrong disk you will lose data!)
Select the image file VMware-VMvisor-big-3.5.0-67921.i386.dd
Confirm the warning message
Wait for the transfer to complete
Unplug the USB flash drive (Warning: If you forget to unplug the flash drive from the PC you might lose the data on your hard drives the next time you boot!)
Attach the USB flash drive to the machine you want to boot (Warning: If ESX Server 3i recognizes local drives, you might lose the data on it, so make sure you don´t need it anymore or unplug all hard drives!)
Turn the machine on and make sure the USB flash drive is selected as boot device
Watch ESX Server 3i boot
Configure
Enjoy!
I cannot be held responsible for any damage or loss of data this procedure might cause.

Cheap ESX 3i Setup

I've been using vmware server and workstation product for quite some time now, and have been very happy with them.

Currently my setup is a Windows 2003 server running Exchange 2003. On top of that I havevmware server which manages two virtual machines. One is a Windows 2003 Server runningSQL and one is Linux running the Excellent ISPConfig. ( This is a home setup and is only setup for testing, learning and experimenting purposes )

As the company I work for is currently looking to go all the way to virtualization, I thought it was a good time to get a bit more into it. So I started looking around to the available options. After reading around, I thought I'd give ESX a try. However the hardware requirements are a bit tough. No way could I afford to get a SCSI setup in the house (the wife would kill me!). However there was hope of using sata drives. So my quest to find something cheap that could run ESXbegan.

First of all I got myself ESX 3i on a USB stick using the procedure described herehttp://nsansari.blogspot.com/2008/03/installing-esx-3i-on-usb-stick.html . Then I started using the USB on every PC I could find just to see if it will work. First of all it was the turn of my home PC. This is a 3 1/2 year old PC. The proc is a athlon 2600+ and the motherboard is A7n8x-d. Needless to say it failed to boot and would hang half way through the boot process. After that I tried several other PCs. At work we use dell PCs so I tried those but could not get it to work. Theoptiplex 745, 755, SX270 all failed. The 745 and 755 would boot but ESX would not recognise either the sata drives or the NIC.

Finally I've found the ideal cheap desktop that is all compatible with ESX. Its the HP Compaq d530 sff (small form factor). At £75 I got hold of two of these the spec is 2.8ghz P4, 2 sata controllers, 4 slots for memory (max 4gb). ESX installs without a hitch recognizes all the hardware, NIC, drives and all.