| /freebsd-13.1/sys/contrib/openzfs/lib/libspl/os/linux/ |
| H A D | gethostid.c | 36 unsigned long hostid; in get_spl_hostid() local 50 if (fscanf(f, "%lx", &hostid) != 1) in get_spl_hostid() 51 hostid = 0; in get_spl_hostid() 55 return (hostid); in get_spl_hostid() 61 unsigned long hostid = get_spl_hostid(); in get_system_hostid() local 69 if (hostid == 0) { in get_system_hostid() 72 if (read(fd, &hostid, 4) < 0) in get_system_hostid() 73 hostid = 0; in get_system_hostid() 78 return (hostid & HOSTID_MASK); in get_system_hostid()
|
| /freebsd-13.1/lib/libc/compat-43/ |
| H A D | sethostid.c | 44 sethostid(long hostid) in sethostid() argument 50 sysctl(mib, 2, NULL, NULL, &hostid, sizeof hostid); in sethostid()
|
| /freebsd-13.1/sys/contrib/openzfs/contrib/dracut/90zfs/ |
| H A D | module-setup.sh.in | 38 dracut_install hostid 97 if [ -f @sysconfdir@/hostid ]; then 98 inst @sysconfdir@/hostid 99 type mark_hostonly >/dev/null 2>&1 && mark_hostonly @sysconfdir@/hostid 102 type mark_hostonly >/dev/null 2>&1 && mark_hostonly @sysconfdir@/hostid
|
| /freebsd-13.1/sys/contrib/openzfs/tests/zfs-tests/tests/functional/mmp/ |
| H A D | mmp.kshlib | 80 typeset hostid=$1 84 if [ $(hostid) != "$hostid" ]; then 156 typeset hostid=$2 159 log_must mmp_set_hostid $hostid
|
| H A D | mmp_hostid.ksh | 65 log_must mv $HOSTID_FILE $mntpnt_etc/hostid 75 log_must ln -s $mntpnt_etc/hostid $HOSTID_FILE
|
| H A D | mmp.cfg | 24 export HOSTID_FILE="/etc/hostid"
|
| /freebsd-13.1/contrib/bsnmp/snmpd/ |
| H A D | action.c | 93 char *hostid; in init_actvals() local 106 if ((hostid = act_getkernint(KERN_HOSTID)) == NULL) in init_actvals() 110 len += strlen(hostid) + 1; in init_actvals() 115 free(hostid); in init_actvals() 140 free(hostid); in init_actvals() 151 char *hostid; in init_snmpd_engine() local 164 if ((hostid = act_getkernint(KERN_HOSTID)) == NULL) in init_snmpd_engine() 169 hostid, SNMP_ENGINE_ID_SIZ - snmpd_engine.engine_len); in init_snmpd_engine() 173 hostid, strlen(hostid)); in init_snmpd_engine() 174 snmpd_engine.engine_len += strlen(hostid); in init_snmpd_engine() [all …]
|
| /freebsd-13.1/sbin/hastd/ |
| H A D | parse.y | 734 unsigned long hostid; variable 771 bufsize = sizeof(hostid); 772 if (sysctlbyname("kern.hostid", &hostid, &bufsize, NULL, 0) < 0) { 776 (void)snprintf(buf, sizeof(buf), "hostid%lu", hostid); 804 unsigned long hostid; in node_names() local 835 bufsize = sizeof(hostid); in node_names() 836 if (sysctlbyname("kern.hostid", &hostid, &bufsize, NULL, 0) < 0) { in node_names() 840 (void)snprintf(buf, sizeof(buf), "hostid%lu", hostid); in node_names()
|
| /freebsd-13.1/sys/contrib/openzfs/cmd/zgenhostid/ |
| H A D | zgenhostid.c | 133 uint32_t hostid = input_i; in main() local 134 int written = fwrite(&hostid, 1, 4, fp); in main()
|
| /freebsd-13.1/sys/contrib/openzfs/lib/libzfs/ |
| H A D | libzfs_status.c | 235 uint64_t hostid = 0; in check_status() local 323 (void) nvlist_lookup_uint64(config, ZPOOL_CONFIG_HOSTID, &hostid); in check_status() 324 if (hostid != 0 && (unsigned long)hostid != system_hostid && in check_status()
|
| /freebsd-13.1/sys/contrib/openzfs/contrib/dracut/ |
| H A D | README.dracut.markdown | 42 by the zfs module. This can save you a trip to a bootcd if hostid has 48 * `spl_hostid`: By default, the hostid used by the SPL module is read from 49 /etc/hostid inside the initramfs. This file is placed there from the host 51 host which builds it. If a different hostid is desired, one may be set in 53 format should be hex exactly as found in the `/etc/hostid` file, IE 56 Note that changing the hostid between boots will most likely lead to an 57 un-importable pool since the last importing hostid won't match. In order 60 before rebooting with the new hostid. 93 and z* programs. Also triggers inclusion of `/etc/hostid` and the zpool 134 Currently this file also includes `/etc/hostid` and `/etc/zfs/zpool.cache` [all …]
|
| /freebsd-13.1/sys/contrib/openzfs/module/os/linux/spl/ |
| H A D | spl-generic.c | 640 hostid_read(uint32_t *hostid) in hostid_read() argument 678 *hostid = (value & HW_HOSTID_MASK); in hostid_read() 691 uint32_t hostid; in zone_get_hostid() local 698 if (hostid_read(&hostid) == 0) in zone_get_hostid() 699 return (hostid); in zone_get_hostid()
|
| /freebsd-13.1/sys/net/ |
| H A D | if_epair.c | 482 uint64_t hostid; in epair_clone_create() local 619 getcredhostid(curthread->td_ucred, (unsigned long *)&hostid); in epair_clone_create() 620 if (hostid == 0) in epair_clone_create() 621 arc4rand(&hostid, sizeof(hostid), 0); in epair_clone_create() 631 key[1] = (uint32_t)(hostid & 0xffffffff); in epair_clone_create() 632 key[2] = (uint32_t)((hostid >> 32) & 0xfffffffff); in epair_clone_create()
|
| /freebsd-13.1/sys/contrib/openzfs/module/zfs/ |
| H A D | spa_config.c | 403 unsigned long hostid = 0; in spa_config_generate() local 454 hostid = spa_get_hostid(spa); in spa_config_generate() 455 if (hostid != 0) in spa_config_generate() 456 fnvlist_add_uint64(config, ZPOOL_CONFIG_HOSTID, hostid); in spa_config_generate()
|
| /freebsd-13.1/sbin/pfctl/tests/files/ |
| H A D | pf0022.in | 8 set hostid 1
|
| H A D | pf0022.ok | 10 set hostid 0x00000001
|
| H A D | pf0055.in | 11 set hostid 1
|
| H A D | pf0055.ok | 22 set hostid 0x00000001
|
| /freebsd-13.1/sbin/nvmecontrol/ |
| H A D | resv.c | 420 e->ctrlr[i].hostid[0], e->ctrlr[i].hostid[1]); in resvreport() 430 s->ctrlr[i].hostid); in resvreport()
|
| /freebsd-13.1/sys/dev/altera/atse/ |
| H A D | if_atse.c | 550 unsigned long hostid; in atse_get_eth_address() local 646 getcredhostid(curthread->td_ucred, &hostid); in atse_get_eth_address() 647 if (hostid == 0) { in atse_get_eth_address() 653 sc->atse_eth_addr[1] = (hostid >> 24) & 0xff; in atse_get_eth_address() 654 sc->atse_eth_addr[2] = (hostid >> 16) & 0xff; in atse_get_eth_address() 655 sc->atse_eth_addr[3] = (hostid >> 8 ) & 0xff; in atse_get_eth_address() 656 sc->atse_eth_addr[4] = hostid & 0xff; in atse_get_eth_address()
|
| /freebsd-13.1/libexec/rc/ |
| H A D | netstart | 40 /etc/rc.d/hostid ${_start}
|
| /freebsd-13.1/libexec/rc/rc.d/ |
| H A D | hostid | 56 ${SYSCTL} kern.hostid=${id} >/dev/null
|
| /freebsd-13.1/sys/rpc/rpcsec_gss/ |
| H A D | svc_rpcsec_gss.c | 537 unsigned long hostid; in svc_rpc_gss_find_client() local 541 getcredhostid(curthread->td_ucred, &hostid); in svc_rpc_gss_find_client() 543 if (id->ci_hostid != hostid || id->ci_boottime != boottime.tv_sec) in svc_rpc_gss_find_client() 572 unsigned long hostid; in svc_rpc_gss_create_client() local 585 getcredhostid(curthread->td_ucred, &hostid); in svc_rpc_gss_create_client() 586 client->cl_id.ci_hostid = hostid; in svc_rpc_gss_create_client()
|
| /freebsd-13.1/sys/kern/ |
| H A D | kern_xxx.c | 101 return (kernel_sysctl(td, name, 2, NULL, NULL, &uap->hostid, in osethostid() 102 sizeof(uap->hostid), NULL, 0)); in osethostid()
|
| /freebsd-13.1/sys/contrib/openzfs/lib/libzutil/ |
| H A D | zutil_import.c | 474 uint64_t hostid; in get_configs() local 594 hostid = 0; in get_configs() 596 ZPOOL_CONFIG_HOSTID, &hostid) == 0) { in get_configs() 598 ZPOOL_CONFIG_HOSTID, hostid); in get_configs() 845 if (hostid != 0) { in get_configs() 847 hostid) == 0); in get_configs()
|