Get List of Smart Servers

To get a list of smart servers, use the following request:

1
2
GET /smart_servers.xml
GET /smart_servers.json

XML Request Example

1
curl -i -X GET -H 'Accept: application/xml' -H 'Content-type: application/xml' -u user:userpass --url http://onapp.test/smart_servers.xml

JSON Request Example

1
curl -i -X GET -H 'Accept: application/xml' -H 'Content-type: application/xml' -u user:userpass --url http://onapp.test/smart_servers.json

XML Output Example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<smart_server>
  <add_to_marketplace nil="true"/>
  <admin_note nil="true"/>
  <allow_resize_without_reboot type="boolean">false</allow_resize_without_reboot>
  <allowed_hot_migrate type="boolean">false</allowed_hot_migrate>
  <allowed_swap type="boolean">true</allowed_swap>
  <booted type="boolean">true</booted>
  <built type="boolean">true</built>
  <cpu_shares type="integer">1</cpu_shares>
  <cpus type="integer">1</cpus>
  <created_at type="datetime">2013-07-25T12:11:09+03:00</created_at>
  <customer_network_id nil="true"/>
  <deleted_at nil="true"/>
  <edge_server_type nil="true"/>
  <enable_autoscale type="boolean">false</enable_autoscale>
  <enable_monitis type="boolean">false</enable_monitis>
  <firewall_notrack type="boolean">false</firewall_notrack>
  <hostname>test</hostname>
  <hypervisor_id type="integer">67</hypervisor_id>
  <id type="integer">103</id>
  <identifier>on8n97e0g0gfci</identifier>
  <initial_root_password>qweasdzxc</initial_root_password>
  <initial_root_password_encrypted type="boolean">false</initial_root_password_encrypted>
  <label>TT</label>
  <local_remote_access_ip_address>83.170.81.132</local_remote_access_ip_address>
  <local_remote_access_port type="integer">5900</local_remote_access_port>
  <locked type="boolean">false</locked>
  <memory type="integer">384</memory>
  <min_disk_size type="integer">5</min_disk_size>
  <note nil="true"/>
  <operating_system>linux</operating_system>
  <operating_system_distro>rhel</operating_system_distro>
  <preferred_hvs type="array">
    <fixnum type="integer">1</fixnum>
  </preferred_hvs>
  <recovery_mode nil="true">
  <remote_access_password>M8eZXy9zJQhP</remote_access_password>
  <service_password nil="true"/>
  <state>new</state>
  <storage_server_type nil="true"/>
  <strict_virtual_machine_id nil="true"/>
  <suspended type="boolean">false</suspended>
  <template_id type="integer">2</template_id>
  <template_label>CentOS 6.4 x64 1.3</template_label>
  <time_zone>Atlantic Time (Canada)</time_zone>
  <updated_at type="datetime">2013-07-25T12:14:15+03:00</updated_at>
  <user_id type="integer">6</user_id>
  <vip nil="true"/>
  <xen_id type="integer">2</xen_id>
  <ip_addresses type="array">
    <ip_address>
      <address>83.170.81.146</address>
      <broadcast>83.170.81.159</broadcast>
      <created_at type="datetime">2013-06-11T10:19:46+03:00</created_at>
      <customer_network_id nil="true"/>
      <disallowed_primary type="boolean">false</disallowed_primary>
      <gateway>83.170.81.145</gateway>
      <hypervisor_id nil="true"/>
      <id type="integer">3</id>
      <ip_address_pool_id nil="true"/>
      <network_address>83.170.81.144</network_address>
      <network_id type="integer">1</network_id>
      <pxe type="boolean">false</pxe>
      <updated_at type="datetime">2013-07-25T12:11:09+03:00</updated_at>
      <user_id nil="true"/>
      <free type="boolean">false</free>
      <netmask>255.255.255.240</netmask>
    </ip_address>
  </ip_addresses>
  <monthly_bandwidth_used>0</monthly_bandwidth_used>
  <total_disk_size type="integer">6</total_disk_size>
  <price_per_hour type="decimal">0.0</price_per_hour>
  <price_per_hour_powered_off type="decimal">0.0</price_per_hour_powered_off>
  <cpu_priority type="integer">1</cpu_priority>
</smart_server>
<smart_server>
....
</smart_server>
<smart_server>
...
</smart_server>

