diff options
author | наб <[email protected]> | 2022-01-12 17:29:50 +0100 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2022-02-01 16:56:31 -0800 |
commit | bde0f7d4c6bc668528ee6183e5a1d54bb00f790a (patch) | |
tree | c3d295d9b5f52d6aaa8a2a15a6cb0e3d4281746d /cmd | |
parent | 0f7a0cc7c2e27f0e13f3efd02b8888187c7f4596 (diff) |
zpool: main: print hostids with PRIx64
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Ahelenia Ziemiańska <[email protected]>
Closes #12968
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/zpool/zpool_main.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/cmd/zpool/zpool_main.c b/cmd/zpool/zpool_main.c index 579839c36..c41c7e4c1 100644 --- a/cmd/zpool/zpool_main.c +++ b/cmd/zpool/zpool_main.c @@ -3039,9 +3039,8 @@ show_import(nvlist_t *config, boolean_t report_error) ZPOOL_CONFIG_MMP_HOSTID); (void) printf(gettext(" action: The pool must be " - "exported from %s (hostid=%lx)\n\tbefore it " - "can be safely imported.\n"), hostname, - (unsigned long) hostid); + "exported from %s (hostid=%"PRIx64")\n\tbefore it " + "can be safely imported.\n"), hostname, hostid); break; case ZPOOL_STATUS_HOSTID_REQUIRED: (void) printf(gettext(" action: Set a unique system " @@ -3170,9 +3169,9 @@ do_import(nvlist_t *config, const char *newname, const char *mntopts, (void) fprintf(stderr, gettext("cannot import '%s': " "pool is imported on %s (hostid: " - "0x%lx)\nExport the pool on the other system, " - "then run 'zpool import'.\n"), - name, hostname, (unsigned long) hostid); + "0x%"PRIx64")\nExport the pool on the other " + "system, then run 'zpool import'.\n"), + name, hostname, hostid); } else if (mmp_state == MMP_STATE_NO_HOSTID) { (void) fprintf(stderr, gettext("Cannot import '%s': " "pool has the multihost property on and the\n" @@ -3197,10 +3196,10 @@ do_import(nvlist_t *config, const char *newname, const char *mntopts, (void) fprintf(stderr, gettext("cannot import '%s': " "pool was previously in use from another system.\n" - "Last accessed by %s (hostid=%lx) at %s" + "Last accessed by %s (hostid=%"PRIx64") at %s" "The pool can be imported, use 'zpool import -f' " "to import the pool.\n"), name, hostname, - (unsigned long)hostid, ctime(×tamp)); + hostid, ctime(×tamp)); } return (1); |