diff --git a/cli/command/system/info.go b/cli/command/system/info.go index 1780487111..1d57f3f5ca 100644 --- a/cli/command/system/info.go +++ b/cli/command/system/info.go @@ -426,7 +426,6 @@ func printServerWarnings(dockerCli command.Cli, info types.Info) { return } // daemon didn't return warnings. Fallback to old behavior - printStorageDriverWarnings(dockerCli, info) printServerWarningsLegacy(dockerCli, info) } @@ -494,51 +493,6 @@ func printServerWarningsLegacy(dockerCli command.Cli, info types.Info) { } } -// printStorageDriverWarnings generates warnings based on storage-driver information -// returned by the daemon. -// DEPRECATED: warnings are now generated by the daemon, and returned in -// info.Warnings. This function is used to provide backward compatibility with -// daemons that do not provide these warnings. No new warnings should be added -// here. -func printStorageDriverWarnings(dockerCli command.Cli, info types.Info) { - if info.OSType == "windows" { - return - } - if info.DriverStatus == nil { - return - } - for _, pair := range info.DriverStatus { - if pair[0] == "Data loop file" { - fmt.Fprintf(dockerCli.Err(), "WARNING: %s: usage of loopback devices is "+ - "strongly discouraged for production use.\n "+ - "Use `--storage-opt dm.thinpooldev` to specify a custom block storage device.\n", info.Driver) - } - if pair[0] == "Supports d_type" && pair[1] == "false" { - backingFs := getBackingFs(info) - - msg := fmt.Sprintf("WARNING: %s: the backing %s filesystem is formatted without d_type support, which leads to incorrect behavior.\n", info.Driver, backingFs) - if backingFs == "xfs" { - msg += " Reformat the filesystem with ftype=1 to enable d_type support.\n" - } - msg += " Running without d_type support will not be supported in future releases." - fmt.Fprintln(dockerCli.Err(), msg) - } - } -} - -func getBackingFs(info types.Info) string { - if info.DriverStatus == nil { - return "" - } - - for _, pair := range info.DriverStatus { - if pair[0] == "Backing Filesystem" { - return pair[1] - } - } - return "" -} - func formatInfo(dockerCli command.Cli, info info, format string) error { // Ensure slice/array fields render as `[]` not `null` if info.ClientInfo != nil && info.ClientInfo.Plugins == nil {