Statistics
| Branch: | Tag: | Revision:

root / snf-image-host / common.sh.in @ master

History | View | Annotate | Download (13.2 kB)

# Date Author Comment
971a3e68 02/04/2014 11:08 am Nikos Skalkotos

Add new HELPER_MEMORY parameter

This can be used to overwrite the size of the virtual RAM that will
be given to the helper VM

4d88c6cf 01/24/2014 05:43 pm Nikos Skalkotos

Fix bug in import/export regarding some API params

Fix a bug where API params like CONFIG_URL or IMG_PASSWORD where
checked and used by scripts other that `create' (e.g. `import' and
`export'). This may lead to errors. The CONFIG_URL may not be valid
after the image creation

4a4e861a 10/17/2013 03:18 pm Nikos Skalkotos

Fix some debug messages

e88a9e49 10/04/2013 01:18 pm Nikos Skalkotos

Allow /'s in local back-end IDs

Add extra code to check if the image path ends up being outside the
IMAGE_DIR directory

0a982a6d 10/04/2013 12:58 pm Nikos Skalkotos

Change the local-backend identifier to local://

This used to be file://

29f35803 09/20/2013 06:53 pm Nikos Skalkotos

Add version check in snf-image-update-helper

9728e789 09/20/2013 04:55 pm Nikos Skalkotos

Remove HELPER_URL from defaults.in & common.sh.in

The variable should only exist in snf-image-update-helper. If the
user wants to overwrite the value, he should create it in
/etc/default/snf-image-update-helper

fc8cbf90 09/09/2013 03:18 pm Nikos Skalkotos

Rename create-fixed helper script to create-helper

Rename snf-image-create-fixed-helper script to snf-image-create-helper.
Also remove the command that will create a tar archive of the helper
files under /tmp

6fe48058 08/30/2013 05:03 pm Nikos Skalkotos

Add code to create a fixed appliance archive

When you run snf-image-create-fixed-helper an archive of the fixed
helper is created under /tmp

34e34e80 08/30/2013 02:18 pm Nikos Skalkotos

Reorganize the helper image creation scripts

Move the old snf-image-update-helper to snf-image-create-fixed-helper
and make the new snf-image-update-helper download a fixed helper image
specified by the HELPER_URL variable.

f4ded3c0 03/11/2013 02:02 pm Nikos Skalkotos

Fix a bug introduced in 7f008dd4ddae1ab883b9833234

The check for supported hypervisors should only executed by scripts
that comply to the ganeti api.

7f008dd4 03/11/2013 12:39 pm Nikos Skalkotos

Check for unsupported hypervisors

eb5554b1 03/06/2013 08:43 pm Nikos Skalkotos

Add some missing "exit 1" statements

The script should always exit with an error status after a log_error
command

70d434ff 03/01/2013 04:52 pm Nikos Skalkotos

Remove dublicated code in {kvm,xen}-common.sh

Add check_helper_rc and check_helper_result functions called by
kvm-common.sh and xen-common.sh.

c15aef04 02/21/2013 07:07 pm Nikos Skalkotos

Make sure the xen helper VM always terminates

d509231b 02/20/2013 07:49 pm Nikos Skalkotos

Make monitoring work with xen

  • Add custom vif script for the helper VM
  • Cleanup helper code
f7a4021c 02/07/2013 06:04 pm Nikos Skalkotos

Merge branch 'master' into xen

Conflicts:
snf-image-helper/common.sh
snf-image-host/Makefile.am
snf-image-host/common.sh.in
snf-image-host/create
snf-image-host/defaults

aa185eca 02/06/2013 05:30 pm Nikos Skalkotos

Add new XEN_BRIDGE variable.

This can be used to configure the bridge on which the helper's VM
nic will be attached when using XEN.

56e4f945 01/27/2013 07:56 pm Nikos Skalkotos

Remove deprecated network_backend_support check

49bc26a3 01/27/2013 07:47 pm Nikos Skalkotos

Change some default values

Change HELPER_SIZE to 600 and HELPER_SOFT_TIMEOUT to 120

81d3d555 01/21/2013 06:38 pm Nikos Skalkotos

Make the size of the helper VM image configurable

Add a new HELPER_SIZE variable for this purpose. Default size is
hardcoded to 400MB

68d58128 01/17/2013 01:11 pm Nikos Skalkotos

Cleanup variables and ./configure options

Remove:
HELPER_CACHE_DIR
HELPER_IMG
HELPER_KERNEL
HELPER_INITRD
TIMELIMIT
Add:
TIMEOUT

In configure, remove:
--enable-network-backend
--with-helper-img
--with-helper-kernel
--with-helper-initrd

9dfb9730 12/05/2012 04:51 pm Christos Stavrakakis

Make pithcat work with pithosmap:// URLs

Modify pithcat to be able to parse and work with URLs of the form:
`pithosmap://hash/size' which are neeed for archipelagos.

