ffx


Usage: ffx [-c <config...>] [-e <env>] [-t <target>] [-T <timeout>] [<command>] [<args>] Fuchsia's developer tool

Options:


-c, --config override default configuration -e, --env override default environment settings -t, --target apply operations across single or multiple targets -T, --timeout override default proxy timeout --help display usage information

Commands:


net View and manage target network configuration assembly Assemble images component Discover and manage components config View and switch default and user configurations cts Build and run CTS tests. daemon Interact with/control the ffx daemon debug Start a debugging session. doctor Run common checks for the ffx tool and host environment driver Support driver development workflows efi Manipulate efi partition emu Start and manage Fuchsia emulators flutter Interact with Flutter components on the target. inspect Query component nodes exposed via the Inspect API overnet Interact with the Overnet mesh package Create and publish Fuchsia packages platform Manage platform build prerequisites profile Profile run-time information from various subsystems repository Inspect and manage package repositories scrutiny Audit the security of Fuchsia sdk Modify or query the installed SDKs self-test Execute the ffx self-test (e2e) suite session Control the session starnix Control starnix processes target Interact with a target device or emulator trace Interact with the tracing subsystem version Print out ffx tool and daemon versions test Run test suite

assembly


Usage: ffx assembly <command> [<args>] Assemble images

Options:


--help display usage information

Commands:


vbmeta vbmeta operations image perform the assembly of images extract extract information from an image.

extract


Usage: ffx assembly extract --outdir <outdir> --zbi <zbi> extract information from an image.

Options:


--outdir the directory to write extracted artifacts to. --zbi the zircon boot image in ZBI format, usually named fuchsia.zbi. --help display usage information

image


Usage: ffx assembly image --product <product> --board <board> --outdir <outdir> [--gendir <gendir>] [--full] perform the assembly of images

Options:


--product the configuration file that specifies the packages, binaries, and settings specific to the product being assembled. --board the configuration file that specifies the packages, binaries, and settings specific to the board being assembled. --outdir the directory to write assembled outputs to. --gendir the directory to write generated intermediate files to. --full run all assembly steps, even though they haven't yet been fully integrated. This is a temporary argument. --help display usage information

vbmeta


Usage: ffx assembly vbmeta <command> [<args>] vbmeta operations

Options:


--help display usage information

Commands:


sign create and sign a vbmeta image.

sign


Usage: ffx assembly vbmeta sign --name <name> --image-path <image-path> --key <key> --key-metadata <key-metadata> [--salt-file <salt-file>] [--additional-descriptor <additional-descriptor...>] --output <output> [--salt-outfile <salt-outfile>] create and sign a vbmeta image.

Options:


--name the name of the image being signed --image-path the path to the image to sign --key the path to the PEM file containing the signing key to use. --key-metadata the path to the metadata file for the signing key. --salt-file the file containing salt for the vbmeta signing operation. This is only to be used as part of testing the vbmeta signing operation, and must be a path to a file that contains a 64-char hex string of bytes. --additional-descriptor descriptors for additional partitions to include, as paths to json files --output the output file to write the vbmeta image to. --salt-outfile the output file to write the salt value used to --help display usage information

component


Usage: ffx component <command> [<args>] Discover and manage components

Options:


--help display usage information

Commands:


bind Binds to a component instance, causing it to start create Creates a component instance, adding it to the component topology data Manages persistent data storage of components destroy Destroys a component instance, removing it from the component topology knock Connects to a capability described by a given selector list Lists all components in the component topology run Creates and binds to a component instance run-legacy Runs a legacy (CMX) component instance on the target select Lists component instances matching a selector show Shows detailed information about a component instance stop Stops a component instance

bind


Usage: ffx component bind <moniker> Binds to a component instance, causing it to start

Options:


--help display usage information Examples: To bind to the component instance designated by the moniker `/core/brightness_manager`: $ ffx component bind /core/brightness_manager Notes: To learn more about running components, visit https://fuchsia.dev/fuchsia-src/development/components/run

create


Usage: ffx component create <moniker> <url> Creates a component instance, adding it to the component topology

Options:


--help display usage information Examples: To create a component instance designated by the moniker `/core/ffx-laboratory:foo`: $ ffx component create /core/ffx-laboratory:foo fuchsia-pkg://fuchsia.com/hello-world#meta/hello-world-rust.cm Notes: To learn more about running components, visit https://fuchsia.dev/fuchsia-src/development/components/run

data


Usage: ffx component data <command> [<args>] Manages persistent data storage of components

Options:


--help display usage information

Commands:


copy Copy files to/from a component's persistent data storage. If the file already exists at the destination it is overwritten. list List the contents of a component's persistent data storage. make-directory Create a new directory in a component's persistent data storage. If the directory already exists, this operation is a no-op.

copy


Usage: ffx component data copy <source_path> <destination_path> Copy files to/from a component's persistent data storage. If the file already exists at the destination it is overwritten.

Options:


--help display usage information Examples: To copy `credentials.json` from the current working directory on the host to the `settings` directory of a component's persistent data storage: $ ffx component data copy ./credentials.json 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520::settings/credentials.json Note: 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520 is the instance ID of the component whose persistent data storage is being accessed. To learn about component instance IDs, visit https://fuchsia.dev/fuchsia-src/development/components/component_id_index

list


Usage: ffx component data list <path> List the contents of a component's persistent data storage.

Options:


--help display usage information Examples: To list the contents of the `settings` directory in a component's persistent data storage: $ ffx component data list 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520::settings To list the contents of the root directory of a component's persistent data storage: $ ffx component data list 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520::/ Note: 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520 is the instance ID of the component whose persistent data storage is being accessed. To learn about component instance IDs, visit https://fuchsia.dev/fuchsia-src/development/components/component_id_index

make-directory


Usage: ffx component data make-directory <path> Create a new directory in a component's persistent data storage. If the directory already exists, this operation is a no-op.

Options:


--help display usage information Examples: To make a `settings` directory in a storage: $ ffx component data make-directory 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520::settings Note: 2042425d4b16ac396ebdb70e40845dc51516dd25754741a209d1972f126a7520 is the instance ID of the component whose persistent data storage is being accessed. To learn about component instance IDs, visit https://fuchsia.dev/fuchsia-src/development/components/component_id_index

destroy


Usage: ffx component destroy <moniker> Destroys a component instance, removing it from the component topology

Options:


--help display usage information Examples: To destroy a component instance designated by the moniker `/core/ffx-laboratory:foo`: $ ffx component destroy /core/ffx-laboratory:foo Notes: To learn more about running components, visit https://fuchsia.dev/fuchsia-src/development/components/run

knock


Usage: ffx component knock <selector> Connects to a capability described by a given selector

Options:


--help display usage information Examples: To connect to a service: $ ffx component knock 'core/appmgr:out:fuchsia.hwinfo.Product' Notes: Knock verifies the existence of a capability by attempting to connect to it. The command expects a <selector> with the following format: `<component moniker>:(in|out|exposed)[:<service name>].` Note that wildcards can be used but must match exactly one service. `ffx component select` can be used to explore the component topology and find the correct selector for use in this command.

list


Usage: ffx component list [-o <only>] [-v] Lists all components in the component topology

Options:


-o, --only output only cmx/cml/running/stopped components depending on the flag. -v, --verbose whether or not to display a column showing component type and a column showing running/stopped. --help display usage information Examples: To list all components in the topology: $ ffx component list To list all cmx components in the topology: $ ffx component list --only cmx To list all cml components in the topology: $ ffx component list --only cml To list all running components in the topology: $ ffx component list --only running To list all stopped components in the topology: $ ffx component list --only stopped

run


Usage: ffx component run <url> [-n <name>] [-r] Creates and binds to a component instance

Options:


-n, --name specify a name for the component instance. if this flag is not set, the instance name is derived from the component URL. -r, --recreate destroy and recreate the component instance if it already exists --help display usage information Examples: To create a component instance from the `hello-world-rust` component URL: $ ffx component run fuchsia-pkg://fuchsia.com/hello-world#meta/hello-world-rust.cm Notes: This command is a shorthand for the following: $ ffx component create /core/ffx-laboratory:<instance-name> <component-url> $ ffx component bind /core/ffx-laboratory:<instance-name> To learn more about running components, visit https://fuchsia.dev/fuchsia-src/development/components/run

run-legacy


Usage: ffx component run-legacy <url> [<args...>] [-b] Runs a legacy (CMX) component instance on the target

Options:


-b, --background switch to turn on background info --help display usage information Examples: To run the 'hello_world_rust' component: $ ffx component run-legacy \ fuchsia-pkg://fuchsia.com/hello_world_rust#meta/hello_world_rust.cmx To run the Remote Control Service: $ ffx component run-legacy \ fuchsia-pkg://fuchsia.com/remote-control#meta/remote-control-runner.cmx Notes: To learn more about component URLs, visit https://fuchsia.dev/fuchsia-src/concepts/components/component_urls

select


Usage: ffx component select <command> [<args>] Lists component instances matching a selector

Options:


--help display usage information

Commands:


moniker subcommand moniker capability subcommand capability Examples: To show services exposed by remote-control: $ ffx component select moniker remote-control:expose:*' Or to show all services offered by v1 components: $ ffx component select moniker core/appmgr:out:* Or to show all components that expose a capability: $ ffx component select capability fuchsia.sys.Loader Notes: Component select allows for 1). looking up various services exposed by the component. The command expects a <selector> with the following format: `<component moniker>:(in|out|exposed)[:<service name>]` Wildcards may be used anywhere in the selector. 2). looking up components that expose a capability. The command takes in a capability name consists of a string containing the characters a to z, A to Z, 0 to 9, underscore (_), hyphen (-), or the full stop character (.).

show


Usage: ffx component show <filter> Shows detailed information about a component instance

Options:


--help display usage information Examples: To show information about the `brightness_manager` component instance, all of the following commands are valid: $ ffx component show /core/brightness_manager $ ffx component show fuchsia-pkg://fuchsia.com/brightness_manager#meta/brightness_manager.cm $ ffx component show meta/brightness_manager.cm $ ffx component show brightness_manager Notes: This command supports partial matches over the moniker and URL

