8.11. set

8.11.1. set host bootflags

rocks set host bootflags {host...} [flags=string]

Set the boot flags for a host. The boot flags will applied to the configuration file that a host uses to boot the running kernel. For example, if a node uses GRUB as its boot loader, the boot flags will part of the 'append' line.

arguments

host

Zero, one or more host names. If no host names are supplied, then the global bootflag will be set.

parameters

[flags=string]

The boot flags to set for the host.

examples

# rocks set host bootflags compute-0-0 flags="mem=1024M"

Apply the kernel boot flags "mem=1024M" to compute-0-0.

8.11.2. set host comment

rocks set host comment {host...} {comment} [comment=string]

Set the comment field for a list of hosts.

arguments

host

One or more host names.

comment

The string to assign to the comment field for each host.

parameters

[comment=string]

Can be used in place of the comment argument.

examples

# rocks set host comment compute-0-0 "Fast Node"

Sets the comment field to "Fast Node" for compute-0-0.

# rocks set host comment compute-0-0 compute-0-1 "Slow Node"

Sets the comment field to "Slow Node" for compute-0-0 and compute-0-1.

# rocks set host comment compute-0-0 compute-0-1 comment="Slow Node"

Same as above.

8.11.3. set host cpus

rocks set host cpus {host...} {cpus} [cpus=string]

Set the number of CPUs for a list of hosts.

arguments

host

One or more host names.

cpus

The number of CPUs to assign to each host.

parameters

[cpus=string]

Can be used in place of the cpus argument.

examples

# rocks set host cpus compute-0-0 2

Sets the CPU value to 2 for compute-0-0.

# rocks set host cpus compute-0-0 compute-0-1 4

Sets the CPU value to 4 for compute-0-0 and compute-0-1.

# rocks set host cpus compute-0-0 compute-0-1 cpus=4

Same as above.

8.11.4. set host interface gateway

rocks set host interface gateway {host...} {iface} {gateway} [gateway=string] [iface=string]

Sets the gateway address for a logical interface on one or more hosts.

arguments

host

One or more named hosts.

iface

Interface that should be updated. This may be a logical interface or the mac address of the interface.

gateway

The gateway address of the interface. Usually of the form nnn.nnn.nnn.nnn where n is a decimal digit. This format is not enforced. Use gateway=NULL to clear.

parameters

[gateway=string]

Can be used in place of the gateway argument.

[iface=string]

Can be used in place of the iface argument.

examples

# rocks set host interface gateway compute-0-0 eth1 192.168.0.1

Sets the gateway Address for the eth1 device on host compute-0-0.

# rocks set host interface gateway compute-0-0 eth1 ip=192.168.0.1

Same as above.

# rocks set host interface gateway compute-0-0 iface=eth1 gateway=192.168.0.1

Same as above.

# rocks set host interface gateway compute-0-0 iface=eth1 gateway=NULL

Clear the gateway entry for eth1 on host compute-0-0

related commands

add host

8.11.5. set host interface iface

rocks set host interface iface {host...} {mac} {iface} [iface=string] [mac=string]

Sets the logical interface of a mac address for particular hosts.

arguments

host

One or more named hosts.

mac

MAC address of the interface whose logical interface will be reassigned

iface

Logical interface.

parameters

[iface=string]

Can be used in place of the iface argument.

[mac=string]

Can be used in place of the mac argument.

examples

# rocks set host interface iface compute-0-0 00:0e:0c:a7:5d:ff eth1

Sets the logical interface of MAC address 00:0e:0c:a7:5d:ff to be eth1

# rocks set host interface iface compute-0-0 iface=eth1 mac=00:0e:0c:a7:5d:ff

Same as above.

related commands

add host

8.11.6. set host interface ip

rocks set host interface ip {host} {iface} {ip} [iface=string] [ip=string]

Sets the IP address for the named interface for one host.

arguments

host

Host name.

iface

Interface that should be updated. This may be a logical interface or the mac address of the interface.

ip

The IP address of the interface. Usually of the form nnn.nnn.nnn.nnn where n is a decimal digit. This format is not enforced. Use IP=NULL to clear.

parameters

[iface=string]

Can be used in place of the iface argument.

[ip=string]

Can be used in place of the ip argument.

examples

# rocks set host interface ip compute-0-0 eth1 192.168.0.10

Sets the IP Address for the eth1 device on host compute-0-0.

