dhclientのオプション


※上記の広告は60日以上更新のないWIKIに表示されています。更新することで広告が下部へ移動します。

dhclientのオプション@CentOS5


TurbolinuxにあるdhcpcdとCentOSのdhclientのデフォルトのオプションが違うことに気付き同じオプションにしようとするもどこにもオプション一覧が書いてなかった。
仕方ないのでソースから引っ張り出してきた

struct option dhcp_options [256] = {
{ "pad", "",					&dhcp_universe, 0 },
{ "subnet-mask", "I",				&dhcp_universe, 1 },
{ "time-offset", "l",				&dhcp_universe, 2 },
{ "routers", "IA",				&dhcp_universe, 3 },
{ "time-servers", "IA",				&dhcp_universe, 4 },
{ "ien116-name-servers", "IA",			&dhcp_universe, 5 },
{ "domain-name-servers", "IA",			&dhcp_universe, 6 },
{ "log-servers", "IA",				&dhcp_universe, 7 },
{ "cookie-servers", "IA",			&dhcp_universe, 8 },
{ "lpr-servers", "IA",				&dhcp_universe, 9 },
{ "impress-servers", "IA",			&dhcp_universe, 10 },
{ "resource-location-servers", "IA",		&dhcp_universe, 11 },
{ "host-name", "t",				&dhcp_universe, 12 },
{ "boot-size", "S",				&dhcp_universe, 13 },
{ "merit-dump", "t",				&dhcp_universe, 14 },
{ "domain-name", "t",				&dhcp_universe, 15 },
{ "swap-server", "I",				&dhcp_universe, 16 },
{ "root-path", "t",				&dhcp_universe, 17 },
{ "extensions-path", "t",			&dhcp_universe, 18 },
{ "ip-forwarding", "f",				&dhcp_universe, 19 },
{ "non-local-source-routing", "f",		&dhcp_universe, 20 },
{ "policy-filter", "IIA",			&dhcp_universe, 21 },
{ "max-dgram-reassembly", "S",			&dhcp_universe, 22 },
{ "default-ip-ttl", "B",			&dhcp_universe, 23 },
{ "path-mtu-aging-timeout", "L",		&dhcp_universe, 24 },
{ "path-mtu-plateau-table", "SA",		&dhcp_universe, 25 },
{ "interface-mtu", "S",				&dhcp_universe, 26 },
{ "all-subnets-local", "f",			&dhcp_universe, 27 },
{ "broadcast-address", "I",			&dhcp_universe, 28 },
{ "perform-mask-discovery", "f",		&dhcp_universe, 29 },
{ "mask-supplier", "f",				&dhcp_universe, 30 },
{ "router-discovery", "f",			&dhcp_universe, 31 },
{ "router-solicitation-address", "I",		&dhcp_universe, 32 },
{ "static-routes", "IIA",			&dhcp_universe, 33 },
{ "trailer-encapsulation", "f",			&dhcp_universe, 34 },
{ "arp-cache-timeout", "L",			&dhcp_universe, 35 },
{ "ieee802-3-encapsulation", "f",		&dhcp_universe, 36 },
{ "default-tcp-ttl", "B",			&dhcp_universe, 37 },
{ "tcp-keepalive-interval", "L",		&dhcp_universe, 38 },
{ "tcp-keepalive-garbage", "f",			&dhcp_universe, 39 },
{ "nis-domain", "t",				&dhcp_universe, 40 },
{ "nis-servers", "IA",				&dhcp_universe, 41 },
{ "ntp-servers", "IA",				&dhcp_universe, 42 },
{ "vendor-encapsulated-options", "E.",		&dhcp_universe, 43 },
{ "netbios-name-servers", "IA",			&dhcp_universe, 44 },
{ "netbios-dd-server", "IA",			&dhcp_universe, 45 },
{ "netbios-node-type", "B",			&dhcp_universe, 46 },
{ "netbios-scope", "t",				&dhcp_universe, 47 },
{ "font-servers", "IA",				&dhcp_universe, 48 },
{ "x-display-manager", "IA",			&dhcp_universe, 49 },
{ "dhcp-requested-address", "I",		&dhcp_universe, 50 },
{ "dhcp-lease-time", "L",			&dhcp_universe, 51 },
{ "dhcp-option-overload", "B",			&dhcp_universe, 52 },
{ "dhcp-message-type", "B",			&dhcp_universe, 53 },
{ "dhcp-server-identifier", "I",		&dhcp_universe, 54 },
{ "dhcp-parameter-request-list", "BA",		&dhcp_universe, 55 },
{ "dhcp-message", "t",				&dhcp_universe, 56 },
{ "dhcp-max-message-size", "S",			&dhcp_universe, 57 },
{ "dhcp-renewal-time", "L",			&dhcp_universe, 58 },
{ "dhcp-rebinding-time", "L",			&dhcp_universe, 59 },
{ "vendor-class-identifier", "X",		&dhcp_universe, 60 },
{ "dhcp-client-identifier", "X",		&dhcp_universe, 61 },
{ "nwip-domain", "t",				&dhcp_universe, 62 },
{ "nwip-suboptions", "Enwip.",			&dhcp_universe, 63 },
{ "nisplus-domain", "t",			&dhcp_universe, 64 },
{ "nisplus-servers", "IA",			&dhcp_universe, 65 },
{ "tftp-server-name", "t",			&dhcp_universe, 66 },
{ "bootfile-name", "t",				&dhcp_universe, 67 },
{ "mobile-ip-home-agent", "IA",			&dhcp_universe, 68 },
{ "smtp-server", "IA",				&dhcp_universe, 69 },
{ "pop-server", "IA",				&dhcp_universe, 70 },
{ "nntp-server", "IA",				&dhcp_universe, 71 },
{ "www-server", "IA",				&dhcp_universe, 72 },
{ "finger-server", "IA",			&dhcp_universe, 73 },
{ "irc-server", "IA",				&dhcp_universe, 74 },
{ "streettalk-server", "IA",			&dhcp_universe, 75 },
{ "streettalk-directory-assistance-server", "IA", &dhcp_universe, 76 },
{ "user-class", "t",				&dhcp_universe, 77 },
{ "slp-directory-agent", "fIa",			&dhcp_universe, 78 },
{ "slp-service-scope", "fto",			&dhcp_universe, 79 },
{ "unknown-80", "X",				&dhcp_universe, 80 },
{ "fqdn", "Efqdn.",				&dhcp_universe, 81 },
{ "relay-agent-information", "Eagent.",		&dhcp_universe, 82 },
{ "unknown-83", "X",				&dhcp_universe, 83 },
{ "unknown-84", "X",				&dhcp_universe, 84 },
{ "nds-servers", "IA",				&dhcp_universe, 85 },
{ "nds-tree-name", "t",				&dhcp_universe, 86 },
{ "nds-context", "t",				&dhcp_universe, 87 },
{ "unknown-88", "X",				&dhcp_universe, 88 },
{ "unknown-89", "X",				&dhcp_universe, 89 },
{ "unknown-90", "X",				&dhcp_universe, 90 },
{ "unknown-91", "X",				&dhcp_universe, 91 },
{ "unknown-92", "X",				&dhcp_universe, 92 },
{ "unknown-93", "X",				&dhcp_universe, 93 },
{ "unknown-94", "X",				&dhcp_universe, 94 },
{ "unknown-95", "X",				&dhcp_universe, 95 },
{ "unknown-96", "X",				&dhcp_universe, 96 },
{ "unknown-97", "X",				&dhcp_universe, 97 },
{ "uap-servers", "t",				&dhcp_universe, 98 },
{ "unknown-99", "X",				&dhcp_universe, 99 },
{ "unknown-100", "X",				&dhcp_universe, 100 },
{ "unknown-101", "X",				&dhcp_universe, 101 },
{ "unknown-102", "X",				&dhcp_universe, 102 },
{ "unknown-103", "X",				&dhcp_universe, 103 },
{ "unknown-104", "X",				&dhcp_universe, 104 },
{ "unknown-105", "X",				&dhcp_universe, 105 },
{ "unknown-106", "X",				&dhcp_universe, 106 },
{ "unknown-107", "X",				&dhcp_universe, 107 },
{ "unknown-108", "X",				&dhcp_universe, 108 },
{ "unknown-109", "X",				&dhcp_universe, 109 },
{ "unknown-110", "X",				&dhcp_universe, 110 },
{ "unknown-111", "X",				&dhcp_universe, 111 },
{ "unknown-112", "X",				&dhcp_universe, 112 },
{ "unknown-113", "X",				&dhcp_universe, 113 },
{ "unknown-114", "X",				&dhcp_universe, 114 },
{ "unknown-115", "X",				&dhcp_universe, 115 },
{ "unknown-116", "X",				&dhcp_universe, 116 },
{ "unknown-117", "X",				&dhcp_universe, 117 },
{ "subnet-selection", "I",			&dhcp_universe, 118 },
{ "unknown-119", "X",				&dhcp_universe, 119 },
{ "unknown-120", "X",				&dhcp_universe, 120 },
{ "unknown-121", "X",				&dhcp_universe, 121 },
{ "unknown-122", "X",				&dhcp_universe, 122 },
{ "unknown-123", "X",				&dhcp_universe, 123 },
{ "unknown-124", "X",				&dhcp_universe, 124 },
{ "unknown-125", "X",				&dhcp_universe, 125 },
{ "unknown-126", "X",				&dhcp_universe, 126 },
{ "unknown-127", "X",				&dhcp_universe, 127 },
{ "unknown-128", "X",				&dhcp_universe, 128 },
{ "unknown-129", "X",				&dhcp_universe, 129 },
{ "unknown-130", "X",				&dhcp_universe, 130 },
{ "unknown-131", "X",				&dhcp_universe, 131 },
{ "unknown-132", "X",				&dhcp_universe, 132 },
{ "unknown-133", "X",				&dhcp_universe, 133 },
{ "unknown-134", "X",				&dhcp_universe, 134 },
{ "unknown-135", "X",				&dhcp_universe, 135 },
{ "unknown-136", "X",				&dhcp_universe, 136 },
{ "unknown-137", "X",				&dhcp_universe, 137 },
{ "unknown-138", "X",				&dhcp_universe, 138 },
{ "unknown-139", "X",				&dhcp_universe, 139 },
{ "unknown-140", "X",				&dhcp_universe, 140 },
{ "unknown-141", "X",				&dhcp_universe, 141 },
{ "unknown-142", "X",				&dhcp_universe, 142 },
{ "unknown-143", "X",				&dhcp_universe, 143 },
{ "unknown-144", "X",				&dhcp_universe, 144 },
{ "unknown-145", "X",				&dhcp_universe, 145 },
{ "unknown-146", "X",				&dhcp_universe, 146 },
{ "unknown-147", "X",				&dhcp_universe, 147 },
{ "unknown-148", "X",				&dhcp_universe, 148 },
{ "unknown-149", "X",				&dhcp_universe, 149 },
{ "unknown-150", "X",				&dhcp_universe, 150 },
{ "unknown-151", "X",				&dhcp_universe, 151 },
{ "unknown-152", "X",				&dhcp_universe, 152 },
{ "unknown-153", "X",				&dhcp_universe, 153 },
{ "unknown-154", "X",				&dhcp_universe, 154 },
{ "unknown-155", "X",				&dhcp_universe, 155 },
{ "unknown-156", "X",				&dhcp_universe, 156 },
{ "unknown-157", "X",				&dhcp_universe, 157 },
{ "unknown-158", "X",				&dhcp_universe, 158 },
{ "unknown-159", "X",				&dhcp_universe, 159 },
{ "unknown-160", "X",				&dhcp_universe, 160 },
{ "unknown-161", "X",				&dhcp_universe, 161 },
{ "unknown-162", "X",				&dhcp_universe, 162 },
{ "unknown-163", "X",				&dhcp_universe, 163 },
{ "unknown-164", "X",				&dhcp_universe, 164 },
{ "unknown-165", "X",				&dhcp_universe, 165 },
{ "unknown-166", "X",				&dhcp_universe, 166 },
{ "unknown-167", "X",				&dhcp_universe, 167 },
{ "unknown-168", "X",				&dhcp_universe, 168 },
{ "unknown-169", "X",				&dhcp_universe, 169 },
{ "unknown-170", "X",				&dhcp_universe, 170 },
{ "unknown-171", "X",				&dhcp_universe, 171 },
{ "unknown-172", "X",				&dhcp_universe, 172 },
{ "unknown-173", "X",				&dhcp_universe, 173 },
{ "unknown-174", "X",				&dhcp_universe, 174 },
{ "unknown-175", "X",				&dhcp_universe, 175 },
{ "unknown-176", "X",				&dhcp_universe, 176 },
{ "unknown-177", "X",				&dhcp_universe, 177 },
{ "unknown-178", "X",				&dhcp_universe, 178 },
{ "unknown-179", "X",				&dhcp_universe, 179 },
{ "unknown-180", "X",				&dhcp_universe, 180 },
{ "unknown-181", "X",				&dhcp_universe, 181 },
{ "unknown-182", "X",				&dhcp_universe, 182 },
{ "unknown-183", "X",				&dhcp_universe, 183 },
{ "unknown-184", "X",				&dhcp_universe, 184 },
{ "unknown-185", "X",				&dhcp_universe, 185 },
{ "unknown-186", "X",				&dhcp_universe, 186 },
{ "unknown-187", "X",				&dhcp_universe, 187 },
{ "unknown-188", "X",				&dhcp_universe, 188 },
{ "unknown-189", "X",				&dhcp_universe, 189 },
{ "unknown-190", "X",				&dhcp_universe, 190 },
{ "unknown-191", "X",				&dhcp_universe, 191 },
{ "unknown-192", "X",				&dhcp_universe, 192 },
{ "unknown-193", "X",				&dhcp_universe, 193 },
{ "unknown-194", "X",				&dhcp_universe, 194 },
{ "unknown-195", "X",				&dhcp_universe, 195 },
{ "unknown-196", "X",				&dhcp_universe, 196 },
{ "unknown-197", "X",				&dhcp_universe, 197 },
{ "unknown-198", "X",				&dhcp_universe, 198 },
{ "unknown-199", "X",				&dhcp_universe, 199 },
{ "unknown-200", "X",				&dhcp_universe, 200 },
{ "unknown-201", "X",				&dhcp_universe, 201 },
{ "unknown-202", "X",				&dhcp_universe, 202 },
{ "unknown-203", "X",				&dhcp_universe, 203 },
{ "unknown-204", "X",				&dhcp_universe, 204 },
{ "unknown-205", "X",				&dhcp_universe, 205 },
{ "unknown-206", "X",				&dhcp_universe, 206 },
{ "unknown-207", "X",				&dhcp_universe, 207 },
{ "unknown-208", "X",				&dhcp_universe, 208 },
{ "unknown-209", "X",				&dhcp_universe, 209 },
{ "authenticate", "X",				&dhcp_universe, 210 },
{ "unknown-211", "X",				&dhcp_universe, 211 },
{ "unknown-212", "X",				&dhcp_universe, 212 },
{ "unknown-213", "X",				&dhcp_universe, 213 },
{ "unknown-214", "X",				&dhcp_universe, 214 },
{ "unknown-215", "X",				&dhcp_universe, 215 },
{ "unknown-216", "X",				&dhcp_universe, 216 },
{ "unknown-217", "X",				&dhcp_universe, 217 },
{ "unknown-218", "X",				&dhcp_universe, 218 },
{ "unknown-219", "X",				&dhcp_universe, 219 },
{ "unknown-220", "X",				&dhcp_universe, 220 },
{ "unknown-221", "X",				&dhcp_universe, 221 },
{ "unknown-222", "X",				&dhcp_universe, 222 },
{ "unknown-223", "X",				&dhcp_universe, 223 },
{ "unknown-224", "X",				&dhcp_universe, 224 },
{ "unknown-225", "X",				&dhcp_universe, 225 },
{ "unknown-226", "X",				&dhcp_universe, 226 },
{ "unknown-227", "X",				&dhcp_universe, 227 },
{ "unknown-228", "X",				&dhcp_universe, 228 },
{ "unknown-229", "X",				&dhcp_universe, 229 },
{ "unknown-230", "X",				&dhcp_universe, 230 },
{ "unknown-231", "X",				&dhcp_universe, 231 },
{ "unknown-232", "X",				&dhcp_universe, 232 },
{ "unknown-233", "X",				&dhcp_universe, 233 },
{ "unknown-234", "X",				&dhcp_universe, 234 },
{ "unknown-235", "X",				&dhcp_universe, 235 },
{ "unknown-236", "X",				&dhcp_universe, 236 },
{ "unknown-237", "X",				&dhcp_universe, 237 },
{ "unknown-238", "X",				&dhcp_universe, 238 },
{ "unknown-239", "X",				&dhcp_universe, 239 },
{ "unknown-240", "X",				&dhcp_universe, 240 },
{ "unknown-241", "X",				&dhcp_universe, 241 },
{ "unknown-242", "X",				&dhcp_universe, 242 },
{ "unknown-243", "X",				&dhcp_universe, 243 },
{ "unknown-244", "X",				&dhcp_universe, 244 },
{ "unknown-245", "X",				&dhcp_universe, 245 },
{ "unknown-246", "X",				&dhcp_universe, 246 },
{ "unknown-247", "X",				&dhcp_universe, 247 },
{ "unknown-248", "X",				&dhcp_universe, 248 },
{ "unknown-249", "X",				&dhcp_universe, 249 },
{ "unknown-250", "X",				&dhcp_universe, 250 },
{ "unknown-251", "X",				&dhcp_universe, 251 },
{ "unknown-252", "X",				&dhcp_universe, 252 },
{ "unknown-253", "X",				&dhcp_universe, 253 },
{ "unknown-254", "X",				&dhcp_universe, 254 },
{ "option-end", "e",				&dhcp_universe, 255 },
};

上記を元にした設定の例

send dhcp-max-message-size 548;
send dhcp-lease-time -1;
request subnet-mask, routers, domain-name-servers, host-name, domain-name,
               root-path, default-ip-ttl, broadcast-address, perform-mask-discovery,
               router-discovery, static-routes, nis-domain, nis-servers, ntp-servers,
               lpr-servers, log-servers, netbios-name-servers;
send vendor-class-identifier "Linux 2.6.18-8.i686";
send dhcp-client-identifier 1:XX:XX:XX:XX:XX:XX;

"dhcp-lease-time"の"-1"はinfinity
"dhcp-client-identifier"の
1 - Hardware Type
  1:ethernet
  2:Experimental Ethernet
  3:AX.25
  4:ProNET
  5:chaos
  6:IEEE 802
  7:ARCNET
  8:Hyper Channel
  9:Lanstar
  a:Autonet Short Address
  b:Localtalk
  c:LocalNet
  d:Ultralink
  e:SMDS
  f:忘れた
  10:ATM
  まだまだありそうだけど調べるのにあきたのでここまで

XX:XX:XX:XX:XX:XX - Mac Address
ツールボックス

下から選んでください:

新しいページを作成する
ヘルプ / FAQ もご覧ください。