stop


Usage: ffx component stop <moniker> [-r] Stops a component instance

Options:


-r, --recursive whether or not to stop the component recursively --help display usage information Examples: To stop the component instance designated by the moniker `/core/brightness_manager`: $ ffx component stop /core/brightness_manager Notes: To learn more about running components, visit https://fuchsia.dev/fuchsia-src/development/components/run

config


Usage: ffx config <command> [<args>] View and switch default and user configurations

Options:


--help display usage information

Commands:


env list environment settings get display config values set set config settings remove remove config for a given level add add config value the end of an array analytics enable or disable analytics

add


Usage: ffx config add <name> <value> [-l <level>] [-b <build-dir>] add config value the end of an array

Options:


-l, --level config level. Possible values are "user", "build", "global". Defaults to "user". -b, --build-dir an optional build directory to associate the build config provided - use used for "build" configs --help display usage information Notes: This will always add to the end of an array. Adding to a subtree is not supported. If the current value is not an array, it will convert the value to an array. If you want to insert a value in a different position, consider editing the configuration file directly. Configuration file locations can be found by running `ffx config env get` command.

analytics


Usage: ffx config analytics <command> [<args>] enable or disable analytics

Options:


--help display usage information

Commands:


enable enable analytics disable disable analytics show show analytics

disable


Usage: ffx config analytics disable disable analytics

Options:


--help display usage information

enable


Usage: ffx config analytics enable enable analytics

Options:


--help display usage information

show


Usage: ffx config analytics show show analytics

Options:


--help display usage information

env


Usage: ffx config env [<command>] [<args>] list environment settings

Options:


--help display usage information

Commands:


set set environment settings get list environment for a given level

get


Usage: ffx config env get [<level>] list environment for a given level

Options:


--help display usage information

set


Usage: ffx config env set <file> [-l <level>] [-b <build-dir>] set environment settings

Options:


-l, --level config level. Possible values are "user", "build", "global". Defaults to "user". -b, --build-dir an optional build directory to associate the build config provided - use used for "build" configs --help display usage information

get


Usage: ffx config get [<name>] [-p <process>] [-s <select>] [-b <build-dir>] display config values

Options:


-p, --process how to process results. Possible values are "raw", "sub", and "sub_flat". Defaults to "raw". Currently only supported if a name is given. -s, --select how to collect results. Possible values are "first" and "all". Defaults to "first". If the value is "first", the first value found in terms of priority is returned. If the value is "all", all values across all configuration levels are aggregrated and returned. Currently only supported if a name is given. -b, --build-dir an optional build directory to associate the build config provided - use used for "build" configs --help display usage information Error codes: 2 No value found

remove


Usage: ffx config remove <name> [-l <level>] [-b <build-dir>] remove config for a given level

Options:


-l, --level config level. Possible values are "user", "build", "global". Defaults to "user". -b, --build-dir an optional build directory to associate the build config provided - use used for "build" configs --help display usage information Notes: This will remove the entire value for the given name. If the value is a subtree or array, the entire subtree or array will be removed. If you want to remove a specific value from an array, consider editing the configuration file directly. Configuration file locations can be found by running `ffx config env get` command.

set


Usage: ffx config set <name> <value> [-l <level>] [-b <build-dir>] set config settings

Options:


-l, --level config level. Possible values are "user", "build", "global". Defaults to "user". -b, --build-dir an optional build directory to associate the build config provided - use used for "build" configs --help display usage information

cts


Usage: ffx cts <command> [<args>] Build and run CTS tests.

Options:


--help display usage information

Commands:


run Run CTS tests.

run


Usage: ffx cts run [--cts-version <cts-version>] [--tests <tests>] Run CTS tests.

Options:


--cts-version string, version of CTS to run. --tests string, comma-separated list of tests to run. --help display usage information

daemon


Usage: ffx daemon <command> [<args>] Interact with/control the ffx daemon

Options:


--help display usage information

Commands:


crash crash the daemon echo run echo test against the daemon hang hang the daemon log Dumps the daemon log start run as daemon stop stops a running daemon

crash


Usage: ffx daemon crash crash the daemon

Options:


--help display usage information

echo


Usage: ffx daemon echo [<text>] run echo test against the daemon

Options:


--help display usage information

hang


Usage: ffx daemon hang hang the daemon

Options:


--help display usage information

log


Usage: ffx daemon log [-f] [-l <line-count>] Dumps the daemon log

Options:


-f, --follow print appended logs as they happen -l, --line-count display most recent log lines. --help display usage information

start


Usage: ffx daemon start run as daemon

Options:


--help display usage information

stop


Usage: ffx daemon stop stops a running daemon

Options:


--help display usage information

debug


Usage: ffx debug [<socket_location>] [<command>] [<args>] Start a debugging session.

Options:


--help display usage information

Commands:


fidl uses fidlcat to automatically manage breakpoints to trace the fidl messages and/or the syscalls zxdb launches zxdb to debug programs

fidl


Usage: ffx debug fidl [--from <from>] [--to <to>] [--format <format>] [--with <with...>] [--with-process-info] [--stack <stack>] [--syscalls <syscalls...>] [--exclude-syscalls <exclude-syscalls...>] [--messages <messages...>] [--exclude-messages <exclude-messages...>] [--trigger <trigger...>] [--thread <thread...>] [--dump-messages] [--remote-pid <remote-pid...>] [--remote-name <remote-name...>] [--extra-name <extra-name...>] [--remote-job-id <remote-job-id...>] [--remote-job-name <remote-job-name...>] uses fidlcat to automatically manage breakpoints to trace the fidl messages and/or the syscalls

Options:


--from specifies the source. Source can be: device: this is the default input. The input comes from the live monitoring of one or several processes. At least one of '--remote-pid', '--remote-name', '--remote-job-id', --'remote-job-name', 'run' must be specified. dump: The input comes from stdin which is the log output of one or several programs. The lines in the log which dump syscalls are decoded and replaced by the decoded version. All other lines are unchanged. <path>: playback. Used to replay a session previously recorded with --to <path> (protobuf format). Path gives the name of the file to read. If path is '-' then the standard input is used. This option must be used at most once. --to the session is saved to the specified file (binary protobuf format). When a session is saved, you can replay it using "--from <path>". The raw data is saved. That means that the data saved is independent from what is displayed. --format the display format for the session dump. The available formats are: pretty: the session is pretty printed (with colors). This is the default output if --with is not used. json: the session is printed using a json format. textproto: the session is printed using a text protobuf format. none: nothing is displayed on the standard output (this option only makes sense when used with `--to` or with `--with`). When there is no output, fidlcat is faster (this is better to monitor real time components). This is the default output when --with is used. --with specifies an extra summarized output. summary: at the end of the session, a summary of the session is displayed on the standard output. top: at the end of the session, generate a view that groups the output by process, protocol, and method. The groups are sorted by number of events, so groups with more associated events are listed earlier. group-by-thread: for each thread display a short version of all the events. An equal sign followed by a path can be concatanated to the option to output the result in a file instead of the standard output (for example: --with summary=/tmp/x). This option can be used several times. --with-process-info display the process name, process id and thread id on each line (useful for grep). --stack define the amount of stack frame to display 0: none (default value) 1: call site (1 to 4 levels) 2: full stack frame (adds some overhead) --syscalls a regular expression which selects the syscalls to decode and display. This option can be specified multiple times. By default, only zx_channel_.* syscalls are displayed. To display all the syscalls, use: --syscalls ".*" --exclude-syscalls a regular expression which selects the syscalls to not decode and display. This option can be specified multiple times. To be displayed, a syscall must verify --syscalls and not verify --exclude-syscalls. To display all the syscalls but the zx_handle syscalls, use: --syscalls ".*" --exclude-syscalls "zx_handle_.*" --messages a regular expression which selects the messages to display. To display a message, the method name must satisfy the regexp. This option can be specified multiple times. Message filtering works on the method's fully qualified name. --exclude-messages a regular expression which selects the messages to not display. If a message method name satisfy the regexp, the message is not displayed (even if it satisfies --messages). This option can be specified multiple times. Message filtering works on the method's fully qualified name. --trigger start displaying messages and syscalls only when a message for which the method name satisfies the filter is found. This option can be specified multiple times. Message filtering works on the method's fully qualified name. --thread only display the events for the specified thread. This option can be specified multiple times. By default all the events are displayed. --dump-messages always does a hexadecimal dump of the messages even if we can decode them. --remote-pid the koid of the remote process to trace. --remote-name the <name> of a process. Fidlcat will monitor all existing and future processes whose names includes <name> (<name> is a substring of the process name). This option can be specified multiple times. When used with --remote-job-id or --remote-job-name, only the processes from the selected jobs are taken into account. --extra-name like --remote-name, it monitors some processes. However, for these processes, monitoring starts only when one of of the "--remote-name" process is launched. Also, fidlcat stops when the last "--remote-name" process stops (even if some "--extra-name" processes are still monitored). This option can be specified multiple times. --remote-job-id the koid of a remote job for which we want to monitor all the processes. Only jobs created before fidlcat is launched are monitored. This option can be specified multiple times. --remote-job-name the name of a remote job for which we want to monitor all the processes. All the jobs which contain <name> in their name are used. Only jobs created before fidlcat is launched are monitored. This option can be specified multiple times. --help display usage information

the


Usage: ffx debug [<socket_location>] [<command>] [<args>] Start a debugging session.

Options:


--help display usage information

Commands:


fidl uses fidlcat to automatically manage breakpoints to trace the fidl messages and/or the syscalls zxdb launches zxdb to debug programs

fidl


Usage: ffx debug fidl [--from <from>] [--to <to>] [--format <format>] [--with <with...>] [--with-process-info] [--stack <stack>] [--syscalls <syscalls...>] [--exclude-syscalls <exclude-syscalls...>] [--messages <messages...>] [--exclude-messages <exclude-messages...>] [--trigger <trigger...>] [--thread <thread...>] [--dump-messages] [--remote-pid <remote-pid...>] [--remote-name <remote-name...>] [--extra-name <extra-name...>] [--remote-job-id <remote-job-id...>] [--remote-job-name <remote-job-name...>] uses fidlcat to automatically manage breakpoints to trace the fidl messages and/or the syscalls