995a47c9 12/02/2012 11:14 am Nikos Skalkotos

Code cleanup

Make sure local variables are defined as local before they get assigned.
Having variables get defined and assigned in one line like this:

local var=foo

can sometimes cause problems. For example, this line:

local var=$(false)

will return 0 and the script will not fail if set -x is defined.

317d9f27 12/01/2012 11:38 pm Nikos Skalkotos

Make snf-image fail if config_url isn't accessible

d3265cf9 11/30/2012 03:29 pm Nikos Skalkotos

Do not install a local helper package by default

snf-image-update-helper will only install a pkg retrieved from the
apt unless -p option is specified.

aa5d3807 11/29/2012 02:58 pm Nikos Skalkotos

Remove old do_debootstrap function from common.sh

5d21c514 11/28/2012 07:09 pm Nikos Skalkotos

Add new version_consistency_check in configure

This can be used to enable or disable the version check between
snf-image-host and snf-image-helper at the end of the update-helper
script.

2187080b 11/28/2012 04:22 pm Nikos Skalkotos

Remove caching

Using package caches to create the helper image is dangerous now that
snf-image-helper is automatically retrieved.

5197de03 11/28/2012 02:27 pm Nikos Skalkotos

Add apt preferences dir for multistrap

The files hosted in this directory will be added in the
/etc/apt/preferences.d directory of the helper image before multistrap
runs.

bec9a804 10/22/2012 04:19 pm Nikos Skalkotos

Change default error msg in monitoring

240c2f10 10/22/2012 04:15 pm Nikos Skalkotos

Seperate error messages from monitoring messages

Do not send through the monitor pipe the error messages. They may
contain internal sensitive information. Create a new report_error
function for sending errors through the monitoring pipe.

Conflicts:
snf-image-host/create...

53a5929f 10/05/2012 10:18 am Nikos Skalkotos

Use a seperated dir for update-helper cache files

By default this directory is $(LOCALSTATEDIR)/cache/snf-image/helper

24f704d1 10/02/2012 06:53 pm Dimitris Aragiorgis

Use socat rather than screen for xm commands

Signed-off-by: Dimitris Aragiorgis <>

1ea8db72 09/29/2012 05:46 am Dimitris Aragiorgis

Use socat to dump helper messages in case of xen

Helper gets a dummy interface and communication between helper
and host is done via socat STDIO INTERFACE:eth0/vif$helperid.0

Signed-off-by: Dimitris Aragiorgis <>

e9413eab 09/28/2012 09:41 pm Dimitris Aragiorgis

Make use of XenStore to export SUCCESS msg

Signed-off-by: Dimitris Aragiorgis <>

72052003 09/28/2012 08:17 pm Dimitris Aragiorgis

Xen support

Support launching helper domain on top of Xen hypervisor under PV mode.

Helper VM becomes hypervisor aware by passing hypervisor=$HYPERVISOR
in the kernel command line and thus acts accordingly (which logging
devices to use, what disk/floppy devices to expect, etc)...

621a9a34 09/27/2012 07:34 pm Nikos Skalkotos

Replace debootstrap with multistrap

multistrap is more flexible allows as to define more that one
repository to retrieve packages from.

603c05f7 09/24/2012 12:05 pm Nikos Skalkotos

Use UTC when calling date command

ded30adf 09/21/2012 03:42 pm Nikos Skalkotos

