summaryrefslogtreecommitdiff
path: root/utilities
Commit message (Collapse)AuthorAgeFilesLines
* ovs-vsctl: Fix typo in documentation.Ben Pfaff2011-09-201-1/+1
| | | | | | | I don't know what was really supposed to go here. Documentation #7371. Reported-by: Reid Price <reid@nicira.com>
* ovs-ofctl: Clarify in_port in manpage.Ben Pfaff2011-09-191-1/+6
| | | | | Suggestion #7370. Suggested-by: Reid Price <reid@nicira.com>
* datapath: Always use generic stats for devices (vports)Pravin Shelar2011-09-151-17/+30
| | | | | | | | | | | | | | | Currently ovs is using device stats for Linux devices and count them itself in other situations. This leads to overlap with hardware stats, inconsistencies, etc. It's much better to just always count the packets flowing through the switch and let userspace do any merging that it wants. Following patch removes vport->get_stats() interface. vport-stat is changed to use new `struct ovs_vport_stat` rather than rtnl_link_stats64. Definitions of rtnl_link_stats64 is removed from OVS. dipf_port->stat is also removed as aggregate stats are only available at netdev layer. Signed-off-by: Pravin B Shelar <pshelar@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com>
* ovs-vsctl: Improve usage message.Ben Pfaff2011-09-151-6/+6
| | | | | Bug #7332. Reported-by: Gordon Good <ggood@nicira.com>
* bugtool: Remove "ovs-bugtool" upon "make clean", to fix "make distcheck".Ben Pfaff2011-09-151-0/+1
|
* bugtool: Uninstall plugins on "make uninstall".Ben Pfaff2011-09-151-0/+12
| | | | This works toward making "make distcheck" succeed.
* Implement new "learn" action.Ben Pfaff2011-09-131-0/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | There are a few loose ends here. First, learning actions cause too much flow revalidation. Upcoming commits will fix that problem. The following additional issues have not yet been addressed: * Resource limits: nothing yet limits the maximum number of flows that can be learned. It is possible to exhaust all system memory. * Age reporting: there is no way to find out how soon a learned table entry is due to be evicted. To try this action out, here's a recipe for a very simple-minded MAC learning switch. It uses a 10-second MAC expiration time to make it easier to see what's going on: ovs-vsctl del-controller br0 ovs-ofctl del-flows br0 ovs-ofctl add-flow br0 "table=0 actions=learn(table=1, hard_timeout=10, \ NXM_OF_VLAN_TCI[0..11], NXM_OF_ETH_DST[]=NXM_OF_ETH_SRC[], \ output:NXM_OF_IN_PORT[]), resubmit(,1)" ovs-ofctl add-flow br0 "table=1 priority=0 actions=flood" You can then dump the MAC learning table with: ovs-ofctl dump-flows br0 table=1
* ovs-ctl: Add load-kmod commandSimon Horman2011-09-082-5/+31
| | | | | | | | | | On Debian there is a need for the init scripts to die gracefully if module insertion fails. In such a case it is desirable to print some sort of informative message. By adding the load-kmod sub-command to ovs-ctl init scripts may try to load modules and take appropriate action on failure or then try to start the daemons.
* docs: Add Makefile rule to check syntax of manpages.Ben Pfaff2011-08-241-1/+1
| | | | | This should catch future nroff syntax errors immediately, instead of much later.
* docs: Fix some manpage syntax errors found with "groff".Ben Pfaff2011-08-241-1/+1
|
* doc: Add spaces between commas to avoid overflowing line during formatting.Ben Pfaff2011-08-241-4/+4
| | | | | | | | This resolves a warning reported as "71: warning [p 11, 5.0i]: cannot adjust line" Reported-by: Simon Horman <horms@verge.net.au> Found by lintian.
* docs: Add missing escapeSimon Horman2011-08-241-1/+1
| | | | | | | | | This adds what appears to be a missing character to an escape sequence. This resolves a problem reported as "a newline character is not allowed in an escape name". Reported by lintian
* datapath: Use "OVS_*" as opposed to "ODP_*" for user<->kernel interactions.Justin Pettit2011-08-191-1/+1
| | | | | | | | | | | | | The prefix "ODP_*" is not overly descriptive in the context of the larger Linux tree. This commit changes the prefix to "OVS_*" for the userpace to kernel interactions. The userspace libraries still use "ODP_" in many of their interfaces since it is more descriptive in the OVS oeuvre. Feature #6904 Signed-off-by: Justin Pettit <jpettit@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com>
* ovs-ofctl: Fix a few formatting typos in manpage.Ben Pfaff2011-08-151-4/+4
|
* nicra-ext: New action NXAST_OUTPUT_REG.Ethan Jackson2011-08-121-1/+8
| | | | | The NXAST_OUTPUT_REG action outputs to the OpenFlow port contained in a supplied NXM field.
* ovs-ofctl: Document that all actions are supported now.Ben Pfaff2011-08-111-4/+0
| | | | | This comment must be very old. ovs-ofctl has supported all the OpenFlow and Nicira extensions actions for a long time now.
* ofp-util: Rename struct flow_stats_request with ofputil_ prefix.Ben Pfaff2011-08-091-2/+2
| | | | | Most of the structs in ofp-util.h have the ofputil_ prefix. Rename this one for consistency.
* ofp-util: Rename struct flow_mod to struct ofputil_flow_mod.Ben Pfaff2011-08-091-2/+2
| | | | | Most of the structs in ofp-util.h have the ofputil_ prefix. Rename this one for consistency.
* ovs-ofctl: Fix reading flows from file for "replace-flows", "diff-flows".Ben Pfaff2011-08-091-4/+2
| | | | | | Commit c821124b25e "ovs-ofctl: Accept only valid flow_mod and flow_stats_request fields" caused actions read by read_flows_from_file() to be ignored and treated as "drop". This fixes the problem.
* New action NXAST_RESUBMIT_TABLE.Ben Pfaff2011-08-091-4/+10
| | | | | This makes multiple table support in ofproto-dpif useful, by allowing resubmits into tables other than 0.
* netdev: Get rid of struct netdev_options and netdev_open_default().Ben Pfaff2011-08-081-17/+12
| | | | | Now that netdev_options only has two members, we might as well pass them directly as parameters.
* netdev: Decouple creating and configuring network devices.Ben Pfaff2011-08-081-23/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Until now, each call to netdev_open() for a particular network device had to either specify a set of network device arguments that was either empty or (for devices that already existed) equal to the existing device's configuration. Unfortunately, the definition of "equality" in the latter case was mostly done in terms of strict equality of string-to-string maps, which caused problems in cases where, for example, one set of arguments specified the default value of an optional argument explicitly and the other omitted it. The netdev interface does have provisions for defining equality other ways, but this had only been done in one case that was especially problematic in practice. One way to solve this particular problem would be to carefully define equality in all the problematic cases. This commit takes another approach based on the realization that there is really no need to do any comparisons. Instead, it removes configuration at netdev_open() time entirely, because almost all of netdev_open()'s callers are not interested in creating and configuring a netdev. Most of them just want to open a configured device and use it. Therefore, this commit stops providing any configuration arguments to netdev_open() and the provider functions that it calls. Instead, a caller that does want to configure a device does so after it opens it, by calling netdev_set_config(). This change allows us to simplify the netdev interface a bit. There is no longer any need to implement argument comparisons. As a result, there is also no need for "struct netdev_dev" to keep track of configuration at all. Instead, the network devices that have configuration keep track of it in their own internal form. This new interface does mean that it becomes possible to accidentally create and try to use an unconfigured netdev that requires configuration. Bug #6677. Reported-by: Paul Ingram <paul@nicira.com>
* netdev: Clean up and refactor packet receive interface.Ben Pfaff2011-08-081-2/+0
| | | | | | | | | | | | | | | | | | | | | The Open vSwitch tree only has one user of the ability for a netdev to receive packets from a network device. Thus, this commit simplifies the common-case use of the netdev interface by replacing the "ethertype" option from "struct netdev_options" by a new netdev_listen() call. The only user of netdev_listen() wants to receive all packets from a network device, so this commit also removes the ability to restrict the received packets to a particular protocol. (This ability was once used by the Open vSwitch integrated DHCP client, but that code has been removed.) This commit also simplifies and improves the implementation of the code in netdev-linux that started listening to a network device. Before, I had not figured out how to avoid receiving all packets on all devices before binding to a particular device, but I took a closer look at the kernel code and figured it out. I've tested that the userspace datapath (dpif-netdev), the only user of netdev_recv(), still works after this change.
* ovs-appctl: Add common commands to man page.Justin Pettit2011-08-041-14/+26
| | | | | | The common "help" command was not previously mentioned in the ovs-appctl man page. This commit documents both "help" and the new "version" commands.
* ovs-appctl: Add "version" command to print version of running daemons.Justin Pettit2011-08-041-1/+2
| | | | | | | When debugging a running system, we occasionally see a mismatch of different versions because someone forgets to restart one or more daemons. Often times, it would be useful to know what's running as opposed to what's on the current runpath.
* util: Introduce get_program_version function.Justin Pettit2011-08-047-7/+7
| | | | Useful in an upcoming commit.
* ovs-dpctl: Show number of flowsSimon Horman2011-08-031-0/+1
| | | | | | | | | | | | | | | | | Expose the number of flows present in a datapath to user-space and to users via ovs-dpctl show. e.g.: ovs-dpctl show br3 system@br3: lookups: frags:0, hit:0, missed:0, lost:0 flows: 0 ... Signed-off-by: Simon Horman <horms@verge.net.au> [Jesse: Add same logic to userspace datapath.] Signed-off-by: Jesse Gross <jesse@nicira.com>
* vlog: Move log level definitions from source code to user documentation.Ben Pfaff2011-08-011-1/+30
| | | | | | | Users should be able to find out what a log level means without reading source code comments, so this seems like a better place for it. Reported-by: David Tsai <dtsai@nicira.com>
* vlog: Add a new log level "off".Ben Pfaff2011-08-014-19/+21
| | | | | | | Until now, "emer" has effectively been "off" because no messages were ever logged at "emer" level. Justin points out that it is useful to use "emer" for messages that indicate a fatal error. This commit makes that change and adds a new "off" level to really turn off all logging to a facility.
* ovs-ofctl: Print human readable nx_pull_match() errors.Ethan Jackson2011-07-281-1/+2
| | | | I've found this makes debugging a bit easier.
* git: Update gitignore in tests and utilities.Ethan Jackson2011-07-281-0/+2
|
* ovs-benchmark: New utility.Ben Pfaff2011-07-273-0/+828
|
* ovs-ofctl: Fix dump-ports and queue-stats commands.Ben Pfaff2011-07-271-4/+5
| | | | | | | | | These ovs-ofctl commands have been sending malformed stats requests since commit 63f2140a553 "openflow: Make stats replies more like other OpenFlow messages." This commit fixes the problem and adds basic unit tests that should prevent similar regressions. Reported-by: Hao Zheng <hzheng@nicira.com>
* ovs-ofctl: New --readd option for "replace-flows".Ben Pfaff2011-07-272-2/+20
| | | | | | This is useful for resetting flows' byte and packet counters to 0. Suggested-by: Jed Daniels <openvswitch@jeddaniels.com>
* vswitchd: Prevent multiple ovs-vswitchd processes from acting together.Ben Pfaff2011-07-261-0/+4
| | | | | | Once in a while someone reports a problem caused by running multiple ovs-vswitchd processes at the same time. This fixes the problem by requiring ovs-vswitchd to obtain a database lock before taking any actions.
* debian: Add support for bridge compatibility.Ben Pfaff2011-07-262-30/+101
| | | | | | | This adds support for bridge compatibility to the generic Open vSwitch init scripts and to the Debian packaging. See https://bugs.launchpad.net/ubuntu/+source/openvswitch/+bug/808224.
* ovs-vsctl: Log better warnings for duplicate ports and interfaces.Ben Pfaff2011-07-261-8/+28
| | | | | | | | | | | The database prevents multiple ports or interfaces with a single name, but duplicates can still occur if, for example, two bridges' "ports" columns both point to a single Port record. The existing warning just says in this case that the database contains a duplicate port name. This prompts users to dump the Port table to look for the duplicate. Of course there isn't one, so then they ask me to point out the problem. This commit improves the log message to point out the actual problem.
* utilities: Install ovs-parse-leaks utility by default.Ben Pfaff2011-07-261-2/+2
| | | | | | | | | We install this in the Debian packaging and I don't see a reason not to install it everywhere. (Oddly, we were already installing the manpage everywhere.) Signed-off-by: Ben Pfaff <blp@nicira.com>
* ovs-ctl: Drop back to an empty database if schema conversion fails.Ben Pfaff2011-07-261-5/+17
| | | | | | | | | If the "ovsdb-tool convert" call fails, it is likely because the database has bad contents that this version of OVSDB does not understand. In that case, we're better off using a fresh, empty database rather than failing to come up at all. Bug #6280.
* ovs-ctl: Log messages about database upgrade process.Ben Pfaff2011-07-261-3/+4
| | | | | | This should make problems easier to debug. Bug #6280.
* ovs-parse-leaks: Fix typos in manpage.Ben Pfaff2011-07-251-5/+7
|
* bundle: New action "bundle_load".Ethan Jackson2011-07-221-0/+13
| | | | | The bundle_load action behaves the same as the bundle action, except instead of outputting, it writes its result to a register.
* nx-match: New helpers.Ethan Jackson2011-07-221-2/+2
| | | | | | | | | | | This patch creates two new helper functions, nxm_reg_load() and nxm_dst_check(). The new nxm_dst_check() function may be used to check the validity of destination fields used by actions. The new nxm_reg_load() function may be used by actions which need to write to NXM fields. This patch also allows multipath and autopath to write their result to non-register NXM fields.
* utilities: Add ovs-bugtool to gitignore.Ethan Jackson2011-07-221-0/+1
|
* ovs-ofctl: Use strchr() instead of strstr().Ben Pfaff2011-07-211-1/+1
| | | | It's the right tool for the job. Potentially faster, too.
* ovs-ofctl: Improve error message for "ovs-ofctl show nonexistent".Ben Pfaff2011-07-201-1/+1
| | | | Suggested-by: Peter Balland <peter@nicira.com>
* vswitch: Implement bundle action.Ethan Jackson2011-07-191-0/+16
| | | | | | This patch creates a new action called "bundle". Bundles are a way to implement a simple form of multipath in OpenFlow by grouping several ports in a single output-like action.
* ovs-lib: Allow "status" command to work as non-root.Ben Pfaff2011-07-181-3/+9
|
* ovs-ctl: Start ovs-vswitchd with correct niceness.Ben Pfaff2011-07-181-1/+1
|
* ovs-bugtool: Include conf.db backups in bugtool output.Ben Pfaff2011-07-132-0/+22
| | | | | When an upgrade or downgrade fails due to OVSDB issues, it is useful to have the old versions of the database available.