Options:


--from specifies the source. Source can be: device: this is the default input. The input comes from the live monitoring of one or several processes. At least one of '--remote-pid', '--remote-name', '--remote-job-id', --'remote-job-name', 'run' must be specified. dump: The input comes from stdin which is the log output of one or several programs. The lines in the log which dump syscalls are decoded and replaced by the decoded version. All other lines are unchanged. <path>: playback. Used to replay a session previously recorded with --to <path> (protobuf format). Path gives the name of the file to read. If path is '-' then the standard input is used. This option must be used at most once. --to the session is saved to the specified file (binary protobuf format). When a session is saved, you can replay it using "--from <path>". The raw data is saved. That means that the data saved is independent from what is displayed. --format the display format for the session dump. The available formats are: pretty: the session is pretty printed (with colors). This is the default output if --with is not used. json: the session is printed using a json format. textproto: the session is printed using a text protobuf format. none: nothing is displayed on the standard output (this option only makes sense when used with `--to` or with `--with`). When there is no output, fidlcat is faster (this is better to monitor real time components). This is the default output when --with is used. --with specifies an extra summarized output. summary: at the end of the session, a summary of the session is displayed on the standard output. top: at the end of the session, generate a view that groups the output by process, protocol, and method. The groups are sorted by number of events, so groups with more associated events are listed earlier. group-by-thread: for each thread display a short version of all the events. An equal sign followed by a path can be concatanated to the option to output the result in a file instead of the standard output (for example: --with summary=/tmp/x). This option can be used several times. --with-process-info display the process name, process id and thread id on each line (useful for grep). --stack define the amount of stack frame to display 0: none (default value) 1: call site (1 to 4 levels) 2: full stack frame (adds some overhead) --syscalls a regular expression which selects the syscalls to decode and display. This option can be specified multiple times. By default, only zx_channel_.* syscalls are displayed. To display all the syscalls, use: --syscalls ".*" --exclude-syscalls a regular expression which selects the syscalls to not decode and display. This option can be specified multiple times. To be displayed, a syscall must verify --syscalls and not verify --exclude-syscalls. To display all the syscalls but the zx_handle syscalls, use: --syscalls ".*" --exclude-syscalls "zx_handle_.*" --messages a regular expression which selects the messages to display. To display a message, the method name must satisfy the regexp. This option can be specified multiple times. Message filtering works on the method's fully qualified name. --exclude-messages a regular expression which selects the messages to not display. If a message method name satisfy the regexp, the message is not displayed (even if it satisfies --messages). This option can be specified multiple times. Message filtering works on the method's fully qualified name. --trigger start displaying messages and syscalls only when a message for which the method name satisfies the filter is found. This option can be specified multiple times. Message filtering works on the method's fully qualified name. --thread only display the events for the specified thread. This option can be specified multiple times. By default all the events are displayed. --dump-messages always does a hexadecimal dump of the messages even if we can decode them. --remote-pid the koid of the remote process to trace. --remote-name the <name> of a process. Fidlcat will monitor all existing and future processes whose names includes <name> (<name> is a substring of the process name). This option can be specified multiple times. When used with --remote-job-id or --remote-job-name, only the processes from the selected jobs are taken into account. --extra-name like --remote-name, it monitors some processes. However, for these processes, monitoring starts only when one of of the "--remote-name" process is launched. Also, fidlcat stops when the last "--remote-name" process stops (even if some "--extra-name" processes are still monitored). This option can be specified multiple times. --remote-job-id the koid of a remote job for which we want to monitor all the processes. Only jobs created before fidlcat is launched are monitored. This option can be specified multiple times. --remote-job-name the name of a remote job for which we want to monitor all the processes. All the jobs which contain <name> in their name are used. Only jobs created before fidlcat is launched are monitored. This option can be specified multiple times. --help display usage information

the


Unrecognized argument: the

zxdb


Usage: ffx debug zxdb launches zxdb to debug programs

Options:


--help display usage information

zxdb


Usage: ffx debug zxdb launches zxdb to debug programs

Options:


--help display usage information

doctor


Usage: ffx doctor [--record] [--no-config] [--retry-count <retry-count>] [--retry-delay <retry-delay>] [--restart-daemon] [--output-dir <output-dir>] Run common checks for the ffx tool and host environment

Options:


--record generates an output zip file with logs --no-config do not include the ffx configuration file --retry-count number of times to retry failed connection attempts --retry-delay timeout delay in ms during connection attempt --restart-daemon force restart the daemon, even if the connection is working --output-dir override the default output directory for doctor records --help display usage information Examples: To run diagnostics: $ ffx doctor To capture the output and additional logs: $ ffx doctor --record By default, this outputs the zip in the current directory. To override output dir: $ ffx doctor --record --output-dir /tmp/ffx Notes: The `doctor` subcommand automatically attempts to repair common target interaction issues and provides useful diagnostic information to the user. By default, running `ffx doctor` attempts to establish a connection with the daemon, and restarts the daemon if there is no connection. The default `retry_count` is '3' and the default 'retry_delay` is '2000' milliseconds.

driver


Usage: ffx driver <command> [<args>] Support driver development workflows

Options:


--help display usage information

Commands:


debug-bind Allows you to debug bind decisions. dump Dump device tree list List drivers list-devices List devices register Informs the driver manager that a new driver package is available. The driver manager will cache a copy of the driver restart Restart all Driver Hosts containing the driver specified by driver path. ZX_ERR_NOT_FOUND indicates that there is no driver matching the given path

available.


Unrecognized argument: available.

debug-bind


Usage: ffx driver debug-bind <driver_path> <device_path> [-p] [-i] Allows you to debug bind decisions.

Options:


-p, --print-properties print out the device properties. -i, --print-instructions print out the bind program instructions. --help display usage information Examples: To debug why a driver did or didn't bind to a particular device: $ ffx driver debug-bind '/boot/driver/usb_video.so' 'sys/platform/pci/00:1f.6' Error codes: 1 Failed to connect to the bind debugger service

driver


Unrecognized argument: driver

driver


Unrecognized argument: driver

driver


Unrecognized argument: driver

dump


Usage: ffx driver dump [-v] Dump device tree

Options:


-v, --verbose list all device properties. --help display usage information Examples: To dump the device tree: $ ffx driver dump Error codes: 1 Failed to connect to the driver development service

list


Usage: ffx driver list [-v] List drivers

Options:


-v, --verbose list all driver properties. --help display usage information Examples: To list all drivers with properties: $ ffx driver list -v Error codes: 1 Failed to connect to the driver development service

list-devices


Usage: ffx driver list-devices [<device>] [-v] List devices

Options:


-v, --verbose list all device properties. --help display usage information Examples: To list all devices: $ ffx driver list-devices -v Error codes: 1 Failed to connect to the driver development service

register


Usage: ffx driver register <url> Informs the driver manager that a new driver package is available. The driver manager will cache a copy of the driver

Options:


--help display usage information Examples: To register a driver $ ffx driver register 'fuchsia-pkg://fuchsia.com/example_driver#meta/example_driver.cmx' Error codes: 1 Failed to connect to the driver registrar service

restart


Usage: ffx driver restart <driver_path> Restart all Driver Hosts containing the driver specified by driver path. ZX_ERR_NOT_FOUND indicates that there is no driver matching the given path

Options:


--help display usage information Examples: To restart a driver: $ ffx driver restart '/boot/driver/e1000.so' Error codes: 1 Failed to connect to the driver manager service

efi


Usage: ffx efi <command> [<args>] Manipulate efi partition

Options:


--help display usage information

Commands:


create Creates efi partition, copies zircon.bin, bootdata.bin, EFI/BOOT/BOOTX64.EFI, zedboot.bin, etc...

EFI/BOOT/BOOTX64.EFI,


Unrecognized argument: EFI/BOOT/BOOTX64.EFI,

create


Usage: ffx efi create -o <output> [--zircon <zircon>] [--bootdata <bootdata>] [--efi-bootloader <efi-bootloader>] [--zedboot <zedboot>] [--cmdline <cmdline>] Creates efi partition, copies zircon.bin, bootdata.bin, EFI/BOOT/BOOTX64.EFI, zedboot.bin, etc...

Options:


-o, --output target file/disk to write EFI partition to --zircon optional path to source file for zircon.bin --bootdata optional path to source file for bootdata.bin --efi-bootloader optional path to source file for EFI/BOOT/BOOTX64.EFI --zedboot optional path to a source file for zedboot.bin --cmdline optional bootloader cmdline file --help display usage information

emu


Usage: ffx emu [--sdk] <command> [<args>] Start and manage Fuchsia emulators

Options:


--sdk running in fuchsia sdk (not inside the fuchsia code repository) --help display usage information

Commands:


start Starting Fuchsia Emulator kill Killing Fuchsia Emulator remote This is a placeholder for a new feature in active development. Please stand by...

development.


Unrecognized argument: development.

kill


Usage: ffx emu kill [-d <vdl-path>] [--launched-proto <launched-proto>] Killing Fuchsia Emulator

Options:


-d, --vdl-path device_launcher binary location. Defaults to looking in prebuilt/vdl/device_launcher --launched-proto required, file containing device_launcher process artifact location. --help display usage information

remote


Usage: ffx emu remote <host> [<args...>] [--dir <dir>] [--no-build] [--stream] [--no-emu] [--no-turn] [--no-open] [--display <display>] [--port <port>] This is a placeholder for a new feature in active development. Please stand by...

Options:


--dir defaults to ~/fuchsia, the path to the FUCHSIA_DIR on <host> --no-build do not build, just pull artifacts already present --stream stream output from remote emulator using WebRTC instead of fetching artifacts --no-emu only tunnel, do not start remote emulator --no-turn do not use turn configuration for remote emulator --no-open do not open https://web-femu.appspot.com, just run remote emulator --display do not start remote virtual display, use DPY instead --port port used on local machine to connect with remote emulator over HTTP (default: 8080) --help display usage information