Add IMAGE_DEBUG variable

if this is set, then snf-image will run in debug mode.

305f3086 09/14/2012 03:22 pm Nikos Skalkotos

Remove enable-network-backend flag from configure

The curl dependency is not optional any more.

3707aa73 09/13/2012 05:25 pm Nikos Skalkotos

Add new config_url os parameter

This url points to a json file that contains the value for other
OS parameters. Using this file we can pass parameters to snf-image
without writting them in Ganeti's config.data. This is
useful, for 2 reasons:
  • Privacy: We don't want the password to appear in the Ganeti config...
3b9cb520 09/12/2012 01:42 pm Nikos Skalkotos

Fix an identation error in common.sh.in

42ed2a70 08/29/2012 06:32 pm Nikos Skalkotos

Add support for null image backend type

This backend type can be used if we want snf-image to configure the
VM disk without first copying an image to it. This is useful for
cases were the VM disk is already populated before snf-image runs.

453ab965 07/23/2012 04:22 pm Nikos Skalkotos

Create a dedicated host monitoring program

This program is used to output info and error messages from the host.

8847e13c 07/23/2012 12:19 pm Nikos Skalkotos

Add stderr-monitor.py for monitoring stderr

This programm will get the stderr file as input and it will create a
json image-error msg

faff1fc9 07/20/2012 06:42 pm Nikos Skalkotos

Add new image-info monitoring msg type

snf-image-host can output info messages using the log_info function.

d8ca112b 07/19/2012 04:54 pm Nikos Skalkotos

Remove redundant location field in error messages

73dddd66 07/16/2012 02:53 pm Nikos Skalkotos

Fix some error messages

70a1fdc1 07/16/2012 02:47 pm Nikos Skalkotos

Fix a bug in error reporting json string

A `{' was missing in the beginning of the json string of the message
with type `error'.

f32664b2 07/16/2012 11:51 am Nikos Skalkotos

Add helper-monitor.py program

This program transforms raw helper monitor messages into json strings
under very strict rules. This reduces security concerns since the
helper VM output cannot be trusted.

a50a2bff 05/29/2012 06:37 pm Nikos Skalkotos

