Linux / Unix Tips and Tricks

This blog contains Linux / Unix Tips and Tricks, collected during my work as a Unix System Administrator.
They are here for my own reference, but they might help you as well !

VMware Server: Managing virtual machines from the command line

len | 15 December, 2008 16:54

Sometimes it's handy to be able to manage your Virtual Machines on the Command Line.
So if you are stuck in traffic and only have an SSH login available on your mobile phone,
here are the commands to manage your Virtual Machine:

Listing configured Virtual Machines:

$ vmware-cmd -l
/var/lib/vmware/Virtual Machines/Server-01/Windows 2000 Server.vmx
/var/lib/vmware/Virtual Machines/Server-01/RedHat5.vmx
 

Get the state of a Virtual Machine:

$ vmware-cmd "/var/lib/vmware/Virtual Machines/Server-01/RedHat5.vmx" getstate

Start (or resume) a Virtual Machine:

$ vmware-cmd "/var/lib/vmware/Virtual Machines/Server-01/RedHat5.vmx" start

Stop a Virtual Machine:

$ vmware-cmd "/var/lib/vmware/Virtual Machines/Server-01/RedHat5.vmx" stop

Reset a Virtual Machine:

$ vmware-cmd "/var/lib/vmware/Virtual Machines/Server-01/RedHat5.vmx" reset

 

Setting your X environment

len | 15 December, 2008 14:15

Most Unix sysadmins are hardcore Command Line gurus. However, sometimes you may need to run a graphical application on Unix.
The graphical environment on Unix is called the X Window System (or X or X11). Unlike most other graphical systems, X is designed to be used over the network. (More)

Replacing text in multiple files

len | 15 December, 2008 07:42

Here's a perl oneliner that does text search & replace over multiple files. Make sure you create a backup before using it !

 (More)

 
Accessible and Valid XHTML 1.0 Strict and CSS
Powered by LifeType - Design by BalearWeb