start


Usage: ffx emu start [-H] [-N] [--host-gpu] [--software-gpu] [--hidpi-scaling] [-u <upscript>] [-p <pointing-device>] [-w <window-width>] [-h <window-height>] [-s <image-size>] [-F <device-proto>] [-e <aemu-path>] [--aemu-version <aemu-version>] [-d <vdl-path>] [--vdl-version <vdl-version>] [-x <grpcwebproxy>] [-X <grpcwebproxy-path>] [--grpcwebproxy-version <grpcwebproxy-version>] [-v <sdk-version>] [--gcs-bucket <gcs-bucket>] [--image-name <image-name>] [-l <emulator-log>] [--port-map <port-map>] [--vdl-output <vdl-output>] [-c <kernel-args>] [--nointeractive] [-i] [--debugger] [-m] [--emu-only] [--nopackageserver] [--packages-to-serve <packages-to-serve>] [--package-server-log <package-server-log>] [--amber-unpack-root <amber-unpack-root>] [--envs <envs...>] [--noacceleration] [--package-server-port <package-server-port>] [-a <amber-files>] [-f <fvm-image>] [-k <kernel-image>] [-z <zbi-image>] [-A <image-architecture>] [--ssh <ssh>] [-V] Starting Fuchsia Emulator

Options:


-H, --headless bool, run emulator in headless mode. -N, --tuntap bool, run emulator with emulated nic via tun/tap. --host-gpu bool, run emulator with host GPU acceleration, this doesn't work on remote-desktop with --headless. --software-gpu bool, run emulator without host GPU acceleration, default. --hidpi-scaling bool, enable pixel scaling on HiDPI devices. -u, --upscript path to tun/tap upscript, this script will be executed before booting up FEMU. -p, --pointing-device set pointing device used on emulator: mouse or touch screen. Allowed values are "touch", "mouse". Default is "touch". -w, --window-width emulator window width. Default to 1280. -h, --window-height emulator window height. Default to 800. -s, --image-size extends storage size to <size> bytes. Default is "2G". -F, --device-proto path to fuchsia virtual device configuration, if not specified a generic one will be generated. -e, --aemu-path path to aemu location. When running in fuchsia repo, defaults to looking in prebuilt/third_party/aemu/PLATFORM. When running in fuchsia sdk, defaults to looking in $HOME/.fuchsia/femu. --aemu-version label used to download AEMU from CIPD. Default is "integration". Download only happens if aemu binary cannot be found from known paths. -d, --vdl-path device_launcher binary location. When running in fuchsia repo, defaults to looking in prebuilt/vdl/device_launcher. When running in fuchsia sdk, defaults to looking in directory containing `fvdl`. --vdl-version label used to download vdl from CIPD. Default is "latest". Download only happens if vdl (device_launcher) binary cannot be found from known paths. -x, --grpcwebproxy enable WebRTC HTTP service on port, if set to 0 a random port will be picked -X, --grpcwebproxy-path location of grpcwebproxy, When running in fuchsia repo, defaults to looking in prebuilt/third_party/grpcwebproxy When running in fuchsia sdk, defaults to looking in $HOME/.fuchsia/femu. --grpcwebproxy-version label used to download grpcwebproxy from CIPD. Default is "latest". Download only happens if --grpcwebproxy is set and grpcwebproxy binary cannot be found from known paths or path specified by --grpcwebproxy_path. -v, --sdk-version fuchsia sdk ID used to fetch from gcs, if specified, the emulator will launch with fuchsia sdk files fetched from gcs. To find the latest version run `gsutil cat gs://fuchsia/development/LATEST_LINUX`. --gcs-bucket gcs bucket name. Default is "fuchsia". --image-name image file name used to fetch from gcs. Default is "qemu-x64". To view available image names run `gsutil ls -l gs://fuchsia/development/$(gsutil cat gs://fuchsia/development/LATEST_LINUX)/images`. -l, --emulator-log file path to store emulator log. Default is a temp file that is deleted after `fvdl` exits. --port-map host port mapping for user-networking mode. This flag will be ignored if --tuntap is used. If not specified, an ssh port on host will be randomly picked and forwarded. ex: hostfwd=tcp::<host_port>-:<guest_port>,hostfwd=tcp::<host_port>-:<guest_port> --vdl-output file destination to write `device_launcher` output. Required for --nointeractive mode. Default is a temp file that is deleted after `fvdl` exits. Specify this flag if you plan to use the `kill` subcommand. -c, --kernel-args extra kernel flags to pass into aemu. --nointeractive bool, turn off interactive mode. if turned off, fvdl will not land user in ssh console. A ssh port will still be forwarded. User needs to specify --vdl-output flag with this mode, and manually call the `kill` subcommand to perform clean shutdown. -i, --cache-image bool, download and re-use image files in the cached location ~/.fuchsia/<image_name>/<sdk_version>/. If not set (default), image files will be stored in a temp location and removed with `kill` subcommand. If image location is specified with --kernel-image, --zbi-image, --fvm-image etc., the cached image will be overwritten for the specified image file. --debugger bool, pause on launch and wait for a debugger process to attach before resuming -m, --monitor bool, launches emulator in qemu console No local services such as package_server will be running in this mode. --emu-only bool, launches user in femu serial console, this flag is required for bringup image. No local services such as package_server will be running in this mode. --nopackageserver bool, disable automatically launching package server. --packages-to-serve comma separated string of fuchsia package urls, extra packages to serve after starting FEMU. Requires --nopackageserver=false --package-server-log file path to store package server log. Default is a stdout. Requires --nopackageserver=false --amber-unpack-root path to unpack archived_package downloaded from GCS. This only applies when fvdl is downloading images files from GCS (ex: --gcs-bucket, --sdk-verion, --image-name flags are specified). If not specified, a temporary path will be used. --envs environment variables for emulator. The argument can be repeated for multiple times to add multiple arguments. If not specified, only the default environment variables (DISPLAY) will be set to run the emulator. --noacceleration bool, disable acceleration using KVM on Linux and HVF on macOS. --package-server-port int, port to an existing package server running on the host. -a, --amber-files string, absolute path to amber-files location, path name must end with 'amber-files'. -f, --fvm-image string, absolute path to fvm image file location. -k, --kernel-image string, absolute path to kernel image file location. If specified --zbi-image and --image-architecture must also be specified. When running with --sdk option, this will skip downloading fuchsia image prebuilts from GCS. -z, --zbi-image string, absolute path to zircon image file location. If specified --kernel-image and --image-architecture must also be specified. When running with --sdk option, this will skip downloading fuchsia image prebuilts from GCS. -A, --image-architecture string, specifies image architecture, accepted values are 'arm64' or 'x64'. Required if image override flags (i.e --fvm-image, --kernel-image, --zbi-image, or --amber-files) are specified. --ssh string, specifies an alternative path for ssh keys. The emulator defaults to the user's $HOME/.ssh directory if none is specified. The path indicated must contain the files `fuchsia_authorized_keys` and `fuchsia_ed25519`. -V, --verbose bool, enables extra logging for debugging --help display usage information

flutter


Usage: ffx flutter <command> [<args>] Interact with Flutter components on the target.

Options:


--help display usage information

Commands:


tunnel Establishes a port forward between the local host and the dart vm service port. Notes: The `flutter` subcommand is an entry workflow and contains various subcommands for flutter component management and interaction.

dart


Unrecognized argument: dart

tunnel


Usage: ffx flutter tunnel Establishes a port forward between the local host and the dart vm service port.

Options:


--help display usage information Notes: Determines the vm_service_port in the Flutter runner on the target Fuchsia device. An ssh tunnel is then established between localhost(127.0.0.1) at an available port and the target device at the vm_service_port. A url for the location of the listening socket is printed out for users.

inspect


Usage: ffx inspect [-f <format>] <command> [<args>] Query component nodes exposed via the Inspect API

Options:


-f, --format the format to be used to display the results (json, text). --help display usage information

Commands:


list List components that expose inspect list-accessors List ArchiveAccessor files. selectors List available selectors show Print inspect hierarchies

list


Usage: ffx inspect list [--manifest <manifest>] [--with-url] [--accessor-path <accessor-path>] List components that expose inspect

Options:


--manifest the name of the manifest file that we are interested in. If this is provided, the output will only contain monikers for components whose url contains the provided name. --with-url also print the URL of the component. --accessor-path the path from where to get the ArchiveAccessor connection. If the given path is a directory, the command will look for a `fuchsia.diagnostics.ArchiveAccessor` service file. If the given path is a service file, the command will attempt to connect to it as an ArchiveAccessor. --help display usage information Notes: Lists all components (relative to the scope where the archivist receives events from) of components that expose inspect. For v1: this is the realm path plus the realm name For v2: this is the moniker without the instances ids.

list-accessors


Usage: ffx inspect list-accessors [<paths...>] List ArchiveAccessor files.

Options:


--help display usage information Notes: Lists all ArchiveAccessor files under the provided paths. All paths are implicitly rooted under `/hub-v2`. If no paths are provided, it'll list everything under /hub-v2. It is possible to reach v1 components by starting with the path prefix children/core/children/appmgr/exec/out/hub.

selectors


Usage: ffx inspect selectors [<selectors...>] [--manifest <manifest>] [--accessor-path <accessor-path>] List available selectors

Options:


--manifest the name of the manifest file that we are interested in. If this is provided, the output will only contain monikers for components whose url contains the provided name. --accessor-path the path from where to get the ArchiveAccessor connection. If the given path is a directory, the command will look for a `fuchsia.diagnostics.ArchiveAccessor` service file. If the given path is a service file, the command will attempt to connect to it as an ArchiveAccessor. --help display usage information Notes: Lists all available full selectors (component selector + tree selector). If a selector is provided, it’ll only print selectors for that component. If a full selector (component + tree) is provided, it lists all selectors under the given node.

show


Usage: ffx inspect show [<selectors...>] [--manifest <manifest>] [--accessor-path <accessor-path>] Print inspect hierarchies