cleanup! cleanup! cleanup! cleanup!

  • Change the monitor message type names once again (hope this is
    the final version)
  • Pass -u (unbuffered) to sed to retain the actual output order in
    the log file
  • Fix a bug in helper code where the starting `{' was missing from...
7836baff 05/29/2012 04:55 pm Nikos Skalkotos

Abandon timelimit program in favor of timeout

The latter is part of gnu coreutils.

87d1bf2e 05/28/2012 05:20 pm Nikos Skalkotos

Cleanup monitoring code pt2

  • Remove id field in the notifications (what was left)
  • Make copy-monitor.py use the already opened pipe file descriptor
    instead of reopening the file
  • Let bash choose the file descriptor instead of specifying one when...
df1c62e2 05/25/2012 05:57 pm Nikos Skalkotos

Cleanup monitoring code

  • Add nanoseconds field in timestamp
  • Remove id field in the notifications
  • Fix cleanup code
9c76962d 05/24/2012 12:36 pm Nikos Skalkotos

Add monitoring event for errors in create

e51d19e9 05/23/2012 03:24 pm Nikos Skalkotos

Remove dead code in common.sh

ebba4508 05/23/2012 02:27 pm Nikos Skalkotos

Add mechanism for monitoring snf-image events

Add a utility initially written by vkoukis for monitoring the image
copy. This utility outputs notifications to a named pipe. An external
program can get informed for the image deployment progress by reading
the notifications from this named pipe. The monitoring mechanism...

643d7283 05/17/2012 04:35 pm Nikos Skalkotos

Remove enable-pithos-support option

snf-image will detect at runtime if pithos backend is installed

8689d50f 05/17/2012 03:31 pm Nikos Skalkotos

Add mechanism for using a custom unattend.xml

snf-image-helper by default uses it's own version of unattend.xml file,
but if UNATTEND variable is specified then it will use the one provided
by snf-image-host.

b1fef76e 05/11/2012 11:33 am Nikos Skalkotos

Remove the progress-monitor-support flag

snf-image-host will make use the external progress monitor program
if the PROGRESS_MONITOR variable is not empty. This way progress
monitor can be enable or disabled by just overwriting the aforementioned
variable in the defaults file.

d259b27c 05/02/2012 04:06 pm Nikos Skalkotos

Create a package list file after every debootstrap

This file is used to check if the cache file contains every package
defined in HELPER_EXTRA_PKGS.

b126203e 03/30/2012 07:25 pm Nikos Skalkotos

Add support for logical partitions

Now FixPartitionTable task can enlarge logical partitions

448a829f 03/29/2012 05:04 pm Nikos Skalkotos

In update-helper ask before using a cache file

  • If -y is not specified and a cache file is found, ask the user before
    using it.
  • "Fix" the -c option's behaviour. With this commit, if -c is applied,
    the system will use the provided cache file if present and will do a...
198f8249 12/15/2011 05:46 pm Nikos Skalkotos

Fix default PITHOS_DATA value

d71f59e9 12/12/2011 03:34 pm Nikos Skalkotos

Clean up code and support pithos-hosted images

  • Drop "custom" image format type. The same functionality is provided
    by network-hosted images.
  • Images with id that starts with "http:", "https:", "ftp:", "ftps:"
    are considered to be network hosted and are downloaded via cURL....
725a0f88 12/01/2011 05:02 pm Nikos Skalkotos

Remove the ARCH field from the image name

baf8926c 11/23/2011 12:07 pm Nikos Skalkotos

Fix a syntax error introduced in the commit 78e9f

78e9f209 11/22/2011 06:05 pm Nikos Skalkotos

Make image properties optional

Image properties should be an optional argument. In any other case
snf-image does not retail backward compatibility.

7e5d635b 11/18/2011 03:48 pm Nikos Skalkotos

Fix copyright and license notices throughout

66840d7a 11/18/2011 02:54 pm Nikos Skalkotos

Fix a bug in host's floppy exported variables

The bug was triggered when a variable contained new lines

ec728294 11/15/2011 05:07 pm Nikos Skalkotos

Disable RDP connection during windows setup

cb489189 11/11/2011 06:23 pm Nikos Skalkotos

Abandon wget.

Since curl is needed to find remote file sizes, lets do the whole
downloading with curl.

14de44dc 11/11/2011 11:06 am Nikos Skalkotos

Fix custom images support

  • Add code to compute the remote filesize
  • Check for wget and curl in the configuration phase
e0ae744d 11/08/2011 03:29 pm Nikos Skalkotos

Add parted as a default pkgs in HELPER_EXTRA_PKGS

e16d4331 11/08/2011 11:23 am Constantinos Venetsanopoulos

Add `img_properties` OS parameter

The img_properties parameter is a json dictionary
(json.dumps format) which contains all the necessary
properties that will be used to customize the new image.

23996b5d 10/31/2011 05:02 pm Nikos Skalkotos

Beautify common.sh.in

5a31f7ef 10/20/2011 11:31 am Nikos Skalkotos

Fix issues #1531 #1532 #1533

bad5ca1f 10/10/2011 09:43 am Nikos Skalkotos

Mass cleanup and some bug fixing

  • Make all "local" variables lowercase.
  • Move HELPER_EXTRA_PKGS from snf-image-update-helper to common.sh
  • Protect all variables from spaces and other special chars
  • Remove extra X's from mktemp template names (only 6 are supported)....
3b66e07b 10/06/2011 05:52 pm Nikos Skalkotos

Reduce helper's timeout limits

5cbb15b9 10/06/2011 05:49 pm Nikos Skalkotos

Make helper boot from a temporary image snapshot

9aac6898 10/06/2011 11:10 am Nikos Skalkotos

Fix a bug in common.sh

test returned !0 causing problems to the script!

d51a95a8 10/05/2011 04:43 pm Nikos Skalkotos

Add script to construct a new helper VM image

The scripts runs debootstrap and creates a new disk image

edf5dd1a 10/05/2011 01:49 pm Constantinos Venetsanopoulos

Rename host to snf-image-host

Also add ChangeLog and COPYING info