Go Vegetarian

Go Vegetarian

Thursday, March 19, 2009

Moving Virtual Box Machines

This document does not show the way to make a Virtual Box configuration see a Virtual Box machine that was copied from somewhere. What I propose(temporarily) is to rename the current Virtual Box directory(.VirtualBox) and then copy the files from the Virtual Box machines where you did the copy. At this time, why would you run 2 machines at the same time ?
  • make a copy of the current Virtual Box
  • start Virtual Box
accept the license agreement
enter your name and email address
  • exit VirtualBox
  • copy the files
rudy@catalogne:/tank/VirtualBox$ ls
compreg.dat HardDisks Machines VirtualBox.xml xpti.dat

tank is a ZFS filesystem on an external disk(from where the VM was copied).

rudy@catalogne:/tank/VirtualBox$ cp -pr HardDisks /export/home/rudy/.VirtualBox
rudy@catalogne:/tank/VirtualBox$ cp -pr Machines /export/home/rudy/.VirtualBox
rudy@catalogne:/tank/VirtualBox$ cp -pr VirtualBox.xml /export/home/rudy/.VirtualBox/
  • start Virtual Box(new VM copied)
rudy@catalogne:~$ VirtualBox

That should make the trick ! You have now access to the VM that was moved !


-Rudy-

Virtual Box on OpenSolaris 2008.11

  • Download the software archive
In my case it is OpenSolaris. But there are others OS supported !
Download
  • Extract the software
% gunzip VirtualBox-2.1.4-42893-SunOS.tar.gz
% tar xvf VirtualBox-2.1.4-42893-SunOS.tar
  • Install Virtual Box
2 packages have to be installed

VirtualBoxKern-2.1.4-SunOS-r42893.pkg
VirtualBox-2.1.4-SunOS-r42893.pkg

as root

# pkgadd -d VirtualBoxKern-2.1.4-SunOS-r42893.pkg
# pkgadd -d VirtualBox-2.1.4-SunOS-r42893.pkg

  • start Virtual Box
rudy@catalogne:~$ which VirtualBox
/usr/bin/VirtualBox

In foreground

rudy@catalogne:~$ VirtualBox


-Rudy-

Wednesday, March 18, 2009

cacao - the basics

Cacao stands for Common Agent Container, i.e. a Container for deploying OSNode agents that help managing the OSNode. You can view it as collection of MBeans available to manage something on this OSNode.

-bash-3.00# cacaoadm stop

-bash-3.00# cacaoadm status
default instance is DISABLED at system startup.
default instance is not running.

-bash-3.00# cacaoadm start

-bash-3.00# cacaoadm status
default instance is DISABLED at system startup.
Smf monitoring process:
7130
7131
Uptime: 0 day(s), 0:0

Sun Java Web Console - the basics

-bash-3.00# smcwebserver stop
Shutting down Sun Java(TM) Web Console Version 3.1 ...
The console is stopped

-bash-3.00# smcwebserver start
Starting Sun Java(TM) Web Console Version 3.1 ...
The console is running

-bash-3.00# netstat -an | grep -i listen | grep 6789
*.6789 *.* 0 0 49152 0 LISTEN

https://hostname.domainname:6789 to open the Web Console.

-Rudy-

X11 and DISPLAY and ssh

Ever wonder what is the way to run xclock from a zone in Solaris 10 running in Virtual Box on OpenSolaris 2008.11 ?

Very easy !

I am logged in OpenSolaris 2008.11 as rudy

rudy:~$ id
uid=101(rudy) gid=10(staff) groups=10(staff)

rudy:~$ echo $DISPLAY
:0.0

rudy:~$ uname -a
SunOS XXX 5.11 snv_101b i86pc i386 i86pc Solaris

OpenSolaris
GZ : 192.168.1.100

VB : Solaris 10
GZ : 192.168.1.102 sol10.vegworld.org
LZ : 192.168.1.104 europortal.vegworld.org

Enter the LZ on Solaris 10(VB) as ANY server. There is no difference !

rudy@dhcp-ebru03-133-226:~$ ssh -l root -X europortal.vegworld.org
Password: XXX
Last login: Wed Mar 18 11:58:26 2009 from 192.168.1.100
Sun Microsystems Inc. SunOS 5.10 Generic January 2005

-bash-3.00# hostname
europortal

-bash-3.00# uname -a
SunOS europortal 5.10 Generic_137138-09 i86pc i386 i86pc

-bash-3.00# echo $DISPLAY
localhost:10.0

-bash-3.00# /usr/openwin/bin/xclock


Don't try to assign DISPLAY yourself... It should work but it is a lot better through ssl -X ! I was "rudy" on OpenSolaris and I do a "ssh" as the user I want on Solaris... I mean don't enter Solaris as rudy(ssh -l rudy) and the su - and assign DISPLAY... You enter the host from a terminal where X11 is working and ssh will initialize your DISPLAY... The fact that it is a LZ does not have any influence here, it is the same logic...

-Rudy-

Thursday, March 12, 2009

Flash on OpenSolaris 2008.11


  • download the plugin from the Adobe website


Valid as of March 12, 2009
http://www.adobe.com/shockwave/download/alternates

flash_player_10_solaris_x86.tar.bz2



  • uncompress and untar


rudy@catalogne:~/Download$ bunzip2 flash_player_10_solaris_x86.tar.bz2
rudy@catalogne:~/Download$ tar xvf flash_player_10_solaris_x86.tar
flash_player_10_solaris_r22_87_x86/
flash_player_10_solaris_r22_87_x86/libflashplayer.so



  • make the direcoty plugin(if it is the first time installation)

mkdir -p $HOME/.mozilla/plugins

for example
mkdir -p /export/home/rudy/.mozilla/plugins




  • copy the library

rudy@catalogne:~/Download$ cp flash_player_10_solaris_r22_87_x86/libflashplayer.so $HOME/.mozilla/plugins/

for example
rudy@catalogne:~/Download$ cp flash_player_10_solaris_r22_87_x86/libflashplayer.so /export/home/rudy/.mozilla/plugins/




  • restart Firefox


That's all for today !

-Rudy-

Sunday, March 08, 2009

X11 in Solaris zones - OpenSolaris 2008.11

From https://www.opensolaris.org/jive/thread.jspa?threadID=82847&tstart=0

Hot stuff :

The following command allows access from remote clients.
svccfg -s svc:/application/x11/x11-server setprop options/tcp_listen = true
Then restart the X server
pkill -HUP Xorg

Or

Turn on tcp listen
svccfg -s svc:/application/x11/x11-server setprop options/tcp_listen = true
Then restart the X server
svcadm refresh svc:/application/x11/x11-server
svcadm restart svc:/application/x11/x11-server

By the way, this post is from a local zone running firefox with the DISPLAY set to the global zone.