Options:


--manifest the name of the manifest file that we are interested in. If this is provided, the output will only contain monikers for components whose url contains the provided name. --accessor-path the path from where to get the ArchiveAccessor connection. If the given path is a directory, the command will look for a `fuchsia.diagnostics.ArchiveAccessor` service file. If the given path is a service file, the command will attempt to connect to it as an ArchiveAccessor. --help display usage information Notes: Prints the inspect hierarchies that match the given selectors.

net


Usage: ffx net <command> [<args>] View and manage target network configuration

Options:


--help display usage information

Commands:


filter commands for packet filter fwd commands for forwarding tables if commands for network interfaces ip-fwd commands for IP forwarding log commands for logging neigh commands for neighbor tables route commands for routing tables metric commands for interface route metrics dhcp commands for an interfaces dhcp client

dhcp


Usage: ffx net dhcp <command> [<args>] commands for an interfaces dhcp client

Options:


--help display usage information

Commands:


start starts a dhcp client on the interface stop stops the dhcp client on the interface

start


Usage: ffx net dhcp start <id> starts a dhcp client on the interface

Options:


--help display usage information

stop


Usage: ffx net dhcp stop <id> stops the dhcp client on the interface

Options:


--help display usage information

filter


Usage: ffx net filter <command> [<args>] commands for packet filter

Options:


--help display usage information

Commands:


disable disables the packet filter enable enables the packet filter get-nat-rules gets nat rules get-rdr-rules gets rdr rules get-rules gets filter rules is-enabled is the packet filter enabled? set-nat-rules sets nat rules (see the netfilter::parser library for the NAT rules format) set-rdr-rules sets rdr rules (see the netfilter::parser library for the RDR rules format) set-rules sets filter rules (see the netfilter::parser library for the rules format)

NAT


Unrecognized argument: NAT

RDR


Unrecognized argument: RDR

disable


Usage: ffx net filter disable disables the packet filter

Options:


--help display usage information

enable


Usage: ffx net filter enable enables the packet filter

Options:


--help display usage information

get-nat-rules


Usage: ffx net filter get-nat-rules gets nat rules

Options:


--help display usage information

get-rdr-rules


Usage: ffx net filter get-rdr-rules gets rdr rules

Options:


--help display usage information

get-rules


Usage: ffx net filter get-rules gets filter rules

Options:


--help display usage information

is-enabled


Usage: ffx net filter is-enabled is the packet filter enabled?

Options:


--help display usage information

rules


Unrecognized argument: rules

set-nat-rules


Usage: ffx net filter set-nat-rules <rules> sets nat rules (see the netfilter::parser library for the NAT rules format)

Options:


--help display usage information

set-rdr-rules


Usage: ffx net filter set-rdr-rules <rules> sets rdr rules (see the netfilter::parser library for the RDR rules format)

Options:


--help display usage information

set-rules


Usage: ffx net filter set-rules <rules> sets filter rules (see the netfilter::parser library for the rules format)

Options:


--help display usage information

fwd


Usage: ffx net fwd <command> [<args>] commands for forwarding tables

Options:


--help display usage information

Commands:


add-device adds a forwarding table entry to route to a device add-hop adds a forwarding table entry to route to a IP address del deletes a forwarding table entry list lists forwarding table entries

add-device


Usage: ffx net fwd add-device <id> <addr> <prefix> adds a forwarding table entry to route to a device

Options:


--help display usage information

add-hop


Usage: ffx net fwd add-hop <next_hop> <addr> <prefix> adds a forwarding table entry to route to a IP address

Options:


--help display usage information

del


Usage: ffx net fwd del <addr> <prefix> deletes a forwarding table entry

Options:


--help display usage information

list


Usage: ffx net fwd list lists forwarding table entries

Options:


--help display usage information

if


Usage: ffx net if <command> [<args>] commands for network interfaces

Options:


--help display usage information

Commands:


add adds a network interface by path addr commands for updates network interface addresses bridge creates a bridge between network interfaces del removes a network interface disable disables a network interface enable enables a network interface get queries a network interface ip-forward get or set IP forwarding for an interface list lists network interfaces

add


Usage: ffx net if add <path> adds a network interface by path

Options:


--help display usage information

addr


Usage: ffx net if addr <command> [<args>] commands for updates network interface addresses

Options:


--help display usage information

Commands:


add adds an address to the network interface del deletes an address from the network interface
add

Usage: ffx net if addr add <id> <addr> <prefix> adds an address to the network interface

Options:


--help display usage information
del

Usage: ffx net if addr del <id> <addr> [<prefix>] deletes an address from the network interface

Options:


--help display usage information

bridge


Usage: ffx net if bridge [<ids...>] creates a bridge between network interfaces

Options:


--help display usage information

del


Usage: ffx net if del <id> removes a network interface

Options:


--help display usage information

disable


Usage: ffx net if disable <id> disables a network interface

Options:


--help display usage information

enable


Usage: ffx net if enable <id> enables a network interface

Options:


--help display usage information

get


Usage: ffx net if get <id> queries a network interface

Options:


--help display usage information

ip-forward


Usage: ffx net if ip-forward <command> [<args>] get or set IP forwarding for an interface

Options:


--help display usage information

Commands:


show get IP forwarding for an interface set set IP forwarding for an interface
set

Usage: ffx net if ip-forward set <id> <ip_version> <enable> set IP forwarding for an interface

Options:


--help display usage information
show

Usage: ffx net if ip-forward show <id> <ip_version> get IP forwarding for an interface

Options:


--help display usage information

list


Usage: ffx net if list [<name_pattern>] lists network interfaces

Options:


--help display usage information

ip-fwd


Usage: ffx net ip-fwd <command> [<args>] commands for IP forwarding

Options:


--help display usage information

Commands:


disable disables IP forwarding enable enables IP forwarding

disable


Usage: ffx net ip-fwd disable disables IP forwarding

Options:


--help display usage information

enable


Usage: ffx net ip-fwd enable enables IP forwarding

Options:


--help display usage information

log


Usage: ffx net log <command> [<args>] commands for logging

Options:


--help display usage information

Commands:


set-packets log packets to stdout

set-packets


Usage: ffx net log set-packets <enabled> log packets to stdout

Options:


--help display usage information

metric


Usage: ffx net metric <command> [<args>] commands for interface route metrics

Options:


--help display usage information

Commands:


set assigns a route metric to the network interface

set


Usage: ffx net metric set <id> <metric> assigns a route metric to the network interface

Options:


--help display usage information

neigh


Usage: ffx net neigh <command> [<args>] commands for neighbor tables

Options:


--help display usage information

Commands:


add adds an entry to the neighbor table clear removes all entries associated with a network interface from the neighbor table del removes an entry from the neighbor table list lists neighbor table entries watch watches neighbor table entries for state changes config commands for the Neighbor Unreachability Detection configuration

add


Usage: ffx net neigh add <interface> <ip> <mac> adds an entry to the neighbor table

Options:


--help display usage information

clear


Usage: ffx net neigh clear <interface> <ip_version> removes all entries associated with a network interface from the neighbor table

Options:


--help display usage information

config


Usage: ffx net neigh config <command> [<args>] commands for the Neighbor Unreachability Detection configuration

Options:


--help display usage information

Commands:


get returns the current NUD configuration options for the provided interface update updates the current NUD configuration options for the provided interface
get

Usage: ffx net neigh config get <interface> <ip_version> returns the current NUD configuration options for the provided interface

Options:


--help display usage information
provided

Unrecognized argument: provided
provided

Unrecognized argument: provided
update

Usage: ffx net neigh config update <interface> <ip_version> [--base-reachable-time <base-reachable-time>] [--learn-base-reachable-time <learn-base-reachable-time>] [--min-random-factor <min-random-factor>] [--max-random-factor <max-random-factor>] [--retransmit-timer <retransmit-timer>] [--learn-retransmit-timer <learn-retransmit-timer>] [--delay-first-probe-time <delay-first-probe-time>] [--max-multicast-probes <max-multicast-probes>] [--max-unicast-probes <max-unicast-probes>] [--max-anycast-delay-time <max-anycast-delay-time>] [--max-reachability-confirmations <max-reachability-confirmations>] updates the current NUD configuration options for the provided interface

Options:


--base-reachable-time a base duration, in nanoseconds, for computing the random reachable time --learn-base-reachable-time learn `base_reachable_time` during runtime from the neighbor discovery protocol, if supported --min-random-factor the minimum value of the random factor used for computing reachable time --max-random-factor the maximum value of the random factor used for computing reachable time --retransmit-timer duration, in nanoseconds, between retransmissions of reachability probes in the PROBE state --learn-retransmit-timer learn `retransmit_timer` during runtime from the neighbor discovery protocol, if supported --delay-first-probe-time duration, in nanoseconds, to wait for a non-Neighbor-Discovery related protocol to reconfirm reachability after entering the DELAY state --max-multicast-probes the number of reachability probes to send before concluding negative reachability and deleting the entry from the INCOMPLETE state --max-unicast-probes the number of reachability probes to send before concluding retransmissions from within the PROBE state should cease and the entry SHOULD be deleted --max-anycast-delay-time if the target address is an anycast address, the stack SHOULD delay sending a response for a random time between 0 and this duration, in nanoseconds --max-reachability-confirmations a node MAY send up to this amount of unsolicited reachability confirmations messages to all-nodes multicast address when a node determines its link-layer address has changed --help display usage information

configuration


Unrecognized argument: configuration

del


Usage: ffx net neigh del <interface> <ip> removes an entry from the neighbor table

Options:


--help display usage information

list


Usage: ffx net neigh list lists neighbor table entries

Options:


--help display usage information

the


Unrecognized argument: the

watch


Usage: ffx net neigh watch watches neighbor table entries for state changes

Options:


--help display usage information

route


Usage: ffx net route <command> [<args>] commands for routing tables

Options:


--help display usage information

Commands:


list lists devices add adds a route to the route table del deletes a route from the route table

add