Where:

  • add_to_marketplace — empty for smart servers; used for edge servers only.
  • admin_note — an optional note of the administrator.
  • allow_resize_without_reboottrue if resize without reboot is possible; otherwise, false.
  • allowed_hot_migratetrue if the template, on which the smart server is based, supports hot migration; otherwise, false.
  • allowed_swaptrue if swap disk is allowed (depends on the template the smart server is based on); otherwise, false.
  • bootedtrue if the smart server is running; otherwise, false.
  • builttrue if the smart server is built; otherwise, false.
  • cpu_shares — CPU priority in percents.
  • cpus — the number of allocated CPU cores.
  • created_at — the date in the [YYYY][MM][DD]T[hh][mm][ss]Z format.
  • customer_network_id — ID of a customer network.
  • deleted_at — time when the smart server was deleted.
  • edge_server_typetrue if this is the edge server.
  • enable_autoscaletrue if autoscaling is allowed for this smart server.
  • enable_monitis — deprecated attribute to be removed in upcoming release.
  • firewall_notracktrue if the NOTRACK rule is set in iptables.
  • hostname — the name of your host.
  • hypervisor_id — the ID of the compute resource used by this smart server.
  • id — the smart server ID.
  • identifier — the smart server identifier.
  • initial_root_password — the smart server root password.
  • initial_root_password_encryptedtrue if the root password is encrypted; otherwise, false.
  • label — the smart server label.
  • local_remote_access_ip_address — IP address used for remote access.
  • local_remote_access_port — the port ID used for console access.
  • lockedtrue if the smart server is locked; otherwise, false.
  • memory — the RAM size allocated to this smart server.
  • min_disk_size — the minimum disk size required to build a smart server from a specified template.
  • note — an optional reminder for this smart server made by a user account.
  • operating_system — operating system used by the smart server.
  • operating_system_distro — the distribution of the OS from which this smart server is built.
  • preferred_hvs — the array of preferable compute resources based on compute zone that meet some smart server configuration settings.
  • recovery_modetrue if recovery mode allowed. Otherwise, false.
  • remote_access_password — the password for the remote access.
  • service_password — service account password.
  • state — parameter reserved for future use.
  • storage_server_typetrue if this is a storage server.
  • strict_virtual_machine_id — the ID of a virtual server that will never reside on the same compute resource with this smart server.
  • suspendedtrue if the smart server is suspended; otherwise, false.
  • template_id — the ID of the template the smart server is based on.
  • template_label — the name of the template from which this smart server is built.
  • time_zone — the time zone set for the smart server. This parameter is applicable only to Windows smart servers.
    Currently, the time zone is set at the Compute resource side only. Therefore, users need to set the target time zone inside a Windows smart server manually. Setting correct time zone at the Compute resource side helps to keep correct time inside a smart server after starting it if time synchronization is not completed for some reason.
  • updated_at — the date when the smart server was updated in the [YYYY][MM][DD]T[hh][mm][ss]Z format.
  • user_id — the ID of a user assigned to this smart server.
  • viptrue if the smart server has VIP status (gives migration priority).
  • xen_id — the smart server ID set by the virtualization engine.
  • ip_addresses — an array of ip addresses with their details assigned to this smart server.
    • address — IP address.
    • broadcast — broadcast address.
    • created_at — the date in the [YYYY][MM][DD]T[hh][mm][ss]Z format.
    • customer_network_id — the ID of the customer VLAN the IP address belongs to.
    • disallowed_primarytrue if not allowed to be used as primary; otherwise, false.
    • gateway — gateway address.
    • hypervisor_id — the ID of a compute resource the IP address is associated with.
    • id — the ID of the IP address.
    • ip_address_pool_id — ID of the IP address pool the IP address is associated with.
    • network_address — the address of the network.
    • network_id — the ID of the network.
    • pxetrue if this address can be used for cloudbooting a compute resource.
    • updated_at — the date in the [YYYY][MM][DD]T[hh][mm][ss]Z format.
    • user_id — the ID of the user this IP address is assigned to.
    • freetrue if free; otherwise, false.
    • netmask — netmask for the IP address.
  • monthly_bandwidth_used — smart server monthly bandwidth in KB.
  • total_disk_size — the total disk size in GB of all disks assigned to smart server.
  • price_per_hour — server’s price per hour.
  • price_per_hour_powered_off — price per hour when server is powered off.
  • support_incremental_backups1 if smart server supports incremental backups, and 0 if it does not.
  • cpu_priority — this is a new parameter reserved for future use; currently it has the same value as cpu_shares parameter.