Friday, 22 October 2010

access windows shared from ubuntu/linux

  1. install smbfs
    1. $sudo apt-get install smbfs
  2. use ‘mount’ to mount the file share
    1. for mount you need to create a local folder that will be the mount point for example create a folder test under /media
    2. then mount the share using
      1. $sudo mount -t smbfs -o username=myusername //192.168.0.10/sharename /media/test
      2. myusername – is a valid username on the windows machine
      3. the ip address is the ip of the windows machine
      4. sharename is the name given to the share on the windows machine
      5. This will prompt you for the passwor d- the password for myusername on the windows machine
      6. on successful password you will be able to see the contents of the sharedfolder under /media/test
      7. Note: if you this is the first time you are using sudo in this shell session or if sudo has timed out there will be two password prompts first for the sudo next for the share mount. you could avoid this by doing $sudo -v before doing the sudo mount
  3. to umount
    1. $sudo umount /media/test

Monday, 18 October 2010

creating a xen windows vm

Create the image of the windows server installation cd using:

#dd if=/dev/cdrom of=/tmp/windowssrv2k3.iso

0. In your workstation terminal type:
#xhost
#ssh -X user@systemname

1. first create a partition for the disk using lvm command:

#lvcreate --size 50G --name winshared01_root XenVolGroup01

2. Create a configuration directory /xen/winshared01

3. virt-install --prompt

4. edit the configuration file by changing "boot" from 'c' to 'd'. Also change "sdl" value from 0 to 1 and also "vnc" value from 1 to 0 and adding cdrom as to point to windows image

5. then start the domU using
#xm create winshared01

6. Follow the instructions in windows installation screen

To delete volume group:

lvremove -f /dev/XenVolGroup01/winshared01_root