Usage: ffx net route add --destination <destination> --netmask <netmask> [--gateway <gateway>] --nicid <nicid> --metric <metric> adds a route to the route table

Options:


--destination the network id of the destination network --netmask the netmask corresponding to destination --gateway the ip address of the first hop router --nicid the outgoing network interface id of the route --metric the metric for the route --help display usage information

del


Usage: ffx net route del --destination <destination> --netmask <netmask> [--gateway <gateway>] --nicid <nicid> --metric <metric> deletes a route from the route table

Options:


--destination the network id of the destination network --netmask the netmask corresponding to destination --gateway the ip address of the first hop router --nicid the outgoing network interface id of the route --metric the metric for the route --help display usage information

list


Usage: ffx net route list lists devices

Options:


--help display usage information

overnet


Usage: ffx overnet <command> [<args>] Interact with the Overnet mesh

Options:


--help display usage information

Commands:


list-peers List known peer nodes list-links List links on a particular peer host-pipe Use stdin/stdout as a link to another overnet instance full-map Construct a detailed graphviz map of the Overnet mesh - experts only!

experts


Unrecognized argument: experts

full-map


Usage: ffx overnet full-map --exclude-self <exclude-self> Construct a detailed graphviz map of the Overnet mesh - experts only!

Options:


--exclude-self if set, exclude the onet tool from output --help display usage information

host-pipe


Usage: ffx overnet host-pipe Use stdin/stdout as a link to another overnet instance

Options:


--help display usage information

list-links


Usage: ffx overnet list-links <nodes> List links on a particular peer

Options:


--help display usage information

list-peers


Usage: ffx overnet list-peers List known peer nodes

Options:


--help display usage information

package


Usage: ffx package <command> [<args>] Create and publish Fuchsia packages

Options:


--help display usage information

Commands:


build Builds a package. Entries may be specified as: - <dst>=<src>: Place the file at path <src> into the package at path <dst>. - @<manifest-file>: Read each line of this file as an entry. This is not recursive; you can't put another @<manifest-file> download download Package from TUF package server. export export a package archive import import a package archive

build


Usage: ffx package build [<entries...>] [-s <source-dir>] [--hash-out <hash-out>] Builds a package. Entries may be specified as: - <dst>=<src>: Place the file at path <src> into the package at path <dst>. - @<manifest-file>: Read each line of this file as an entry. This is not recursive; you can't put another @<manifest-file>

Options:


-s, --source-dir base directory for the <src> part of entries; defaults to the current directory --hash-out write the package hash to this file instead of stdout --help display usage information

platform


Usage: ffx platform <command> [<args>] Manage platform build prerequisites

Options:


--help display usage information

Commands:


preflight Evaluate suitability for building and running Fuchsia

preflight


Usage: ffx platform preflight [--json] Evaluate suitability for building and running Fuchsia

Options:


--json outputs json instead of human-readable text. --help display usage information

profile


Usage: ffx profile <command> [<args>] Profile run-time information from various subsystems

Options:


--help display usage information

Commands:


cpu Query CPU-related information

cpu


Usage: ffx profile cpu <command> [<args>] Query CPU-related information

Options:


--help display usage information

Commands:


load Measure CPU load over the specified duration

load


Usage: ffx profile cpu load -d <duration> Measure CPU load over the specified duration

Options:


-d, --duration duration over which to measure the CPU load --help display usage information Examples: To measure the CPU load over a two second duration $ ffx profile cpu load --duration 2 Notes: This command uses the GetCpuLoad method of the fuchsia.kernel.Stats service to query the the load from each active CPU core in the system. The measured CPU load from each core is printed in the following format: CPU 0: 0.66% CPU 1: 1.56% CPU 2: 0.83% CPU 3: 0.71% Total: 3.76% The valid range for each CPU load is [0-100]%. The "Total" value represents the summation of the load percentages of all CPU cores and is valid in the range [0-100*[NUM_CPU]]%

repository


Usage: ffx repository <command> [<args>] Inspect and manage package repositories

Options:


--help display usage information

Commands:


add-from-pm list List all repositories packages List the packages inside a repository remove target ....

add-from-pm


Usage: ffx repository add-from-pm <name> <pm_repo_path>

Options:


--help display usage information

list


Usage: ffx repository list List all repositories

Options:


--help display usage information

packages


Usage: ffx repository packages <name> [--full-hash] List the packages inside a repository

Options:


--full-hash if true, package hashes will be displayed in full (i.e. not truncated). --help display usage information

remove


Usage: ffx repository remove <name>

Options:


--help display usage information

target


Usage: ffx repository target <command> [<args>] ....

Options:


--help display usage information

Commands:


deregister list register

deregister


Usage: ffx repository target deregister <name>

Options:


--help display usage information

list


Usage: ffx repository target list

Options:


--help display usage information

register


Usage: ffx repository target register [<name>] [--storage-type <storage-type>] [--alias <alias...>]

Options:


--storage-type enable persisting this repository across reboots. --alias set up a rewrite rule mapping each `alias` host to to the repository identified by `name`. --help display usage information

scrutiny


Usage: ffx scrutiny <command> [<args>] Audit the security of Fuchsia

Options:


--help display usage information

Commands:


extract Extracts common Fuchsia file types list Lists properties about build artifacts shell Launch the scrutiny shell verify Verify the build

extract


Usage: ffx scrutiny extract <command> [<args>] Extracts common Fuchsia file types

Options:


--help display usage information

Commands:


blobfs Extracts a Blobfs block file fvm Extracts a FVM file package Extracts a Fuchsia package from a Url zbi Extracts the Zircon Boot Image

blobfs


Usage: ffx scrutiny extract blobfs <input> <output> Extracts a Blobfs block file

Options:


--help display usage information Examples: To extract a Blobfs block file: $ffx scrutiny extract blobfs blob.blk /tmp/blobs Notes: Extracts a blobfs block file to a specific directory.

fvm


Usage: ffx scrutiny extract fvm <input> <output> Extracts a FVM file

Options:


--help display usage information Examples: To extract a FVM file: $ffx scrutiny extract fvm fvm.blk /tmp/fvm Notes: Extracts a FVM to a specific directory.

package


Usage: ffx scrutiny extract package <url> <output> Extracts a Fuchsia package from a Url

Options:


--help display usage information Examples: To extract a Fuchsia package from a url: $ffx scrutiny extract package fuchsia-pkg://fuchsia.com/foo /tmp/foo Notes: Extracts a package to a specific directory.

zbi


Usage: ffx scrutiny extract zbi <input> <output> Extracts the Zircon Boot Image

Options:


--help display usage information Examples: To extract a Zircon Boot Image: $ffx scrutiny extract zbi foo.zbi /tmp/foo Notes: Extracts a ZBI to a specific directory.

list


Usage: ffx scrutiny list <command> [<args>] Lists properties about build artifacts

Options:


--help display usage information

Commands:


components Lists all the components in the build package Lists all the files in a package packages Lists all the packages in the build

components


Usage: ffx scrutiny list components Lists all the components in the build

Options:


--help display usage information Examples: To list all the components in the build: $ffx scrutiny list components Notes: Lists all the components in the build in a json format.

package


Usage: ffx scrutiny list package <url> Lists all the files in a package

Options:


--help display usage information Examples: To list all the files in a package: $ffx scrutiny list package fuchsia-pkg://fuchsia.com/foo Notes: Lists all the package contents in json format.

packages


Usage: ffx scrutiny list packages Lists all the packages in the build

Options:


--help display usage information Examples: To list all the packages in the build: $ffx scrutiny list packages Notes: Lists all the packages in the build in a json format.

shell


Usage: ffx scrutiny shell [<command>] [-b <build>] [-s <script>] [-m <model>] [-l <log>] [-p <port>] [-v <verbosity>] Launch the scrutiny shell

Options:


-b, --build set a custom path to the build directory -s, --script run a file as a scrutiny script -m, --model set a custom path to the data model -l, --log set a custom path output log -p, --port set a custom port to run scrutiny on -v, --verbosity set the verbosity level of logging --help display usage information Examples: To start an interactive shell session: $ ffx scrutiny shell To run commands directly: $ ffx scrutiny shell components $ ffx scrutiny shell "search.packages --files fdio" Notes: Launches an interactive scrutiny shell where scrutiny specific commands can be run. This will also launch a server on port 127.0.0.1:8080 by default that provides visual auditing tools. Inside the shell run help for a full list of available commands. If you wish to integrate Scrutiny as part of a wider script check out the --script option.

verify


Usage: ffx scrutiny verify <command> [<args>] Verify the build

Options:


--help display usage information

Commands:


routes Verifies protocol and directory routes in Fuchsia

routes


Usage: ffx scrutiny verify routes [<capability>] Verifies protocol and directory routes in Fuchsia

Options:


--help display usage information Examples: To verify the routes on your current build: $ffx scrutiny verify routes $ffx scrutiny verify routes directory $ffx scrutiny verify routes protocol Notes: Verifies all protocol and directory routes.

sdk


Usage: ffx sdk <command> [<args>] Modify or query the installed SDKs

Options:


--help display usage information

Commands:


version Retrieve the version of the current SDK set Set sdk-related configuration options

set


Usage: ffx sdk set <command> [<args>] Set sdk-related configuration options

Options:


--help display usage information

Commands:


root Sets the path to the root of the preferred SDK

root


Usage: ffx sdk set root <path> Sets the path to the root of the preferred SDK

Options:


--help display usage information

version


Usage: ffx sdk version Retrieve the version of the current SDK

Options:


--help display usage information

self-test


Usage: ffx self-test [--timeout <timeout>] [--case-timeout <case-timeout>] [--include-target <include-target>] [<command>] [<args>] Execute the ffx self-test (e2e) suite

Options:


--timeout maximum runtime of entire test suite in seconds --case-timeout maximum run time of a single test case in seconds --include-target include target interaction tests --help display usage information

Commands:


experiment A fake experiment for the ffx self-test (e2e) suite

experiment


Usage: ffx self-test experiment A fake experiment for the ffx self-test (e2e) suite

Options:


--help display usage information

session


Usage: ffx session <command> [<args>] Control the session

