Difference between revisions of "Installation/Live Images/USB-Stick for OFW5"

From OpenFOAMWiki
(How to "burn" the ISO-Image onto an USB-Stick?)
(rearranged structure)
Line 15: Line 15:
 
# If you have already an ubuntu based operating system, you can use the tool "usb-creator-*"
 
# If you have already an ubuntu based operating system, you can use the tool "usb-creator-*"
 
# You can use also other software like http://www.linuxliveusb.com/ or http://unetbootin.sourceforge.net/ , but it is not guaranteed that these programs also create the '''persistent storage files''' or offer the language menu at the boot loader.
 
# You can use also other software like http://www.linuxliveusb.com/ or http://unetbootin.sourceforge.net/ , but it is not guaranteed that these programs also create the '''persistent storage files''' or offer the language menu at the boot loader.
* Boot the '''ISO-Image''' directly into a [https://wiki.ubuntu.com/Testing/VirtualBox VirtualBox] image
+
* Boot the '''ISO-Image''' directly into a [https://wiki.ubuntu.com/Testing/VirtualBox VirtualBox]
 
+
== OpenFOAM debian package structure ==
+
 
+
Three binary packages were build from the OpenFOAM source package
+
 
+
openfoam-dev-1.5:
+
* Binaries: /usr/lib/OpenFOAM-1.5-dev/{bin,applications/bin}
+
* Libraries: /usr/lib/OpenFOAM-1.5-dev/lib
+
* Documentation: /usr/share/doc/openfoam-dev-1.5
+
 
+
openfoam-dev-1.5-dev:
+
* Headers/Sources: /usr/lib/OpenFOAM-1.5-dev/{applications,src}
+
 
+
openfoam-dev-1.5-doc:
+
* Doxygen Doc: /usr/share/doc/openfoam-dev-1.5
+
  
 
== How to boot it? ==
 
== How to boot it? ==
Line 49: Line 34:
 
one-time boot from the USB device.
 
one-time boot from the USB device.
  
== How to boot in a VirtualBox? ==
+
== How to boot the '''USB-Stick''' in a VirtualBox? ==
  
 
This is for people who would like to run the USB-stick within their normal
 
This is for people who would like to run the USB-stick within their normal
Line 118: Line 103:
 
You may also resize '''without''' loosing your data
 
You may also resize '''without''' loosing your data
 
  resize2fs casper-rw 1024M
 
  resize2fs casper-rw 1024M
 +
 +
== OpenFOAM debian package structure ==
 +
 +
Three binary packages were build from the OpenFOAM source package
 +
 +
openfoam-dev-1.5:
 +
* Binaries: /usr/lib/OpenFOAM-1.5-dev/{bin,applications/bin}
 +
* Libraries: /usr/lib/OpenFOAM-1.5-dev/lib
 +
* Documentation: /usr/share/doc/openfoam-dev-1.5
 +
 +
openfoam-dev-1.5-dev:
 +
* Headers/Sources: /usr/lib/OpenFOAM-1.5-dev/{applications,src}
 +
 +
openfoam-dev-1.5-doc:
 +
* Doxygen Doc: /usr/share/doc/openfoam-dev-1.5

Revision as of 19:47, 10 October 2010

1 Where to get the ISO-Image?

The ISO-Image is available from the openfoam-extend site at sourceforge.net It contains a fully operational Linux operating system based on Kubuntu 10.04 LTS Lucid, and lots of useful CAE software including OpenFOAM (including pyFoam, cgnstools funkySetFields, groovyBC and simpleFunctionObjects), OpenCASCADE, CalculiX, ParaView with Takuya's OpenFOAM reader, enGrid, netgen, gmsh, blender, freecad, qcad, elmer, gerris, xfoil, bladedesigner, mittel, skv, octave, yacas and many more.

2 How to "burn" the ISO-Image onto an USB-Stick?

  • Burn the ISO-Image with the program of your choice to DVD.
  • Extract the ISO-Image onto a USB stick:
  1. If you have already an ubuntu based operating system, you can use the tool "usb-creator-*"
  2. You can use also other software like http://www.linuxliveusb.com/ or http://unetbootin.sourceforge.net/ , but it is not guaranteed that these programs also create the persistent storage files or offer the language menu at the boot loader.

3 How to boot it?

On "standard" laptops and PCs, things should be straight forward. Simply plug the USB-stick in and boot your machine. You will be asked for the language you prefer before you get to the kubuntu splash screen. Here select "Try Kubuntu without installing". Booting your machine from the USB-stick will not change your normal operating system in any way. Later, if you like, you have the option of installing Kubuntu and the included software on your computer permanently.

If the machine boots from harddisk and not' into Kubuntu, you will have to change the boot order in the BIOS. You can enter the BIOS by pressing a specific key during start-up (usually Del, F1, F2, F10, F12 - watch out for instructions on the screen during the boot procedure). In the BIOS, make sure that the USB device is booted in preference to anything else, or choose a one-time boot from the USB device.

4 How to boot the USB-Stick in a VirtualBox?

This is for people who would like to run the USB-stick within their normal operating system (Linux, Mac OS X, Windows). Here, we assume that the VirtualBox-software is installed on your computer and that you are familiar with the command line (the "Terminal Window") or at least know where to find it. You will also need to have administrative rights on your machine, ie. you are allowed to do "sudo somecommand".

The general procedure is as follows:

  • Plug in the USB-stick
  • Find out which device the USB-stick is
  • Create a raw disk file using "VBoxManage internalcommands createrawvmdk"
  • Create a new virtual machine in VirtualBox and attach the raw disk file that you just created
  • Boot the virtual machine. It should boot from the USB-stick

Caution: The command line parameters are only examples and have to be adapted to your system. When doing this on a Mac you won't be able to access the filesystem on the USB-stick from the Finder.

on Linux:

df
# /dev/sdb is the device with the USB-Stick
VBoxManage internalcommands createrawvmdk -filename ~/.VirtualBox/HardDisks/usb.vmdk -rawdisk /dev/sdb -register
# Sometimes you need to give special permissions ...
sudo chmod 666 /dev/sdb*
sudo chown `whoami` ~/.VirtualBox/HardDisks/usb.vdmk


on Mac OS X:

df
# Unmount the USB-stick at device /dev/disk2s1
sudo diskutil unmount /dev/disk2s1
VBoxManage internalcommands createrawvmdk -filename /Users/igarten/Desktop/stickBoot.vmdk -rawdisk /dev/disk2 -register
# The VirtualBox may complain that it cannot gain exclusive access to the disk 
# if the Finder mounted it again automatically. Redo the last two steps!

on Windows:

diskmgmt.msc
cd %programfiles%\sun\virtualbox
VBoxManage internalcommands createrawvmdk -filename "%USERPROFILE%"\.VirtualBox\VDI\usb.vmdk -rawdisk \\.\PhysicalDrive1 -register

5 How to activate VirtualBox Guest Additions?

In order to use the VirtualBox Guest Utils in the USB-Stick, when the USB-Stick is booted in a VirtualBox, you will need to do the following two steps by hand:

sudo apt-get install linux-headers-2.6.32-21-generic
sudo /etc/init.d/virtualbox-ose-guest-utils start

This is a known bug and is caused because of two different kernel's used during creation of the ISO image.

6 How to alter the keyboard layout?

The keyboard layout can be changed by clicking on the little US flag icon located at the bottom right of the desktop. More keyboard layouts can be access by clicking the right mouse button on it.

7 How to erase or resize the persistent storage?

The persistent storage is used to save your result on the USB-stick. Currently, 512 Mb are allocated in casper-rw for this purpose. In case you want to reset the persistent storage, simply do

dd if=/dev/zero of=casper-rw bs=1M count=512
mkfs.ext3 -F casper-rw

You may also resize without loosing your data

resize2fs casper-rw 1024M

8 OpenFOAM debian package structure

Three binary packages were build from the OpenFOAM source package

openfoam-dev-1.5:

  • Binaries: /usr/lib/OpenFOAM-1.5-dev/{bin,applications/bin}
  • Libraries: /usr/lib/OpenFOAM-1.5-dev/lib
  • Documentation: /usr/share/doc/openfoam-dev-1.5

openfoam-dev-1.5-dev:

  • Headers/Sources: /usr/lib/OpenFOAM-1.5-dev/{applications,src}

openfoam-dev-1.5-doc:

  • Doxygen Doc: /usr/share/doc/openfoam-dev-1.5