Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Contact Us
Online Help
Domain Status
Man Pages

Virtual Servers

Topology Map

Server Agreement
Year 2038

USA Flag



Man Pages
ECLAT-MKTAG(1) Eclat User Reference ECLAT-MKTAG(1)

eclat-mktag, eclat-create-tags - create or replace tags for a resource

eclat mktag [-a ID] [-i ID] [-r [MAP:]ID] [-s ID] [-v ID] [-T FILE] [--ami ID] [--instance ID] [--resource-id [MAP:]ID] [--volume ID] [--snapshot ID] [--from-file FILE] [ID]... TAG[=VAL]...

eclat mktag --help

This command creates or replaces one or more tags for given resources. Tags are specified by their names. If a tag name is followed by an equals sign, the characters following that sign are stored in this tag's value. Otherwise an empty value is assigned to it.

The resources to create the tags for are supplied with one of the options. At least one resource designation must be present.

If ID mapping is enabled (see the section MAPS in eclat(1)), all options except -r (--resource-id) translate their arguments using corresponding maps (see OPTIONS below). The -r (--resource-id) option uses no map by default, unless the map name is specified explicitly before the ID.

-a, --ami ID
Creates tags for the given image. In resource translation mode, uses the map ImageId.
-i, --instance ID
Creates tags for the given instance. In resource translation mode, uses the map InstanceId.
-r, --resource-id [MAP:]ID
Creates tags for the EC2 resource identified by ID. If optional MAP prefix is supplied and resource translation mode is enabled, this option will use the MAP to translate ID into AWS resource identifier.
-s, --snapshot ID
Creates tags for the given snapshot. In resource translation mode, uses the map SnapshotId.
-T, --from-file FILE
Reads tags from FILE or from the standard input, if FILE is -. Empty lines and lines beginning with # are ignored. Non-empty lines must contain either a tag name alone, or a tag name and the corresponding value, separated by an equals sign. If the value is enclosed in double quotes, these will be removed and any escaped characters within the value translated to their corresponding equivalents using shell rules (e.g. \" becomes ", etc). See example 2 below.
-v, --volume ID
Creates tags for the given volume. In resource translation mode, uses the map VolumeId.

By default the command does not output anything, unless an error occurs in which case the error diagnostics is printed on the standard error.

Create two tags for an instance:

eclat mktag -i i-12345678 Name=Webserver test


This command creates two tags for instance i-12345678: the tag Name with the value Webserver and tag test with empty value.

Copy tags between instances:

eclat -e 'if (.DescribeTagsResponse)
            for (var in .DescribeTagsResponse.tagSet.item)
              print(var.key,"=",var.value,"\n");' \
      lstag resource-id=i-12345678 |
 eclat mktag -i i-fe2345ed -T -


This example uses the lstag command to obtain tags from the instance i-12345678 and a custom format to represent them in a form suitable as input to mktag. The obtained data are piped to the mktag command which is instructed to read them from the standard input using -T -.

eclat(1), eclat-rmtag(1), eclat-lstag(1).

Sergey Poznyakoff

Report bugs to <>.

Copyright © 2012-2018 Sergey Poznyakoff
License GPLv3+: GNU GPL version 3 or later <>
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

January 26, 2015 ECLAT

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.