Options:


--help display usage information

Commands:


add Add an element to the current session keyboard Modify keyboard settings launch Launch a session restart Restart the current session show Show information about the current session

add


Usage: ffx session add <url> Add an element to the current session

Options:


--help display usage information

keyboard


Usage: ffx session keyboard --keymap <keymap> Modify keyboard settings

Options:


--keymap the keymap to use, one of US_QWERTY,FR_AZERTY,US_DVORAK --help display usage information

launch


Usage: ffx session launch <url> Launch a session

Options:


--help display usage information

restart


Usage: ffx session restart Restart the current session

Options:


--help display usage information

show


Usage: ffx session show Show information about the current session

Options:


--help display usage information

starnix


Usage: ffx starnix <command> [<args>] Control starnix processes

Options:


--help display usage information

Commands:


shell Start a shell inside starnix start Start a component inside starnix

shell


Usage: ffx starnix shell Start a shell inside starnix

Options:


--help display usage information Examples: To start a shell inside starnix: $ ffx starnix shell

start


Usage: ffx starnix start <url> Start a component inside starnix

Options:


--help display usage information Examples: To start a component inside starnix: $ ffx starnix start <url>

target


Usage: ffx target <command> [<args>] Interact with a target device or emulator

Options:


--help display usage information

Commands:


add Make the daemon aware of a specific target default Manage the default target flash Flash an image to a target device get-ssh-address Get the target's ssh address list List all targets log Display logs from a target device off Powers off a target reboot Reboots a target remove Make the daemon forget a specific target show Display relevant information for the target snapshot Takes a snapshot of the target's state update Update base system software on target wait Wait until the target becomes available. Notes: The `target` subcommand contains various commands for target management and interaction. Typically, this is the entry workflow for users, allowing for target discovery and provisioning before moving on to `component` or `session` workflows once the system is up and running on the target. Most of the commands depend on the RCS (Remote Control Service) on the target.

add


Usage: ffx target add <addr> Make the daemon aware of a specific target

Options:


--help display usage information Examples: To add a remote target forwarded via ssh: $ ffx target add 127.0.0.1:8022 Or to add a target using its IPV6: $ ffx target add fe80::32fd:38ff:fea8:a00a Notes: Manually add a target based on its IP address. The command accepts IPV4 or IPV6 addresses, including a port number: `<addr> = <ip addr:port>`. Typically, the daemon automatically discovers targets as they come online. However, manually adding a target allows for specifying a port number or address, often used for remote workflows.

default


Usage: ffx target default <command> [<args>] Manage the default target

Options:


--help display usage information

Commands:


get Get the default configured target set Set the default target unset Clears the default configured target Examples: For one-off overrides for the default use `--target` option: $ ffx --target <target name> <subcommand> Or use the `--config` option: $ ffx --config target.default=<target name> <subcommand> Notes: Manages the default configured target for all operations. The default target is designated by a `*` next to the name. This is an alias for the `target.default` configuration key.

get


Usage: ffx target default get Get the default configured target

Options:


--help display usage information Notes: Returns the default configured target from the 'User Configuration'. Returns an empty string if no default is configured.

set


Usage: ffx target default set <nodename> [-l <level>] [-b <build-dir>] Set the default target

Options:


-l, --level config level, such as 'user', 'build', or 'global' -b, --build-dir optional directory to associate the provided build config --help display usage information Examples: To set the default target: $ ffx target default set <target name> To set the 'target.default` key at the global configuration: $ ffx target default set -l global <target name> To specify a default target for a specific build directory: $ ffx target default set -l build -b ~/fuchsia/out <target name> Notes: Sets the `target.default` configuration key. By default sets the key in the 'User Configuration'. Can be used in conjuction with `ffx target list` to list the names of the discovered targets. After setting the default target, `ffx target list` will mark the default with a `*` in the output list.

unset


Usage: ffx target default unset [-l <level>] [-b <build-dir>] Clears the default configured target

Options:


-l, --level config level, such as 'user', 'build', or 'global' -b, --build-dir optional directory to associate the provided build config --help display usage information Examples: To clear the default target: $ ffx target default unset To clear the `target.default` key from global configuration: $ ffx target default unset -l global To specify a specific build directory: $ ffx target default unset -l build -b ~/fuchsia/out Notes: Clears the `target.default` configuration key. By default clears the 'User Configuration'. Returns a warning if the key is already empty.

flash


Usage: ffx target flash <manifest> [<product>] [--oem-stage <oem-stage...>] [--ssh-key <ssh-key>] [--no-bootloader-reboot] [--skip-verify] Flash an image to a target device

Options:


--oem-stage oem staged file - can be supplied multiple times --ssh-key path to ssh key - will default to the `ssh.pub` key in ffx config --no-bootloader-reboot the device should not reboot after bootloader images are flashed --skip-verify skip hardware verification. This is dangerous, please be sure the images you are flashing match the device --help display usage information Examples: To flash a specific image: $ ffx target flash ~/fuchsia/out/flash.json fuchsia To include SSH keys as well: $ ffx target flash --ssh-key ~/fuchsia/.ssh/authorized_keys ~/fuchsia/out/default/flash.json fuchsia Notes: Flashes an image to a target device using the fastboot protocol. Requires a specific <manifest> file and <product> name as an input. This is only applicable to a physical device and not an emulator target. The target device is typically connected via a micro-USB connection to the host system. The <manifest> format is a JSON file generated when building a fuchsia <product> and can be found in the build output directory. The `--oem-stage` option can be supplied multiple times for several OEM files. The format expects a single OEM command to execute after staging the given file. The format for the `--oem-stage` parameter is a comma separated pair: '<OEM_COMMAND>,<FILE_TO_STAGE>'

get-ssh-address


Usage: ffx target get-ssh-address [-t <timeout>] Get the target's ssh address

Options:


-t, --timeout the timeout in seconds [default = 1.0] --help display usage information Notes: Return the SSH address of the default target defined in the `target.default` key. By default this comes from the 'User Configuration'. The command takes a <timeout> value in seconds with a default of `1.0` and overrides the value in the `target.interaction.timeout` key. Error codes: 1 Timeout while getting ssh address

list


Usage: ffx target list [<nodename>] [-f <format>] List all targets

Options:


-f, --format determines the output format for the list operation --help display usage information Examples: To list targets in short form: $ ffx target list --format s fe80::4415:3606:fb52:e2bc%zx-f80ff974f283 pecan-guru-clerk-rhyme To list targets with only their addresses: $ ffx target list --format a fe80::4415:3606:fb52:e2bc%zx-f80ff974f283 Notes: List all targets that the daemon currently has in memory. This includes manually added targets. The daemon also proactively discovers targets as they come online. Use `ffx target list` to always get the latest list of targets. The default target is marked with a '*' next to the node name. The table has the following columns: NAME = The name of the target. TYPE = The product type of the target, currently always 'Unknown'. STATE = The high-level state of the target, currently always 'Unknown'. AGE = Shows the last time the daemon was able to discover the target. ADDRS/IP = The discovered and known addresses of the target. RCS = Indicates if the Remote Control Service is running on the target. The NAME column shows the target's advertised name. When the target is in early boot state such as fastboot, shows 'FastbootDevice' with the `product` and `serial` attributes instead. By default, the `list` command outputs in a tabular format. To override the format, pass `--format` and can take the following options: 'simple' , 'tabular|table|tab', 'addresses|addrs|addr', 'name-only', 'json|JSON' or in short form 's', 't', 'a', 'n', 'j'. Error codes: 2 If a nodename is supplied, an error code of 2 will be returned if the nodename cannot be resolved

log


Usage: ffx target log [--filter <filter...>] [--exclude <exclude...>] [--color <color>] [--ignore-symbolizer-failure] [--show-process-info] [--time <time>] [--moniker <moniker...>] [--exclude-moniker <exclude-moniker...>] [--min-severity <min-severity>] <command> [<args>] Display logs from a target device

Options:


--filter filter for a string in either the message, component or url. --exclude exclude a string in either the message, component or url. --color toggle coloring logs according to severity --ignore-symbolizer-failure ignore any failure to find the symbolizer binary. --show-process-info shows process-id and thread-id in log output --time how to display log timestamps --moniker filter log entries using component selectors --exclude-moniker exclude log entries matching a component selector --min-severity set the minimum severity --help display usage information

Commands:


watch Watches for and prints logs from a target. Optionally dumps recent logs first. dump Dumps all logs from a target. Examples: Dump the most recent logs and stream new ones as they happen: $ ffx target log watch Stream new logs without dumping recent ones, filtering for severity of at least "WARN": $ ffx target log --min-severity warn watch --dump false Dump all logs from components with a moniker, url, or message containing "remote-control": $ ffx target log --filter remote-control dump Stream logs from components with moniker, url or message that do not include "sys": $ ffx target log --exclude sys watch Dump ERROR logs with moniker, url or message containing either "klog" or "remote-control.cm", but which do not contain "sys": $ ffx target log --min-severity error --filter klog --filter remote-control.cm --exclude sys dump Dump logs with monikers matching component selectors, instead of text matches: $ ffx target log --moniker "core/remote-*" --exclude-moniker "sys/*" dump Notes: Filters must be provided to the top-level `target log` command, *not* to the sub-command (see examples above) The `--moniker` argument expects a component selector. See this page for documentation: https://fuchsia.dev/reference/fidl/fuchsia.diagnostics#ComponentSelector. You may find the `component select` command useful for exploring the topology and identifying the selector that matches the component(s) of interest.

dump


Usage: ffx target log dump [--from <from>] [--from-monotonic <from-monotonic>] [--to <to>] [--to-monotonic <to-monotonic>] Dumps all logs from a target.

Options:


--from show only logs after a certain time --from-monotonic show only logs after a certain time (as a monotonic timestamp in seconds from the target). --to show only logs until a certain time --to-monotonic show only logs until a certain time (as a monotonic timestamp in seconds from the target). --help display usage information

recent


Unrecognized argument: recent

watch


Usage: ffx target log watch [--dump <dump>] Watches for and prints logs from a target. Optionally dumps recent logs first.

