Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sled-agent-sim and docs need update for IPv6 requirement #919

Merged
merged 3 commits into from
Apr 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions docs/how-to-run-simulated.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,7 @@ Nexus can also serve the web console. Instructions for generating the static ass
+
[source,text]
----
$ cargo run --bin=sled-agent-sim -- $(uuidgen) 127.0.0.1:12345 127.0.0.1:12221
...
Jun 02 12:21:50.989 INFO listening, local_addr: 127.0.0.1:12345, component: dropshot
$ cargo run --bin=sled-agent-sim -- $(uuidgen) [::1]:12345 127.0.0.1:12221
----

. `oximeter` is similar to `nexus`, requiring a configuration file. You can use `oximeter/collector/config.toml`, and the whole thing can be run with:
Expand Down
7 changes: 4 additions & 3 deletions sled-agent/src/bin/sled-agent-sim.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ use omicron_sled_agent::sim::{
run_server, Config, ConfigStorage, ConfigZpool, SimMode,
};
use std::net::SocketAddr;
use std::net::SocketAddrV6;
use structopt::StructOpt;
use uuid::Uuid;

Expand Down Expand Up @@ -44,7 +45,7 @@ struct Args {
uuid: Uuid,

#[structopt(name = "SA_IP:PORT", parse(try_from_str))]
sled_agent_addr: SocketAddr,
sled_agent_addr: SocketAddrV6,

#[structopt(name = "NEXUS_IP:PORT", parse(try_from_str))]
nexus_addr: SocketAddr,
Expand All @@ -67,15 +68,15 @@ async fn do_run() -> Result<(), CmdError> {
sim_mode: args.sim_mode,
nexus_address: args.nexus_addr,
dropshot: ConfigDropshot {
bind_address: args.sled_agent_addr,
bind_address: args.sled_agent_addr.into(),
request_body_max_bytes: 1024 * 1024,
..Default::default()
},
log: ConfigLogging::StderrTerminal { level: ConfigLoggingLevel::Info },
storage: ConfigStorage {
// Create 10 "virtual" U.2s, with 1 TB of storage.
zpools: vec![ConfigZpool { size: 1 << 40 }; 10],
ip: args.sled_agent_addr.ip(),
ip: (*args.sled_agent_addr.ip()).into(),
},
};

Expand Down