自动化Linux:配置Cobbler Server
这两天在看Cobbler,虽然红帽说Cobbler的配置很简单,甚至连补鞋匠都能够掌握(这也是该产品成为Cobbler的原因)。
但是通过接触,发现还是不够简单,… 也是有很多地方需要配置的。
于是,经过今天的努力,将Cobbler服务器端的配置过程脚本化了。
通过执行脚本,可以一键完成Cobbler Server的初步配置(至少能够保证最基本的工作)。
这些脚本我已经发布到了:
Github:https://github.com/adamhuan/linux-script/tree/master/cobbler_server_shell
OSC:http://git.oschina.net/memorycache/open-linux-script/tree/master/cobbler_server_shell
该脚本执行完成之后,你可能还需要自己手动做下面几个工作:
1. 挂载系统介质
2. 导入cobbler(cobbler import)
3. 准备Kickstart脚本
4. 将Kickstart脚本与特定的Cobbler Profile关联(cobbler profile edit –name=xxx …)
完成了以上工作后,你就可以让客户机通过网络PXE方式,便捷的部署系统了。
——————————————
Done。
——————————————
追加:2016年3月8日
对于一个全新的机器,执行前:
1. 挂在光盘介质到/iso
2. 确保主机连通外网(你也可以将需要下载的介质提前放到本地,并修改脚本中的相关参数,并修改运行时的online为offline)
该脚本的执行状态:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 |
[root@cobbler-server ~]# mkdir /iso [root@cobbler-server ~]# mount /dev/sr0 /iso mount: block device /dev/sr0 is write-protected, mounting read-only [root@cobbler-server ~]# [root@cobbler-server ~]# vi cobbler.sh [root@cobbler-server ~]# [root@cobbler-server ~]# sh cobbler.sh File: /etc/sysconfig/network ===================== Old value is: cobbler-server New value is: cobbler-server File: /etc/sysconfig/network-scripts/ifcfg-eth0 ===================== Old value is: "dhcp" New value is: static File: /etc/sysconfig/network-scripts/ifcfg-eth0 ===================== Old value is: "yes" New value is: on File: /etc/sysconfig/network-scripts/ifcfg-eth0 ===================== Old value is: New value is: 192.168.232.142 File: /etc/sysconfig/network-scripts/ifcfg-eth0 ===================== Old value is: New value is: 255.255.255.0 File: /etc/sysconfig/network-scripts/ifcfg-eth0 ===================== Old value is: "192.168.232.2" New value is: 192.168.232.2 File: /etc/sysconfig/network-scripts/ifcfg-eth0 ===================== Old value is: New value is: 114.114.114.114 File: /etc/sysconfig/network-scripts/ifcfg-lo ===================== Old value is: New value is: static File: /etc/sysconfig/network-scripts/ifcfg-lo ===================== Old value is: yes New value is: on File: /etc/sysconfig/network-scripts/ifcfg-lo ===================== Old value is: 127.0.0.1 New value is: 127.0.0.1 File: /etc/sysconfig/network-scripts/ifcfg-lo ===================== Old value is: 255.0.0.0 New value is: 255.0.0.0 File: /etc/sysconfig/network-scripts/ifcfg-lo ===================== Old value is: New value is: 192.168.232.2 File: /etc/sysconfig/network-scripts/ifcfg-lo ===================== Old value is: New value is: 114.114.114.114 Shutting down interface eth0: Device state: 3 (disconnected) [ OK ] Shutting down loopback interface: [ OK ] Bringing up loopback interface: [ OK ] Bringing up interface eth0: Active connection state: activating Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/1 state: activated Connection activated [ OK ] ======================== PING baidu.com (220.181.57.217) 56(84) bytes of data. 64 bytes from 220.181.57.217: icmp_seq=1 ttl=128 time=23.6 ms 64 bytes from 220.181.57.217: icmp_seq=2 ttl=128 time=23.9 ms 64 bytes from 220.181.57.217: icmp_seq=3 ttl=128 time=23.8 ms --- baidu.com ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 2027ms rtt min/avg/max/mdev = 23.609/23.790/23.925/0.133 ms ======================== File: /etc/yum.conf ===================== Old value is: /var/cache/yum/$basearch/$releasever New value is: /tmp/yum_data File: /etc/yum.conf ===================== Old value is: 0 New value is: 1 --2016-03-08 18:34:25-- https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm Resolving dl.fedoraproject.org... 209.132.181.25, 209.132.181.27, 209.132.181.23, ... Connecting to dl.fedoraproject.org|209.132.181.25|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 14540 (14K) [application/x-rpm] Saving to: “/tmp/epel-release-latest-6.noarch.rpm” 100%[======================================================================================================================>] 14,540 59.7K/s in 0.2s 2016-03-08 18:34:26 (59.7 KB/s) - “/tmp/epel-release-latest-6.noarch.rpm” saved [14540/14540] error: package epel-release is not installed warning: /tmp/epel-release-latest-6.noarch.rpm: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY Preparing... ########################################### [100%] 1:epel-release ########################################### [100%] --2016-03-08 18:34:27-- ftp://ftp.icm.edu.pl/vol/rzm5/linux-oracle-repo/OracleLinux/OL6/openstack10/x86_64/getPackage/PyYAML-3.10-3.el6.x86_64.rpm => “/tmp/PyYAML-3.10-3.el6.x86_64.rpm” Resolving ftp.icm.edu.pl... 193.219.28.2, 2001:6a0:0:31::2 Connecting to ftp.icm.edu.pl|193.219.28.2|:21... connected. Logging in as anonymous ... Logged in! ==> SYST ... done. ==> PWD ... done. ==> TYPE I ... done. ==> CWD (1) /vol/rzm5/linux-oracle-repo/OracleLinux/OL6/openstack10/x86_64/getPackage ... done. ==> SIZE PyYAML-3.10-3.el6.x86_64.rpm ... 160544 ==> PASV ... done. ==> RETR PyYAML-3.10-3.el6.x86_64.rpm ... done. Length: 160544 (157K) (unauthoritative) 100%[======================================================================================================================>] 160,544 77.8K/s in 2.0s 2016-03-08 18:34:35 (77.8 KB/s) - “/tmp/PyYAML-3.10-3.el6.x86_64.rpm” saved [160544] error: package PyYAML is not installed Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Setting up Install Process HighAvailability | 4.1 kB 00:00 ... HighAvailability/primary_db | 44 kB 00:00 ... ISO | 4.1 kB 00:00 ... ISO/primary_db | 3.1 MB 00:00 ... LoadBalancer | 4.1 kB 00:00 ... LoadBalancer/primary_db | 7.4 kB 00:00 ... ResilientStorage | 4.1 kB 00:00 ... ResilientStorage/primary_db | 50 kB 00:00 ... ScalableFileSystem | 4.1 kB 00:00 ... ScalableFileSystem/primary_db | 7.0 kB 00:00 ... Server | 4.1 kB 00:00 ... Server/primary_db | 3.1 MB 00:00 ... epel/metalink | 4.9 kB 00:00 epel | 4.3 kB 00:00 epel/primary_db | 5.8 MB 00:09 Resolving Dependencies --> Running transaction check ---> Package libyaml.x86_64 0:0.1.3-1.4.el6 will be installed --> Finished Dependency Resolution Dependencies Resolved ================================================================================================================================================================ Package Arch Version Repository Size ================================================================================================================================================================ Installing: libyaml x86_64 0.1.3-1.4.el6 ISO 52 k Transaction Summary ================================================================================================================================================================ Install 1 Package(s) Total download size: 52 k Installed size: 127 k Downloading Packages: Running rpm_check_debug Running Transaction Test Transaction Test Succeeded Running Transaction Warning: RPMDB altered outside of yum. Installing : libyaml-0.1.3-1.4.el6.x86_64 1/1 HighAvailability/productid | 1.6 kB 00:00 ... ISO/productid | 1.6 kB 00:00 ... LoadBalancer/productid | 1.6 kB 00:00 ... ResilientStorage/productid | 1.6 kB 00:00 ... ScalableFileSystem/productid | 1.6 kB 00:00 ... Server/productid | 1.6 kB 00:00 ... Verifying : libyaml-0.1.3-1.4.el6.x86_64 1/1 Installed: libyaml.x86_64 0:0.1.3-1.4.el6 Complete! warning: /tmp/PyYAML-3.10-3.el6.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID ec551f03: NOKEY Preparing... ########################################### [100%] 1:PyYAML ########################################### [100%] Yum clean metadata: ********************** Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Cleaning repos: HighAvailability ISO LoadBalancer ResilientStorage ScalableFileSystem Server epel 15 metadata files removed 7 sqlite files removed 0 metadata files removed Yum clean all: ********************** Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Cleaning repos: HighAvailability ISO LoadBalancer ResilientStorage ScalableFileSystem Server epel Cleaning up Everything Yum list repo: ********************** Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. HighAvailability | 4.1 kB 00:00 ... HighAvailability/primary_db | 44 kB 00:00 ... ISO | 4.1 kB 00:00 ... ISO/primary_db | 3.1 MB 00:00 ... LoadBalancer | 4.1 kB 00:00 ... LoadBalancer/primary_db | 7.4 kB 00:00 ... ResilientStorage | 4.1 kB 00:00 ... ResilientStorage/primary_db | 50 kB 00:00 ... ScalableFileSystem | 4.1 kB 00:00 ... ScalableFileSystem/primary_db | 7.0 kB 00:00 ... Server | 4.1 kB 00:00 ... Server/primary_db | 3.1 MB 00:00 ... epel/metalink | 4.9 kB 00:00 epel | 4.3 kB 00:00 epel/primary_db | 5.8 MB 00:09 repo id repo name status HighAvailability HighAvailability 55 ISO ISO 3,785 LoadBalancer LoadBalancer 4 ResilientStorage ResilientStorage 62 ScalableFileSystem ScalableFileSystem 7 Server Server 3,785 epel Extra Packages for Enterprise Linux 6 - x86_64 12,082 repolist: 19,780 Yum clean metadata: ********************** Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Cleaning repos: HighAvailability ISO LoadBalancer ResilientStorage ScalableFileSystem Server epel 15 metadata files removed 7 sqlite files removed 0 metadata files removed Yum clean all: ********************** Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Cleaning repos: HighAvailability ISO LoadBalancer ResilientStorage ScalableFileSystem Server epel Cleaning up Everything Yum list repo: ********************** Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. HighAvailability | 4.1 kB 00:00 ... HighAvailability/primary_db | 44 kB 00:00 ... ISO | 4.1 kB 00:00 ... ISO/primary_db | 3.1 MB 00:00 ... LoadBalancer | 4.1 kB 00:00 ... LoadBalancer/primary_db | 7.4 kB 00:00 ... ResilientStorage | 4.1 kB 00:00 ... ResilientStorage/primary_db | 50 kB 00:00 ... ScalableFileSystem | 4.1 kB 00:00 ... ScalableFileSystem/primary_db | 7.0 kB 00:00 ... Server | 4.1 kB 00:00 ... Server/primary_db | 3.1 MB 00:00 ... epel/metalink | 4.9 kB 00:00 epel | 4.3 kB 00:00 epel/primary_db | 5.8 MB 00:07 repo id repo name status HighAvailability HighAvailability 55 ISO ISO 3,785 LoadBalancer LoadBalancer 4 ResilientStorage ResilientStorage 62 ScalableFileSystem ScalableFileSystem 7 Server Server 3,785 epel Extra Packages for Enterprise Linux 6 - x86_64 12,082 repolist: 19,780 Loaded plugins: product-id, refresh-packagekit, security, subscription-manager This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package bind.x86_64 32:9.8.2-0.30.rc1.el6 will be installed ---> Package cman.x86_64 0:3.0.12.1-68.el6 will be installed --> Processing Dependency: clusterlib = 3.0.12.1-68.el6 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: corosync >= 1.4.1-10 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: fence-agents >= 3.1.5-1 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: fence-virt >= 0.2.3-1 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: modcluster >= 0.15.0-3 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: openais >= 1.1.1-1 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: ricci >= 0.15.0-4 for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libSaCkpt.so.3(OPENAIS_CKPT_B.01.01)(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libconfdb.so.4(COROSYNC_CONFDB_1.0)(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libcpg.so.4(COROSYNC_CPG_1.0)(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libSaCkpt.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libccs.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libcman.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libconfdb.so.4()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libcpg.so.4()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libdlm.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libdlmcontrol.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libfence.so.4()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: libfenced.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 --> Processing Dependency: liblogthread.so.3()(64bit) for package: cman-3.0.12.1-68.el6.x86_64 ---> Package cobbler.x86_64 0:2.6.11-1.el6 will be installed --> Processing Dependency: syslinux for package: cobbler-2.6.11-1.el6.x86_64 --> Processing Dependency: python-simplejson for package: cobbler-2.6.11-1.el6.x86_64 --> Processing Dependency: python-cheetah for package: cobbler-2.6.11-1.el6.x86_64 --> Processing Dependency: mod_wsgi for package: cobbler-2.6.11-1.el6.x86_64 --> Processing Dependency: createrepo for package: cobbler-2.6.11-1.el6.x86_64 ---> Package dhcp.x86_64 12:4.1.1-43.P1.el6 will be installed ---> Package pykickstart.noarch 0:1.74.16-1.el6 will be installed ---> Package tftp-server.x86_64 0:0.49-7.el6 will be installed ---> Package xinetd.x86_64 2:2.3.14-39.el6_4 will be installed --> Running transaction check ---> Package clusterlib.x86_64 0:3.0.12.1-68.el6 will be installed ---> Package corosync.x86_64 0:1.4.7-1.el6 will be installed ---> Package corosynclib.x86_64 0:1.4.7-1.el6 will be installed ---> Package createrepo.noarch 0:0.9.9-22.el6 will be installed --> Processing Dependency: python-deltarpm for package: createrepo-0.9.9-22.el6.noarch ---> Package fence-agents.x86_64 0:3.1.5-48.el6 will be installed --> Processing Dependency: /usr/bin/ipmitool for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: /usr/bin/virsh for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: net-snmp-utils for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: perl(Net::Telnet) for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: perl-Net-Telnet for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: pexpect for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: python-suds for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: sg3_utils for package: fence-agents-3.1.5-48.el6.x86_64 --> Processing Dependency: telnet for package: fence-agents-3.1.5-48.el6.x86_64 ---> Package fence-virt.x86_64 0:0.2.3-18.el6 will be installed ---> Package mod_wsgi.x86_64 0:3.2-7.el6 will be installed ---> Package modcluster.x86_64 0:0.16.2-29.el6 will be installed ---> Package openais.x86_64 0:1.1.1-7.el6 will be installed ---> Package openaislib.x86_64 0:1.1.1-7.el6 will be installed ---> Package python-cheetah.x86_64 0:2.4.1-1.el6 will be installed --> Processing Dependency: python-markdown for package: python-cheetah-2.4.1-1.el6.x86_64 --> Processing Dependency: python-pygments for package: python-cheetah-2.4.1-1.el6.x86_64 ---> Package python-simplejson.x86_64 0:2.0.9-3.1.el6 will be installed ---> Package ricci.x86_64 0:0.16.2-75.el6 will be installed ---> Package syslinux.x86_64 0:4.04-3.el6 will be installed --> Processing Dependency: syslinux-nonlinux for package: syslinux-4.04-3.el6.x86_64 --> Running transaction check ---> Package ipmitool.x86_64 0:1.8.11-20.el6 will be installed --> Processing Dependency: OpenIPMI for package: ipmitool-1.8.11-20.el6.x86_64 ---> Package libvirt-client.x86_64 0:0.10.2-46.el6 will be installed --> Processing Dependency: cyrus-sasl-md5 for package: libvirt-client-0.10.2-46.el6.x86_64 --> Processing Dependency: gnutls-utils for package: libvirt-client-0.10.2-46.el6.x86_64 --> Processing Dependency: nc for package: libvirt-client-0.10.2-46.el6.x86_64 --> Processing Dependency: libyajl.so.1()(64bit) for package: libvirt-client-0.10.2-46.el6.x86_64 ---> Package net-snmp-utils.x86_64 1:5.5-49.el6_5.3 will be installed ---> Package perl-Net-Telnet.noarch 0:3.03-11.el6 will be installed ---> Package pexpect.noarch 0:2.3-6.el6 will be installed ---> Package python-deltarpm.x86_64 0:3.5-0.5.20090913git.el6 will be installed --> Processing Dependency: deltarpm = 3.5-0.5.20090913git.el6 for package: python-deltarpm-3.5-0.5.20090913git.el6.x86_64 ---> Package python-markdown.noarch 0:2.0.1-3.1.el6 will be installed ---> Package python-pygments.noarch 0:1.1.1-1.el6 will be installed --> Processing Dependency: python-setuptools for package: python-pygments-1.1.1-1.el6.noarch ---> Package python-suds.noarch 0:0.4.1-3.el6 will be installed ---> Package sg3_utils.x86_64 0:1.28-6.el6 will be installed ---> Package syslinux-nonlinux.noarch 0:4.04-3.el6 will be installed ---> Package telnet.x86_64 1:0.17-48.el6 will be installed --> Running transaction check ---> Package OpenIPMI.x86_64 0:2.0.16-14.el6 will be installed --> Processing Dependency: OpenIPMI-libs = 2.0.16-14.el6 for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libIPMIlanserv.so.0()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libOpenIPMI.so.0()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libOpenIPMIcmdlang.so.0()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libOpenIPMIglib.so.0()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libOpenIPMIposix.so.0()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libOpenIPMIui.so.1()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 --> Processing Dependency: libOpenIPMIutils.so.0()(64bit) for package: OpenIPMI-2.0.16-14.el6.x86_64 ---> Package cyrus-sasl-md5.x86_64 0:2.1.23-15.el6 will be installed ---> Package deltarpm.x86_64 0:3.5-0.5.20090913git.el6 will be installed ---> Package gnutls-utils.x86_64 0:2.8.5-14.el6_5 will be installed ---> Package nc.x86_64 0:1.84-22.el6 will be installed ---> Package python-setuptools.noarch 0:0.6.10-3.el6 will be installed ---> Package yajl.x86_64 0:1.0.7-3.el6 will be installed --> Running transaction check ---> Package OpenIPMI-libs.x86_64 0:2.0.16-14.el6 will be installed --> Finished Dependency Resolution Dependencies Resolved ================================================================================================================================================================ Package Arch Version Repository Size ================================================================================================================================================================ Installing: bind x86_64 32:9.8.2-0.30.rc1.el6 ISO 4.0 M cman x86_64 3.0.12.1-68.el6 HighAvailability 449 k cobbler x86_64 2.6.11-1.el6 epel 612 k dhcp x86_64 12:4.1.1-43.P1.el6 ISO 819 k pykickstart noarch 1.74.16-1.el6 ISO 310 k tftp-server x86_64 0.49-7.el6 ISO 39 k xinetd x86_64 2:2.3.14-39.el6_4 ISO 122 k Installing for dependencies: OpenIPMI x86_64 2.0.16-14.el6 ISO 156 k OpenIPMI-libs x86_64 2.0.16-14.el6 ISO 473 k clusterlib x86_64 3.0.12.1-68.el6 HighAvailability 105 k corosync x86_64 1.4.7-1.el6 HighAvailability 212 k corosynclib x86_64 1.4.7-1.el6 HighAvailability 189 k createrepo noarch 0.9.9-22.el6 ISO 96 k cyrus-sasl-md5 x86_64 2.1.23-15.el6 ISO 47 k deltarpm x86_64 3.5-0.5.20090913git.el6 ISO 71 k fence-agents x86_64 3.1.5-48.el6 ISO 166 k fence-virt x86_64 0.2.3-18.el6 HighAvailability 38 k gnutls-utils x86_64 2.8.5-14.el6_5 ISO 100 k ipmitool x86_64 1.8.11-20.el6 ISO 463 k libvirt-client x86_64 0.10.2-46.el6 ISO 4.0 M mod_wsgi x86_64 3.2-7.el6 ISO 66 k modcluster x86_64 0.16.2-29.el6 HighAvailability 191 k nc x86_64 1.84-22.el6 ISO 57 k net-snmp-utils x86_64 1:5.5-49.el6_5.3 ISO 174 k openais x86_64 1.1.1-7.el6 HighAvailability 192 k openaislib x86_64 1.1.1-7.el6 HighAvailability 82 k perl-Net-Telnet noarch 3.03-11.el6 ISO 55 k pexpect noarch 2.3-6.el6 ISO 147 k python-cheetah x86_64 2.4.1-1.el6 ISO 364 k python-deltarpm x86_64 3.5-0.5.20090913git.el6 ISO 27 k python-markdown noarch 2.0.1-3.1.el6 ISO 118 k python-pygments noarch 1.1.1-1.el6 ISO 561 k python-setuptools noarch 0.6.10-3.el6 ISO 336 k python-simplejson x86_64 2.0.9-3.1.el6 ISO 126 k python-suds noarch 0.4.1-3.el6 ISO 218 k ricci x86_64 0.16.2-75.el6 HighAvailability 630 k sg3_utils x86_64 1.28-6.el6 ISO 475 k syslinux x86_64 4.04-3.el6 ISO 346 k syslinux-nonlinux noarch 4.04-3.el6 ISO 574 k telnet x86_64 1:0.17-48.el6 ISO 58 k yajl x86_64 1.0.7-3.el6 ISO 27 k Transaction Summary ================================================================================================================================================================ Install 41 Package(s) Total download size: 17 M Installed size: 50 M Downloading Packages: (6/41): cobbler-2.6.11-1.el6.x86_64.rpm | 612 kB 00:01 ---------------------------------------------------------------------------------------------------------------------------------------------------------------- Total 7.8 MB/s | 17 MB 00:02 warning: rpmts_HdrFromFdno: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6 Importing GPG key 0x0608B895: Userid : EPEL (6) <epel@fedoraproject.org> Package: epel-release-6-8.noarch (installed) From : /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6 Running rpm_check_debug Running Transaction Test Transaction Test Succeeded Running Transaction Warning: RPMDB altered outside of yum. Installing : corosynclib-1.4.7-1.el6.x86_64 1/41 Installing : corosync-1.4.7-1.el6.x86_64 2/41 Installing : openais-1.1.1-7.el6.x86_64 3/41 Installing : openaislib-1.1.1-7.el6.x86_64 4/41 Installing : clusterlib-3.0.12.1-68.el6.x86_64 5/41 Installing : modcluster-0.16.2-29.el6.x86_64 6/41 Installing : syslinux-nonlinux-4.04-3.el6.noarch 7/41 Installing : syslinux-4.04-3.el6.x86_64 8/41 Installing : ricci-0.16.2-75.el6.x86_64 9/41 Installing : 1:net-snmp-utils-5.5-49.el6_5.3.x86_64 10/41 Installing : yajl-1.0.7-3.el6.x86_64 11/41 Installing : OpenIPMI-libs-2.0.16-14.el6.x86_64 12/41 Installing : OpenIPMI-2.0.16-14.el6.x86_64 13/41 Installing : ipmitool-1.8.11-20.el6.x86_64 14/41 Installing : pexpect-2.3-6.el6.noarch 15/41 Installing : cyrus-sasl-md5-2.1.23-15.el6.x86_64 16/41 Installing : fence-virt-0.2.3-18.el6.x86_64 17/41 Installing : python-setuptools-0.6.10-3.el6.noarch 18/41 Installing : python-pygments-1.1.1-1.el6.noarch 19/41 Installing : python-markdown-2.0.1-3.1.el6.noarch 20/41 Installing : python-cheetah-2.4.1-1.el6.x86_64 21/41 Installing : perl-Net-Telnet-3.03-11.el6.noarch 22/41 Installing : gnutls-utils-2.8.5-14.el6_5.x86_64 23/41 Installing : python-suds-0.4.1-3.el6.noarch 24/41 Installing : deltarpm-3.5-0.5.20090913git.el6.x86_64 25/41 Installing : python-deltarpm-3.5-0.5.20090913git.el6.x86_64 26/41 Installing : createrepo-0.9.9-22.el6.noarch 27/41 Installing : 2:xinetd-2.3.14-39.el6_4.x86_64 28/41 Installing : tftp-server-0.49-7.el6.x86_64 29/41 Installing : python-simplejson-2.0.9-3.1.el6.x86_64 30/41 Installing : 1:telnet-0.17-48.el6.x86_64 31/41 Installing : sg3_utils-1.28-6.el6.x86_64 32/41 Installing : mod_wsgi-3.2-7.el6.x86_64 33/41 Installing : nc-1.84-22.el6.x86_64 34/41 Installing : libvirt-client-0.10.2-46.el6.x86_64 35/41 Installing : fence-agents-3.1.5-48.el6.x86_64 36/41 Stopping kdump:[ OK ] Starting kdump:[ OK ] Installing : cman-3.0.12.1-68.el6.x86_64 37/41 Installing : cobbler-2.6.11-1.el6.x86_64 38/41 Installing : pykickstart-1.74.16-1.el6.noarch 39/41 Installing : 12:dhcp-4.1.1-43.P1.el6.x86_64 40/41 Installing : 32:bind-9.8.2-0.30.rc1.el6.x86_64 41/41 Verifying : 32:bind-9.8.2-0.30.rc1.el6.x86_64 1/41 Verifying : createrepo-0.9.9-22.el6.noarch 2/41 Verifying : libvirt-client-0.10.2-46.el6.x86_64 3/41 Verifying : cman-3.0.12.1-68.el6.x86_64 4/41 Verifying : modcluster-0.16.2-29.el6.x86_64 5/41 Verifying : python-pygments-1.1.1-1.el6.noarch 6/41 Verifying : nc-1.84-22.el6.x86_64 7/41 Verifying : mod_wsgi-3.2-7.el6.x86_64 8/41 Verifying : corosync-1.4.7-1.el6.x86_64 9/41 Verifying : sg3_utils-1.28-6.el6.x86_64 10/41 Verifying : 1:telnet-0.17-48.el6.x86_64 11/41 Verifying : python-simplejson-2.0.9-3.1.el6.x86_64 12/41 Verifying : 2:xinetd-2.3.14-39.el6_4.x86_64 13/41 Verifying : fence-agents-3.1.5-48.el6.x86_64 14/41 Verifying : ricci-0.16.2-75.el6.x86_64 15/41 Verifying : deltarpm-3.5-0.5.20090913git.el6.x86_64 16/41 Verifying : python-suds-0.4.1-3.el6.noarch 17/41 Verifying : tftp-server-0.49-7.el6.x86_64 18/41 Verifying : 12:dhcp-4.1.1-43.P1.el6.x86_64 19/41 Verifying : gnutls-utils-2.8.5-14.el6_5.x86_64 20/41 Verifying : openais-1.1.1-7.el6.x86_64 21/41 Verifying : openaislib-1.1.1-7.el6.x86_64 22/41 Verifying : python-cheetah-2.4.1-1.el6.x86_64 23/41 Verifying : pykickstart-1.74.16-1.el6.noarch 24/41 Verifying : perl-Net-Telnet-3.03-11.el6.noarch 25/41 Verifying : python-markdown-2.0.1-3.1.el6.noarch 26/41 Verifying : corosynclib-1.4.7-1.el6.x86_64 27/41 Verifying : cobbler-2.6.11-1.el6.x86_64 28/41 Verifying : python-setuptools-0.6.10-3.el6.noarch 29/41 Verifying : python-deltarpm-3.5-0.5.20090913git.el6.x86_64 30/41 Verifying : syslinux-4.04-3.el6.x86_64 31/41 Verifying : fence-virt-0.2.3-18.el6.x86_64 32/41 Verifying : cyrus-sasl-md5-2.1.23-15.el6.x86_64 33/41 Verifying : pexpect-2.3-6.el6.noarch 34/41 Verifying : OpenIPMI-libs-2.0.16-14.el6.x86_64 35/41 Verifying : yajl-1.0.7-3.el6.x86_64 36/41 Verifying : syslinux-nonlinux-4.04-3.el6.noarch 37/41 Verifying : OpenIPMI-2.0.16-14.el6.x86_64 38/41 Verifying : 1:net-snmp-utils-5.5-49.el6_5.3.x86_64 39/41 Verifying : ipmitool-1.8.11-20.el6.x86_64 40/41 Verifying : clusterlib-3.0.12.1-68.el6.x86_64 41/41 Installed: bind.x86_64 32:9.8.2-0.30.rc1.el6 cman.x86_64 0:3.0.12.1-68.el6 cobbler.x86_64 0:2.6.11-1.el6 dhcp.x86_64 12:4.1.1-43.P1.el6 pykickstart.noarch 0:1.74.16-1.el6 tftp-server.x86_64 0:0.49-7.el6 xinetd.x86_64 2:2.3.14-39.el6_4 Dependency Installed: OpenIPMI.x86_64 0:2.0.16-14.el6 OpenIPMI-libs.x86_64 0:2.0.16-14.el6 clusterlib.x86_64 0:3.0.12.1-68.el6 corosync.x86_64 0:1.4.7-1.el6 corosynclib.x86_64 0:1.4.7-1.el6 createrepo.noarch 0:0.9.9-22.el6 cyrus-sasl-md5.x86_64 0:2.1.23-15.el6 deltarpm.x86_64 0:3.5-0.5.20090913git.el6 fence-agents.x86_64 0:3.1.5-48.el6 fence-virt.x86_64 0:0.2.3-18.el6 gnutls-utils.x86_64 0:2.8.5-14.el6_5 ipmitool.x86_64 0:1.8.11-20.el6 libvirt-client.x86_64 0:0.10.2-46.el6 mod_wsgi.x86_64 0:3.2-7.el6 modcluster.x86_64 0:0.16.2-29.el6 nc.x86_64 0:1.84-22.el6 net-snmp-utils.x86_64 1:5.5-49.el6_5.3 openais.x86_64 0:1.1.1-7.el6 openaislib.x86_64 0:1.1.1-7.el6 perl-Net-Telnet.noarch 0:3.03-11.el6 pexpect.noarch 0:2.3-6.el6 python-cheetah.x86_64 0:2.4.1-1.el6 python-deltarpm.x86_64 0:3.5-0.5.20090913git.el6 python-markdown.noarch 0:2.0.1-3.1.el6 python-pygments.noarch 0:1.1.1-1.el6 python-setuptools.noarch 0:0.6.10-3.el6 python-simplejson.x86_64 0:2.0.9-3.1.el6 python-suds.noarch 0:0.4.1-3.el6 ricci.x86_64 0:0.16.2-75.el6 sg3_utils.x86_64 0:1.28-6.el6 syslinux.x86_64 0:4.04-3.el6 syslinux-nonlinux.noarch 0:4.04-3.el6 telnet.x86_64 1:0.17-48.el6 yajl.x86_64 0:1.0.7-3.el6 Complete! ********************** Cobbler Server: Install Part - Done. ********************** @@@ cobbler server: Configuration Part. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ File: /etc/cobbler/settings ===================== Old value is: 127.0.0.1 New value is: 192.168.232.142 File: /etc/cobbler/settings ===================== Old value is: 127.0.0.1 New value is: 192.168.232.142 File: /etc/cobbler/settings ===================== Old value is: 0 New value is: 1 File: /etc/cobbler/settings ===================== Old value is: 0 New value is: 1 File: /etc/cobbler/settings ===================== Old value is: 0 New value is: 1 File: /etc/cobbler/settings ===================== Old value is: "$1$mF86/UHC$WvcIcX2t6crBz2onWxyac." New value is: $1$random-p$coSn62dC9JIVNcphvf.1C. Stopping xinetd: [FAILED] Starting xinetd: [ OK ] Stopping httpd: [ OK ] Starting httpd: [ OK ] Stopping cobbler daemon: [ OK ] Starting cobbler daemon: [ OK ] ============================= @@@ cobbler: get-loaders. task started: 2016-03-08_183554_get_loaders task started (id=Download Bootloader Content, time=Tue Mar 8 18:35:54 2016) downloading http://cobbler.github.io/loaders/README to /var/lib/cobbler/loaders/README downloading http://cobbler.github.io/loaders/COPYING.elilo to /var/lib/cobbler/loaders/COPYING.elilo downloading http://cobbler.github.io/loaders/COPYING.yaboot to /var/lib/cobbler/loaders/COPYING.yaboot downloading http://cobbler.github.io/loaders/COPYING.syslinux to /var/lib/cobbler/loaders/COPYING.syslinux downloading http://cobbler.github.io/loaders/elilo-3.8-ia64.efi to /var/lib/cobbler/loaders/elilo-ia64.efi downloading http://cobbler.github.io/loaders/yaboot-1.3.17 to /var/lib/cobbler/loaders/yaboot downloading http://cobbler.github.io/loaders/pxelinux.0-3.86 to /var/lib/cobbler/loaders/pxelinux.0 downloading http://cobbler.github.io/loaders/menu.c32-3.86 to /var/lib/cobbler/loaders/menu.c32 downloading http://cobbler.github.io/loaders/grub-0.97-x86.efi to /var/lib/cobbler/loaders/grub-x86.efi downloading http://cobbler.github.io/loaders/grub-0.97-x86_64.efi to /var/lib/cobbler/loaders/grub-x86_64.efi *** TASK COMPLETE *** @@@ cobbler: check. The following are potential configuration items that you may want to fix: 1 : service dhcpd is not running 2 : file /etc/xinetd.d/rsync does not exist 3 : debmirror package is not installed, it will be required to manage debian deployments and repositories Restart cobblerd and then run 'cobbler sync' to apply changes. @@@ cobbler: sync task started: 2016-03-08_183618_sync task started (id=Sync, time=Tue Mar 8 18:36:18 2016) running pre-sync triggers cleaning trees removing: /var/lib/tftpboot/grub/images copying bootloaders trying hardlink /var/lib/cobbler/loaders/pxelinux.0 -> /var/lib/tftpboot/pxelinux.0 trying hardlink /var/lib/cobbler/loaders/menu.c32 -> /var/lib/tftpboot/menu.c32 trying hardlink /var/lib/cobbler/loaders/yaboot -> /var/lib/tftpboot/yaboot trying hardlink /usr/share/syslinux/memdisk -> /var/lib/tftpboot/memdisk trying hardlink /var/lib/cobbler/loaders/grub-x86_64.efi -> /var/lib/tftpboot/grub/grub-x86_64.efi trying hardlink /var/lib/cobbler/loaders/grub-x86.efi -> /var/lib/tftpboot/grub/grub-x86.efi copying distros to tftpboot copying images generating PXE configuration files generating PXE menu structure rendering DHCP files generating /etc/dhcp/dhcpd.conf rendering TFTPD files generating /etc/xinetd.d/tftp cleaning link caches rendering Rsync files running post-sync triggers running python triggers from /var/lib/cobbler/triggers/sync/post/* running python trigger cobbler.modules.sync_post_restart_services running: dhcpd -t -q received on stdout: received on stderr: running: service dhcpd restart received on stdout: Starting dhcpd: [ OK ] received on stderr: running shell triggers from /var/lib/cobbler/triggers/sync/post/* running python triggers from /var/lib/cobbler/triggers/change/* running python trigger cobbler.modules.scm_track running shell triggers from /var/lib/cobbler/triggers/change/* *** TASK COMPLETE *** [root@cobbler-server ~]# |
————————————
Done。
需要注意的是,这个脚本需要在RHEL6及其以上的系统上跑,否则EPEL的部分会报错。