# rocks set host interface ip compute-0-0 iface=eth1 ip=192.168.0.10

Same as above.

8.11.7. set host interface mac

rocks set host interface mac {host} {iface} {mac} [iface=string] [mac=string]

Sets the mac address for named interface on host.

arguments

host

Host name.

iface

Interface that should be updated. This may be a logical interface or the mac address of the interface.

mac

The mac address of the interface. Usually of the form dd:dd:dd:dd:dd:dd where d is a hex digit. This format is not enforced. Use mac=NULL to clear the mac address.

parameters

[iface=string]

Can be used in place of the iface argument.

[mac=string]

Can be used in place of the mac argument.

examples

# rocks set host interface mac compute-0-0 eth1 00:0e:0c:a7:5d:ff

Sets the MAC Address for the eth1 device on host compute-0-0.

# rocks set host interface mac compute-0-0 iface=eth1 mac=00:0e:0c:a7:5d:ff

Same as above.

# rocks set host interface mac compute-0-0 iface=eth1 mac=NULL

clears the mac address from the database

related commands

add host

8.11.8. set host interface module

rocks set host interface module {host...} {iface} {module} [iface=string] [module=string]

Sets the device module for a named interface. On Linux this will get translated to an entry in /etc/modprobe.conf.

arguments

host

One or more hosts.

iface

Interface that should be updated. This may be a logical interface or the MAC address of the interface.

module

The software device module of interface. Use module=NULL to clear.

parameters

[iface=string]

Can be used in place of the iface argument.

[module=string]

Can be used in place of the module argument.

examples

# rocks set host interface module compute-0-0 eth1 e1000

Sets the device module for eth1 to be e1000 on host compute-0-0.

# rocks set host interface gateway compute-0-0 iface=eth1 module=e1000

Same as above.

# rocks set host interface gateway compute-0-0 iface=eth1 module=NULL

Clear the module entry.

related commands

add host

8.11.9. set host interface name

rocks set host interface name {host} {iface} {name} [iface=string] [name=string]

Sets the logical name of a network interface on a particular host. This is usually a fully qualified domain name.

arguments

host

Host name.

iface

Interface that should be updated. This may be a logical interface or the MAC address of the interface.

name

Name of this interface (e.g. hostname.external.net) This is usually of the form, hostname.domain, but is not enforced. Use name=NULL to clear.

parameters

[iface=string]

Can be used in place of the iface argument.

[name=string]

Can be used in place of the name argument.

examples

# rocks set host interface name compute-0-0 eth1 c0-0.external.net

Sets the name for the eth1 device on host compute-0-0 to c0-0.external.net

# rocks set host interface name compute-0-0 iface=eth1 name=c0-0.external.net

Same as above.

related commands

add host

8.11.10. set host interface subnet

rocks set host interface subnet {host...} {iface} {subnet} [iface=string] [subnet=string]

Sets the subnet for named interface on one of more hosts.

arguments

host

One or more named hosts.

iface

Interface that should be updated. This may be a logical interface or the MAC address of the interface.

subnet

The subnet address of the interface. This is a named subnet and must be listable by the command 'rocks list subnet'.

parameters

[iface=string]

Can be used in place of the iface argument.

[subnet=string]

Can be used in place of the subnet argument.

examples

# rocks set host interface subnet compute-0-0 eth1 public

Sets eth1 to be on the public subnet.

# rocks set host interface mac compute-0-0 iface=eth1 subnet=public

Same as above.

related commands

add host

8.11.11. set host interface vlan

rocks set host interface vlan {host...} {iface} {vlanid} [iface=string] [vlanid=string]

Sets the VLAN ID for an interface on one of more hosts.

arguments

host

One or more named hosts.

iface

Interface that should be updated. This may be a logical interface or the mac address of the interface.

vlanid

The VLAN ID that should be updated. This must be an integer and the pair 'subnet/vlanid' must be defined in the VLANs table.

parameters

[iface=string]

Can be used in place of the iface argument.

[vlanid=string]

Can be used in place of the vlanid argument.

examples

# rocks set host interface vlan compute-0-0-0 eth0 2

Sets compute-0-0-0's private interface to VLAN ID 2.

# rocks set host interface vlan compute-0-0-0 subnet=eth0 vlanid=2

Same as above.

related commands

add host

8.11.12. set host membership

rocks set host membership {host...} {membership} [membership=string]

Set the membership for hosts.