Options:


--dump if true, dumps recent logs before printing new ones. --help display usage information

off


Usage: ffx target off Powers off a target

Options:


--help display usage information Notes: Power off a target. Uses the 'fuchsia.hardware.power.statecontrol.Admin' FIDL API to send the power off command. The 'fuchsia.hardware.power.statecontrol.Admin' is exposed via the 'appmgr' component. To verify that the target exposes this service, `ffx component select` or `ffx component knock` can be used. Error codes: 1 Timeout while powering off target.

reboot


Usage: ffx target reboot [-b] [-r] Reboots a target

Options:


-b, --bootloader reboot to bootloader -r, --recovery reboot to recovery --help display usage information Notes: Reboot a target. Uses the 'fuchsia.hardware.power.statecontrol.Admin' FIDL API to send the reboot command. By default, target boots fully. This behavior can be overrided by passing in either `--bootloader` or `--recovery` to boot into the bootloader or recovery, respectively. The 'fuchsia.hardware.power.statecontrol.Admin' is exposed via the 'appmgr' component. To verify that the target exposes this service, `ffx component select` or `ffx component knock` can be used. Error codes: 1 Timeout while powering off target.

remove


Usage: ffx target remove <id> Make the daemon forget a specific target

Options:


--help display usage information Examples: To remove a target by its target name: $ ffx target remove correct-horse-battery-staple Or to remove a target using its IP address: $ ffx target remove fe80::32fd:38ff:fea8:a00a Notes: IP addresses are matched by their full string representation. for best results, copy the exact address from ffx target list.

show


Usage: ffx target show [--desc] [--label] [--json] [--version] Display relevant information for the target

Options:


--desc display descriptions of entries --label display label of entries --json formats output as json objects --version display version --help display usage information Notes: Displays a detailed iformation about the target. The default output is intended for a human reader. This output can be decorated with machine readable labels (--label) and descriptions of each field (--desc). The 'label' fields in the machine readable output (--json) will remain stable across software updates and is not localized (compare to 'title' which may change or be localized). The 'value' field will be one of: 'null', 'bool', 'string', or a list of strings. Error codes: 1 Timeout retrieving target information.

snapshot


Usage: ffx target snapshot [-d <dir>] [--dump-annotations] Takes a snapshot of the target's state

Options:


-d, --dir valid directory where the snapshot will be stored. --dump-annotations print annotations --help display usage information Examples: Store the target's snapshot in the current directory: $ ffx target snapshot -d . Exported ./snapshot.zip Notes: This command connects to a running target to acquire its snapshot, which contains useful debugging information about the target. The `--dir` can be supplied to override the default snapshot directory `/tmp/snapshots/YYYYMMDD_HHMMSS/`. Snapshot contents: - Build information and annotations - Kernel and system logs - Inspect data

update


Usage: ffx target update <command> [<args>] Update base system software on target

Options:


--help display usage information

Commands:


channel View and manage update channels check-now Check and perform the system update operation force-install Trigger the system updater manually Notes: This command interfaces with system update services on the target.

channel


Usage: ffx target update channel <command> [<args>] View and manage update channels

Options:


--help display usage information

Commands:


get-current Return the currently configured update channel get-next Return the next or target update channel set Sets the update channel list List the known update channels Notes: Channel management commands and operations. Interfaces directly with the 'fuchsia.update.channelcontrol.ChannelControl' service on the target system.
get-current

Usage: ffx target update channel get-current Return the currently configured update channel

Options:


--help display usage information Notes: For developer product configurations, this is by default 'devhost'. Error codes: 1 Timeout while getting update channel.
get-next

Usage: ffx target update channel get-next Return the next or target update channel

Options:


--help display usage information Notes: Returns the next or target channel. This differs from `get` when the next successful update changes the configured update channel on the system. Error codes: 1 Timeout while getting update channel.
list

Usage: ffx target update channel list List the known update channels

Options:


--help display usage information Notes: This lists all the known next or target update channels on the system. Returns an empty list if no other update channels are configured. Error codes: 1 Timeout while getting list of update channel.
set

Usage: ffx target update channel set <channel> Sets the update channel

Options:


--help display usage information Examples: To list all the known update channels: $ ffx target update channel list Then, use a valid channel from the list: $ ffx target update channel set <channel> Notes: Sets the next or target update channel on the device. When paired with `ffx target update check-now`, ensures the update is check against the next or target channel. When the update is successful, next or target channel becomes the current channel. Use `ffx target update channel list` to list known system update channels. Error codes: 1 Timeout while setting update channel.

check-now


Usage: ffx target update check-now [--service-initiated] [--monitor] Check and perform the system update operation

Options:


--service-initiated the update check was initiated by a service, in the background. --monitor monitor for state update. --help display usage information Examples: To check for update and monitor progress: $ ffx target update check-now --monitor Notes: Triggers an update check operation and performs the update if available. Interfaces using the 'fuchsia.update Manager' protocol with the system update service on the target. The command takes in an optional `--monitor` switch to watch the progress of the update. The output is displayed in `stdout`. The command also takes an optional `--service-initiated` switch to indicate a separate service has initiated a check for update.

force-install


Usage: ffx target update force-install <update_pkg_url> [--reboot <reboot>] Trigger the system updater manually

Options:


--reboot automatically trigger a reboot into the new system --help display usage information Examples: With a known update package URL, trigger an update: $ ffx target update force-install fuchsia-pkg://fuchsia.com/update Also trigger a reboot after update: $ ffx target update force-install fuchsia-pkg://fuchsia.com/update --reboot Notes: Directly invoke the system updater to install the provided update, bypassing any update checks. Interfaces using the 'fuchsia.update.installer' protocol to update the system. Requires an <update_pkg_url> in the following format: `fuchsia-pkg://fuchsia.com/update` Takes an optional `--reboot <true|false>` to trigger a system reboot after update has been successfully applied.

wait


Usage: ffx target wait [-t <timeout>] Wait until the target becomes available.

Options:


-t, --timeout the timeout in seconds [default = 60] --help display usage information Error codes: 1 Timeout while getting ssh address

test


Usage: ffx test <command> [<args>] Run test suite

Options:


--help display usage information

Commands:


run Run test suite list List test suite cases result Manage test results Notes: Run tests or inspect output from a previous test run.

list


Usage: ffx test list <test_url> List test suite cases

Options:


--help display usage information Notes: Lists the set of test cases available in a test suite

result


Usage: ffx test result <command> [<args>] Manage test results

Options:


--help display usage information

Commands:


show Display test results list List test results delete Delete test results save Save test results Notes: Inspect and manage the results from previous test runs

delete


Usage: ffx test result delete [--index <index>] [--name <name>] Delete test results

Options:


--index when set, display the results of a run with specified index. --name when set, display the results of a run with specified name. --help display usage information Notes: Manually delete a previous test run result. Either --index or --name must be specified.

list


Usage: ffx test result list List test results

Options:


--help display usage information Notes: Display a list of previous test runs

save


Usage: ffx test result save --index <index> --name <name> Save test results

Options:


--index the index of the test result to save. --name the name to assign the saved test result. --help display usage information Notes: Mark a test result so it is not garbage collected. By default, ffx test only retains the last 'n' test results, as configured with 'test.save_count'. A test result saved and given a name using the save command will be exempted from this cleanup and will not be counted towards the total number of saved test results.

show


Usage: ffx test result show [--directory <directory>] [--index <index>] [--name <name>] Display test results

Options:


--directory when set, display the results of the specified directory. --index when set, display the results of a run with specified index. --name when set, display the results of a run with specified name. --help display usage information Notes: Display the results of a previous test run. When no options are provided, displays the results of the most recent test run.

run


Usage: ffx test run <test_url> [-t <timeout>] [--test-filter <test-filter...>] [--run-disabled] [--filter-ansi] [--parallel <parallel>] [--count <count>] [--min-severity-logs <min-severity-logs>] [--max-severity-logs <max-severity-logs>] [--output-directory <output-directory>] [--disable-output-directory] Run test suite

Options:


-t, --timeout test timeout --test-filter glob pattern for matching tests. Can be specified multiple times to pass in multiple patterns. example: --test-filter glob1 --test-filter glob2. --run-disabled run tests that have been marked disabled/ignored --filter-ansi filter ANSI escape sequences from output --parallel run tests in parallel --count number of times to run the test [default = 1] --min-severity-logs when set, only logs with a severity equal to the given one or higher will be printed. --max-severity-logs when set, the test will fail if any log with a higher severity is emitted. --output-directory when set, output test results to the specified directory. --disable-output-directory when set, disables structured output to a directory. --help display usage information Notes: Runs a test or suite implementing the `fuchsia.test.Suite` protocol. Note that if running multiple iterations of a test and an iteration times out, no further iterations will be executed.

trace


Usage: ffx trace <command> [<args>] Interact with the tracing subsystem

Options:


--help display usage information

Commands:


list-providers List the target's trace providers start Record a trace stop Record a trace

list-providers


Usage: ffx trace list-providers List the target's trace providers

Options:


--help display usage information

start


Usage: ffx trace start [--buffer-size <buffer-size>] [--categories <categories>] [--duration <duration>] [--output <output>] Record a trace

Options:


--buffer-size size of per-provider trace buffer in MB. Defaults to 4. --categories comma-separated list of categories to enable. Defaults to "app,audio,benchmark,blobfs,gfx,input,kernel:meta, kernel:sched,ledger,magma,minfs,modular,view,flutter, dart,dart:compiler,dart:dart,dart:debugger,dart:embedder, dart:gc,dart:isolate,dart:profiler,dart:vm" --duration duration of trace capture in seconds. If not set, interactive mode is used. --output name of output trace file. Defaults to trace.fxt. --help display usage information

stop


Usage: ffx trace stop [--output <output>] Record a trace

Options:


--output name of output trace file. Defaults to trace.fxt. --help display usage information

version


Usage: ffx version [-v] Print out ffx tool and daemon versions

Options:


-v, --verbose if true, includes details about both ffx and the daemon --help display usage information