arguments

host

One or more host names.

membership

The membership to assign to each host.

parameters

[membership=string]

Can be used in place of the membership argument.

examples

# rocks set host membership "NAS Appliance" nas-0-0

Sets the membership to 'NAS Appliance' for nas-0-0.

# rocks set host membership "NAS Appliance" membership=nas-0-0

Same as above.

# rocks set host membership Compute

Sets the membership to 'Compute' for all known hosts.

8.11.13. set host pxeboot

rocks set host pxeboot {host...} [action=string]

Set a pxeaction for a host. This action defines what configuration is sent back to a host the next time it PXE boots.

arguments

host

One or more host names.

parameters

[action=string]

The label name for the pxeaction. For a list of pxeactions, execute: 'rocks list host pxeaction'. If no action is supplied, then only the configuration file for the list of hosts will be rewritten.

examples

# rocks set host pxeboot compute-0-0 action=os

Set the 'os' pxeaction for compute-0-0.

8.11.14. set host rack

rocks set host rack {host...} {rack} [rack=string]

Set the rack number for a list of hosts.

arguments

host

One or more host names.

rack

The rack number to assign to each host.

parameters

[rack=string]

Can be used in place of rack argument.

examples

# rocks set host rack compute-2-0 2

Set the rack number to 2 for compute-2-0.

# rocks set host rack compute-0-0 compute-0-1 0

Set the rack number to 0 for compute-0-0 and compute-0-1.

# rocks set host rack compute-0-0 compute-0-1 rack=0

Same as above.

8.11.15. set host rank

rocks set host rank {host...} {rank} [rank=string]

Set the rank number for a list of hosts.

arguments

host

One or more host names.

rank

The rank number to assign to each host.

parameters

[rank=string]

Can be used in place of rank argument.

examples

# rocks set host rank compute-0-2 2

Set the rank number to 2 for compute-0-2.

# rocks set host rank compute-0-0 compute-1-0 0

Set the rank number to 0 for compute-0-0 and compute-1-0.

# rocks set host rank compute-0-0 compute-1-0 rank=0

Same as above.

8.11.16. set network netmask

rocks set network netmask {network...} {netmask} [netmask=string]

Sets the network mask for one or more named networks .

arguments

network

One or more named networks that should have the defined netmask.

netmask

Netmask that named networks should have.

parameters

[netmask=string]

Can be used in place of netmask argument.

examples

# rocks set network netmask optiputer 255.255.255.0

Sets the netmask for the "optiputer" network to a class-c address space.

# rocks set network netmask optiputer netmask=255.255.255.0

Same as above.

# rocks set network netmask optiputer cavewave 255.255.0.0

Sets the netmask for the "optiputer" and "cavewave" networks to a class-b address space.

8.11.17. set network subnet

rocks set network subnet {network...} {subnet} [subnet=string]

Sets the subnet for one or more named networks.

arguments

network

One or more named networks that should have the defined subnet.

subnet

Subnet that named networks should have.

parameters

[subnet=string]

Can be used in place of subnet argument.

examples

# rocks set network subnet optiputer 132.239.51.0

Sets the "optiputer" subnet address to 132.239.51.0.

# rocks set network subnet optiputer subnet=132.239.51.0

Same as above.

# rocks set network subnet optiputer cavewave 67.58.32.0

Sets both the "optiputer" and "cavewave" subnet addresses to the same value of 67.58.32.0.

8.11.18. set var

rocks set var {service} {component} {value} [appliance=string] [component=string] [service=string] [value=string]

Set variables in the Rocks key/value database. Variables are defined as quad of (Appliance, Service, Component, Value). Within a node XML file, values can be retrieved as <var name="Service_Component"/>.

arguments

service

Defines the service name. e.g., service=Kickstart.

component

Defines the component name. e.g., component=PublicDNS.

value

Defines the value for the variable.

parameters

[appliance=string]

If supplied, restricts to the named appliance. See 'rocks list appliance' for a listing of appliances.

[component=string]

Can be used in place of component argument.

[service=string]

Can be used in place of service argument.

[value=string]

Can be used in place of value argument.

examples

# rocks set var service=Condor component=Master value=localhost

Set the variable name <var name="Condor_Master"/> to 'localhost'.

# rocks set var service=Condor component=Master value=localhost appliance=compute

Set the variable name <var name="Condor_Master"/> to 'localhost' and associate it with only compute appliances.