############# # cert-23 ############# [root@cert-23 ~]# cat /etc/redhat-release Scientific Linux release 6.4 (Carbon) [root@cert-23 ~]# uname -a Linux cert-23.pd.infn.it 2.6.32-358.18.1.el6.x86_64 #1 SMP Tue Aug 27 14:23:09 CDT 2013 x86_64 x86_64 x86_64 GNU/Linux [root@cert-23 ~]# [root@cert-23 ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/vda2 48G 2.4G 43G 6% / tmpfs 1.5G 0 1.5G 0% /dev/shm gw-master:/opt/nfs_install 195G 63G 123G 34% /usr/local/nfs [root@cert-23 ~]# yum install puppet-server puppet […] Dependencies Resolved ============================================================================================================================================================================= Package Arch Version Repository Size ============================================================================================================================================================================= Installing: puppet noarch 2.6.18-3.el6 epel 817 k puppet-server noarch 2.6.18-3.el6 epel 23 k Installing for dependencies: augeas-libs x86_64 0.9.0-4.el6 sl 317 k compat-readline5 x86_64 5.2-17.1.el6 sl 129 k facter x86_64 1.6.18-3.el6 epel 62 k libselinux-ruby x86_64 2.0.94-5.3.el6 sl 98 k ruby x86_64 1.8.7.352-12.el6_4 sl-security 533 k ruby-augeas x86_64 0.4.1-1.el6 epel 21 k ruby-libs x86_64 1.8.7.352-12.el6_4 sl-security 1.6 M ruby-shadow x86_64 1.4.1-13.el6 epel 11 k Transaction Summary ============================================================================================================================================================================= Install 10 Package(s) Total download size: 3.6 M Installed size: 12 M Is this ok [y/N]: y [..] 10/10 Installed: puppet.noarch 0:2.6.18-3.el6 puppet-server.noarch 0:2.6.18-3.el6 Dependency Installed: augeas-libs.x86_64 0:0.9.0-4.el6 compat-readline5.x86_64 0:5.2-17.1.el6 facter.x86_64 0:1.6.18-3.el6 libselinux-ruby.x86_64 0:2.0.94-5.3.el6 ruby.x86_64 0:1.8.7.352-12.el6_4 ruby-augeas.x86_64 0:0.4.1-1.el6 ruby-libs.x86_64 0:1.8.7.352-12.el6_4 ruby-shadow.x86_64 0:1.4.1-13.el6 Complete! [root@cert-23 ~]# yum install http://yum.theforeman.org/releases/1.3/el6/x86_64/foreman-release.rpm [..] Dependencies Resolved ============================================================================================================================================================================= Package Arch Version Repository Size ============================================================================================================================================================================= Installing: foreman-release noarch 1.3.0-1.el6 /foreman-release 2.4 k Transaction Summary ============================================================================================================================================================================= Install 1 Package(s) Total size: 2.4 k Installed size: 2.4 k Is this ok [y/N]: y […] Installed: foreman-release.noarch 0:1.3.0-1.el6 Complete! [root@cert-23 ~]# yum install foreman-installer […] Dependencies Resolved ============================================================================================================================================================================= Package Arch Version Repository Size ============================================================================================================================================================================= Installing: foreman-installer noarch 1:1.3.0-1.el6 foreman 349 k Installing for dependencies: ruby-irb x86_64 1.8.7.352-12.el6_4 sl-security 312 k ruby-rdoc x86_64 1.8.7.352-12.el6_4 sl-security 375 k rubygem-ansi noarch 1.4.3-0.el6 foreman 42 k rubygem-clamp noarch 0.6.1-9.el6 foreman 24 k rubygem-foreman_api noarch 0.1.6-1.el6 foreman 39 k rubygem-hashie noarch 2.0.5-0.el6 foreman 17 k rubygem-highline noarch 1.4.0-2.el6 foreman 161 k rubygem-json x86_64 1.4.6-1.el6 epel 457 k rubygem-kafo noarch 0.2.1-1.el6 foreman 43 k rubygem-little-plugger noarch 1.1.3-17.el6 foreman 12 k rubygem-logging noarch 1.8.1-25.el6 foreman 61 k rubygem-mime-types noarch 1.16-3.el6 epel 72 k rubygem-multi_json noarch 1.3.6-11.el6 foreman 14 k rubygem-oauth noarch 0.4.7-5.el6 foreman 267 k rubygem-powerbar noarch 1.0.11-7.el6 foreman 12 k rubygem-rdoc x86_64 3.12-12.el6 foreman 223 k rubygem-rest-client noarch 1.6.1-2.el6 epel 184 k rubygems noarch 1.3.7-4.el6_4 sl-security 206 k Transaction Summary ============================================================================================================================================================================= Install 19 Package(s) Total download size: 2.8 M Installed size: 8.8 M Is this ok [y/N]: y [..] 19/19 Installed: foreman-installer.noarch 1:1.3.0-1.el6 Dependency Installed: ruby-irb.x86_64 0:1.8.7.352-12.el6_4 ruby-rdoc.x86_64 0:1.8.7.352-12.el6_4 rubygem-ansi.noarch 0:1.4.3-0.el6 rubygem-clamp.noarch 0:0.6.1-9.el6 rubygem-foreman_api.noarch 0:0.1.6-1.el6 rubygem-hashie.noarch 0:2.0.5-0.el6 rubygem-highline.noarch 0:1.4.0-2.el6 rubygem-json.x86_64 0:1.4.6-1.el6 rubygem-kafo.noarch 0:0.2.1-1.el6 rubygem-little-plugger.noarch 0:1.1.3-17.el6 rubygem-logging.noarch 0:1.8.1-25.el6 rubygem-mime-types.noarch 0:1.16-3.el6 rubygem-multi_json.noarch 0:1.3.6-11.el6 rubygem-oauth.noarch 0:0.4.7-5.el6 rubygem-powerbar.noarch 0:1.0.11-7.el6 rubygem-rdoc.x86_64 0:3.12-12.el6 rubygem-rest-client.noarch 0:1.6.1-2.el6 rubygems.noarch 0:1.3.7-4.el6_4 Complete! [root@cert-23 ~]# rpm -qa |grep mysql mysql-libs-5.1.69-1.el6_4.x86_64 [root@cert-23 ~]# rpm -qa |grep ruby |sort libselinux-ruby-2.0.94-5.3.el6.x86_64 ruby-1.8.7.352-12.el6_4.x86_64 ruby-augeas-0.4.1-1.el6.x86_64 rubygem-ansi-1.4.3-0.el6.noarch rubygem-clamp-0.6.1-9.el6.noarch rubygem-foreman_api-0.1.6-1.el6.noarch rubygem-hashie-2.0.5-0.el6.noarch rubygem-highline-1.4.0-2.el6.noarch rubygem-json-1.4.6-1.el6.x86_64 rubygem-kafo-0.2.1-1.el6.noarch rubygem-little-plugger-1.1.3-17.el6.noarch rubygem-logging-1.8.1-25.el6.noarch rubygem-mime-types-1.16-3.el6.noarch rubygem-multi_json-1.3.6-11.el6.noarch rubygem-oauth-0.4.7-5.el6.noarch rubygem-powerbar-1.0.11-7.el6.noarch rubygem-rdoc-3.12-12.el6.x86_64 rubygem-rest-client-1.6.1-2.el6.noarch rubygems-1.3.7-4.el6_4.noarch ruby-irb-1.8.7.352-12.el6_4.x86_64 ruby-libs-1.8.7.352-12.el6_4.x86_64 ruby-rdoc-1.8.7.352-12.el6_4.x86_64 ruby-shadow-1.4.1-13.el6.x86_64 [root@cert-23 ~]# yum install mysql mysql-server mysql-devel ruby-mysql rubygem-activerecord […] Dependencies Resolved ============================================================================================================================================================================= Package Arch Version Repository Size ============================================================================================================================================================================= Installing: mysql x86_64 5.1.69-1.el6_4 sl-security 907 k mysql-devel x86_64 5.1.69-1.el6_4 sl-security 127 k mysql-server x86_64 5.1.69-1.el6_4 sl-security 8.7 M ruby-mysql x86_64 2.8.2-1.el6 epel 45 k Installing for dependencies: perl-DBD-MySQL x86_64 4.013-3.el6 sl 133 k Transaction Summary ============================================================================================================================================================================= Install 5 Package(s) Total download size: 9.8 M Installed size: 28 M Is this ok [y/N]: y […] Installed: mysql.x86_64 0:5.1.69-1.el6_4 mysql-devel.x86_64 0:5.1.69-1.el6_4 mysql-server.x86_64 0:5.1.69-1.el6_4 ruby-mysql.x86_64 0:2.8.2-1.el6 Dependency Installed: perl-DBD-MySQL.x86_64 0:4.013-3.el6 Complete! [root@cert-23 ~]# rpm -ivh http://yum.puppetlabs.com/el/6/products/i386/puppetlabs-release-6-7.noarch.rpm […] Dependencies Resolved ============================================================================================================================================================================= Package Arch Version Repository Size ============================================================================================================================================================================= Installing: rubygem-activerecord noarch 2.3.16-1.el6 puppetlabs-deps 1.6 M Installing for dependencies: rubygem-activesupport noarch 2.3.16-1.el6 puppetlabs-deps 1.7 M Transaction Summary ============================================================================================================================================================================= Install 2 Package(s) Total download size: 3.2 M Installed size: 13 M Is this ok [y/N]: y […] Installed: rubygem-activerecord.noarch 0:2.3.16-1.el6 Dependency Installed: rubygem-activesupport.noarch 0:2.3.16-1.el6 Complete! ##### [root@cert-23 ~]# yum install mod_ssl […] Dependencies Resolved ============================================================================================================================================================================= Package Arch Version Repository Size ============================================================================================================================================================================= Installing: mod_ssl x86_64 1:2.2.15-29.sl6 sl-security 90 k Transaction Summary ============================================================================================================================================================================= Install 1 Package(s) Total download size: 90 k Installed size: 183 k Is this ok [y/N]: y […] Installed: mod_ssl.x86_64 1:2.2.15-29.sl6 Complete! ############## [root@cert-23 ~]# foreman-installer -i Welcome to the Kafo installer! ------------------------------ This wizard will gather all required information. You can change any parameter to your needs. Ready to start? (y/n) y Main Config Menu 1. [✓] Configure foreman_proxy 2. [✓] Configure puppet 3. [✓] Configure foreman 4. Display current config 5. Save and run 6. Cancel run without Saving Choose an option from the menu... 4 --- foreman_proxy: oauth_effective_user: admin foreman_base_url: https://cert-23.pd.infn.it bmc_default_provider: ipmitool dns_interface: eth0 dhcp_config: /etc/dhcp/dhcpd.conf tftp_servername: 193.206.210.250 dns_forwarders: [] bmc: false dns_server: 127.0.0.1 puppet_group: puppet autosign_location: /etc/puppet/autosign.conf dhcp_vendor: isc dhcp_range: false trusted_hosts: [] gpgcheck: true keyfile: /etc/rndc.key tftp_dirs: - /var/lib/tftpboot//pxelinux.cfg - /var/lib/tftpboot//boot tftp_syslinux_files: - pxelinux.0 - menu.c32 - chain.c32 - memdisk tftp_syslinux_root: /usr/share/syslinux puppetrun: true puppetca_cmd: /usr/sbin/puppetca ssl: true oauth_consumer_key: Fu9aw4dwvKk3BmHm4qGiMJeZeqDzFMHC registered_name: cert-23.pd.infn.it dns_reverse: 100.168.192.in-addr.arpa dns_managed: true dhcp_leases: /var/lib/dhcpd/dhcpd.leases puppetca: true dir: /usr/share/foreman-proxy custom_repo: true dhcp_managed: true tftp_root: /var/lib/tftpboot/ manage_sudoersd: true ssl_key: /var/lib/puppet/ssl/private_keys/cert-23.pd.infn.it.pem dhcp_gateway: 192.168.100.1 puppetrun_cmd: /usr/sbin/puppetrun ssldir: /var/lib/puppet/ssl use_sudoersd: true ssl_ca: /var/lib/puppet/ssl/certs/ca.pem port: 8443 repo: stable oauth_consumer_secret: dJtDpTXUZaCh8PKYEGCcYLkmVbLZ9Ciy register_in_foreman: true dns_zone: pd.infn.it dns: false dhcp_key_secret: "" dhcp_key_name: "" dhcp_interface: eth0 puppetdir: /etc/puppet dhcp_nameservers: default dhcp: false tftp: true ssl_cert: /var/lib/puppet/ssl/certs/cert-23.pd.infn.it.pem puppet: server_foreman_ssl_cert: /var/lib/puppet/ssl/certs/cert-23.pd.infn.it.pem server_storeconfigs_backend: server_manifest_path: /etc/puppet/manifests server_envs_dir: /etc/puppet/environments agent_noop: false server_facts: true server_report_api: v2 server_post_hook_content: puppet/server/post-receive.erb server_common_modules_path: - /etc/puppet/environments/common - /usr/share/puppet/modules server_dynamic_environments: false client_package: - puppet show_diff: false runmode: service server_enc_api: v2 server_passenger_max_pool: 12 server_vardir: /var/lib/puppet nsauth_template: puppet/namespaceauth.conf.erb pluginsync: true server_foreman_ssl_key: /var/lib/puppet/ssl/private_keys/cert-23.pd.infn.it.pem server_git_repo: false server_dir: /etc/puppet server_group: puppet runinterval: 1800 server_post_hook_name: post-receive server_git_repo_path: /var/lib/puppet/puppet.git server_ca: true server_puppet_basedir: /usr/lib/ruby/site_ruby/1.8/puppet server_foreman_url: https://cert-23.pd.infn.it server_httpd_service: httpd server_port: 8140 server_user: puppet server: true ca_server: splay: false dir: /etc/puppet server_package: - puppet-server server_ssl_dir: /var/lib/puppet/ssl server_environments_owner: puppet server_config_version: listen: false user: puppet server_passenger: true port: 8140 version: present server_puppet_home: /var/lib/puppet server_foreman_ssl_ca: /var/lib/puppet/ssl/certs/ca.pem server_environments: - development - production server_service_fallback: true server_reports: foreman server_app_root: /etc/puppet/rack server_template: puppet/server/puppet.conf.erb server_external_nodes: /etc/puppet/node.rb auth_template: puppet/auth.conf.erb agent_template: puppet/puppet.conf.erb group: puppet foreman: db_password: XXXXXXXXXX db_database: unattended: true gpgcheck: true oauth_map_users: true organizations_enabled: false environment: production selinux: ssl: true use_vhost: true oauth_consumer_key: Fu9aw4dwvKk3BmHm4qGiMJeZeqDzFMHC apache_conf_dir: /etc/httpd/conf.d app_root: /usr/share/foreman custom_repo: true oauth_active: true passenger_scl: ruby193 authentication: true foreman_url: https://cert-23.pd.infn.it user: foreman db_type: postgresql db_manage: true passenger_interface: "" user_groups: - puppet db_port: db_adapter: version: present repo: stable oauth_consumer_secret: dJtDpTXUZaCh8PKYEGCcYLkmVbLZ9Ciy locations_enabled: false db_sslmode: db_username: foreman db_host: puppet_home: /var/lib/puppet group: foreman passenger: true Main Config Menu 1. [✓] Configure foreman_proxy 2. [✓] Configure puppet 3. [✓] Configure foreman 4. Display current config 5. Save and run 6. Cancel run without Saving Choose an option from the menu... 2 Module puppet configuration 1. Enable/disable puppet module, current value: true 2. Set agent_noop, current value: false 3. Set server_envs_dir, current value: /etc/puppet/environments 4. Set server_manifest_path, current value: /etc/puppet/manifests 5. Set server_storeconfigs_backend, current value: 6. Set server_foreman_ssl_cert, current value: /var/lib/puppet/ssl/certs/cert-23.pd.infn.it.pem 7. Set runmode, current value: service 8. Set show_diff, current value: false 9. Set client_package, current value: puppet 10. Set server_dynamic_environments, current value: false 11. Set server_common_modules_path, current value: /etc/puppet/environments/common/usr/share/puppet/modules 12. Set server_post_hook_content, current value: puppet/server/post-receive.erb 13. Set server_report_api, current value: v2 14. Set server_facts, current value: true 15. Set pluginsync, current value: true 16. Set nsauth_template, current value: puppet/namespaceauth.conf.erb 17. Set server_vardir, current value: /var/lib/puppet 18. Set server_passenger_max_pool, current value: 12 19. Set server_enc_api, current value: v2 20. Set runinterval, current value: 1800 21. Set server_group, current value: puppet 22. Set server_dir, current value: /etc/puppet 23. Set server_git_repo, current value: false 24. Set server_foreman_ssl_key, current value: /var/lib/puppet/ssl/private_keys/cert-23.pd.infn.it.pem 25. Set server_ca, current value: true 26. Set server_git_repo_path, current value: /var/lib/puppet/puppet.git 27. Set server_post_hook_name, current value: post-receive 28. Set dir, current value: /etc/puppet -- press enter/return to continue or q to stop -- 29. Set splay, current value: false 30. Set ca_server, current value: 31. Set server, current value: true 32. Set server_user, current value: puppet 33. Set server_port, current value: 8140 34. Set server_httpd_service, current value: httpd 35. Set server_foreman_url, current value: https://cert-23.pd.infn.it 36. Set server_puppet_basedir, current value: /usr/lib/ruby/site_ruby/1.8/puppet 37. Set server_environments_owner, current value: puppet 38. Set server_ssl_dir, current value: /var/lib/puppet/ssl 39. Set server_package, current value: puppet-server 40. Set user, current value: puppet 41. Set listen, current value: false 42. Set server_config_version, current value: 43. Set version, current value: present 44. Set port, current value: 8140 45. Set server_passenger, current value: true 46. Set server_reports, current value: foreman 47. Set server_service_fallback, current value: true 48. Set server_environments, current value: developmentproduction 49. Set server_foreman_ssl_ca, current value: /var/lib/puppet/ssl/certs/ca.pem 50. Set server_puppet_home, current value: /var/lib/puppet 51. Set group, current value: puppet 52. Set agent_template, current value: puppet/puppet.conf.erb 53. Set auth_template, current value: puppet/auth.conf.erb 54. Set server_external_nodes, current value: /etc/puppet/node.rb 55. Set server_template, current value: -- press enter/return to continue or q to stop -- puppet/server/puppet.conf.erb 56. Set server_app_root, current value: /etc/puppet/rack 57. Back to main menu Choose an option from the menu... 57 Main Config Menu 1. [✓] Configure foreman_proxy 2. [✓] Configure puppet 3. [✓] Configure foreman 4. Display current config 5. Save and run 6. Cancel run without Saving Choose an option from the menu…3 Module foreman configuration 1. Enable/disable foreman module, current value: true 2. Set unattended, current value: true 3. Set db_database, current value: 4. Set db_password, current value: XXXXXXXXXXX 5. Set gpgcheck, current value: true 6. Set use_vhost, current value: true 7. Set ssl, current value: true 8. Set selinux, current value: 9. Set environment, current value: production 10. Set organizations_enabled, current value: false 11. Set oauth_map_users, current value: true 12. Set custom_repo, current value: true 13. Set app_root, current value: /usr/share/foreman 14. Set apache_conf_dir, current value: /etc/httpd/conf.d 15. Set oauth_consumer_key, current value: Fu9aw4dwvKk3BmHm4qGiMJeZeqDzFMHC 16. Set foreman_url, current value: https://cert-23.pd.infn.it 17. Set authentication, current value: true 18. Set passenger_scl, current value: ruby193 19. Set oauth_active, current value: true 20. Set db_manage, current value: true 21. Set db_type, current value: postgresql 22. Set user, current value: foreman 23. Set repo, current value: stable 24. Set version, current value: present 25. Set db_adapter, current value: 26. Set db_port, current value: 27. Set user_groups, current value: puppet 28. Set passenger_interface, current value: 29. Set db_host, current value: 30. Set db_username, current value: foreman 31. Set db_sslmode, current value: 32. Set locations_enabled, current value: false 33. Set oauth_consumer_secret, current value: dJtDpTXUZaCh8PKYEGCcYLkmVbLZ9Ciy -- press enter/return to continue or q to stop -- 34. Set passenger, current value: true 35. Set group, current value: foreman 36. Set puppet_home, current value: /var/lib/puppet 37. Back to main menu Choose an option from the menu... Main Config Menu 1. [✓] Configure foreman_proxy 2. [✓] Configure puppet 3. [✓] Configure foreman 4. Display current config 5. Save and run 6. Cancel run without Saving Choose an option from the menu... 5 Could not prefetch mysql_database provider 'mysql': Execution of '/usr/bin/mysql -NBe show databases' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Could not prefetch mysql_grant provider 'mysql': Execution of '/usr/bin/mysql -NBe SELECT CONCAT(User, '@',Host) AS User FROM mysql.user' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Could not prefetch mysql_user provider 'mysql': Execution of '/usr/bin/mysql -NBe SELECT CONCAT(User, '@',Host) AS User FROM mysql.user' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Installing debug: Package[foreman-mysql2](provider=yum): Ensu [25%] [....................... Main Config Menu 1. [✓] Configure foreman_proxy 2. [✓] Configure puppet 3. [✓] Configure foreman 4. Display current config 5. Save and run 6. Cancel run without Saving Choose an option from the menu... 5 Could not prefetch mysql_database provider 'mysql': Execution of '/usr/bin/mysql -NBe show databases' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Could not prefetch mysql_grant provider 'mysql': Execution of '/usr/bin/mysql -NBe SELECT CONCAT(User, '@',Host) AS User FROM mysql.user' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Could not prefetch mysql_user provider 'mysql': Execution of '/usr/bin/mysql -NBe SELECT CONCAT(User, '@',Host) AS User FROM mysql.user' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Installing Done [100%] [.........................................................................................] Success! * Foreman is running at https://cert-23.pd.infn.it Default credentials are 'admin:changeme' * Foreman Proxy is running at https://cert-23.pd.infn.it:8443 * Puppetmaster is running at port 8140 The full log is at /var/log/foreman-installer/foreman-installer.log [root@cert-23 ~]# ps -ef |grep foreman 497 28922 1 0 11:58 ? 00:00:00 /usr/bin/ruby /usr/share/foreman-proxy/bin/smart-proxy foreman 28987 1 0 11:59 ? 00:00:05 Passenger RackApp: /usr/share/foreman root 30660 27208 0 12:40 pts/1 00:00:00 grep foreman [root@cert-23 ~]# /etc/init.d/foreman status Foreman is running under passenger [PASSED] [root@cert-23 ~]# /etc/init.d/foreman-proxy status foreman-proxy (pid 28922) is running... [root@cert-23 ~]# ps -ef |grep mysql root 28477 1 0 11:58 ? 00:00:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --socket=/var/lib/mysql/mysql.sock --pid-file=/var/run/mysqld/mysqld.pid --basedir=/usr --user=mysql mysql 28635 28477 0 11:58 ? 00:00:02 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql --log-error=/var/lib/mysql/cert-23.pd.infn.it.err --pid-file=/var/run/mysqld/mysqld.pid --socket=/var/lib/mysql/mysql.sock --port=3306 root 29683 27208 0 12:11 pts/1 00:00:00 grep mysql [root@cert-23 ~]# /etc/init.d/puppet status puppetd (pid 29064) is running... [root@cert-23 ~]# /etc/init.d/puppetmaster status puppetmasterd is stopped [root@cert-23 ~]# ll /etc/foreman/database.yml -rw-r----- 1 root foreman 657 Nov 7 11:58 /etc/foreman/database.yml [root@cert-23 ~]# cat /etc/foreman/database.yml ### File managed with puppet ### ## Module: 'foreman' ## Template source: 'MODULES/foreman/templates/database.yml.erb' # SQLite version 3.x development: adapter: sqlite3 database: db/development.sqlite3 pool: 5 timeout: 5000 # Warning: The database defined as "test" will be erased and # re-generated from your development database when you run "rake". # Do not set this db to the same as development or production. test: adapter: sqlite3 database: db/test.sqlite3 pool: 5 timeout: 5000 # Database is managed by foreman::database::mysql production: adapter: mysql2 database: puppet username: foreman password: pippo123 [root@cert-23 ~]# ll /etc/httpd/conf.d/ total 32 -rw-r--r-- 1 root root 1404 Nov 7 11:58 foreman.conf -rw-r--r-- 1 root root 770 Jun 10 17:30 passenger.conf -rw-r--r-- 1 root root 1505 Nov 7 11:58 puppet.conf -rw-r--r-- 1 root root 392 Aug 13 18:51 README -rw-r--r-- 1 root root 9473 Aug 2 13:59 ssl.conf -rw-r--r-- 1 root root 299 Aug 2 13:59 welcome.conf [root@cert-23 ~]# grep PassengerMaxRequests /etc/httpd/conf.d/* /etc/httpd/conf.d/puppet.conf: # PassengerMaxRequests 1000 /etc/httpd/conf.d/puppet.conf: PassengerMaxRequests 1 [root@cert-23 foreman]# ruby193-rake permissions:reset RAILS_ENV=production Reset to user:admin, password:changeme ################## [root@cert-23 ~]# rpm -e puppetlabs-release foreman-release [root@cert-23 ~]# yum install http://repos.fedorapeople.org/repos/openstack/openstack-havana/rdo-release-havana-7.noarch.rpm [root@cert-23 ~]# yum install openstack-foreman-installer […] Dependencies Resolved ========================================================================================================= Package Arch Version Repository Size ========================================================================================================= Installing: openstack-foreman-installer noarch 0.0.21-1.el6 openstack-havana 50 k Installing for dependencies: augeas x86_64 0.9.0-4.el6 sl 26 k foreman-mysql noarch 1.3.0-1.el6 foreman 9.4 k hiera noarch 1.2.1-1.el6 puppetlabs-products 21 k libxslt x86_64 1.1.26-2.el6_3.1 sl 451 k packstack-modules-puppet noarch 2013.2.1-0.11.dev806.el6 openstack-havana 497 k ruby-rgen noarch 0.6.5-1.el6 puppetlabs-deps 87 k ruby193-rubygem-deface noarch 0.7.2-6.el6 foreman-plugins 13 k ruby193-rubygem-foreman_simplify noarch 0.0.5-1.el6 foreman-plugins 9.2 k ruby193-rubygem-mysql x86_64 2.8.1-5.el6 foreman 90 k ruby193-rubygem-nokogiri x86_64 1.5.6-7.el6 foreman 334 k Updating for dependencies: puppet noarch 3.3.1-1.el6 puppetlabs-products 1.1 M puppet-server noarch 3.3.1-1.el6 puppetlabs-products 23 k [root@cert-23 ~]# facter fqdn cert-23.pd.infn.it [root@cert-23 ~]# hostname --fqdn cert-23.pd.infn.it [root@cert-23 ~]# cat env_foreman export PRIVATE_CONTROLLER_IP=193.206.210.250 export PRIVATE_INTERFACE=eth0 export PRIVATE_NETMASK=255.255.255.0 export PUBLIC_CONTROLLER_IP=193.206.210.250 export PUBLIC_INTERFACE=eth0 export PUBLIC_NETMASK=255.255.255.0 export FOREMAN_GATEWAY=false export FOREMAN_PROVISIONING=false [root@cert-23 bin]# ./foreman_server.sh #################### RED HAT OPENSTACK ##################### Thank you for using the Red Hat OpenStack Foreman Installer! Please note that this tool is a Technology Preview For more information about Red hat Technology Previews, see https://access.redhat.com/support/offerings/techpreview/ ############################################################ Press [Enter] to continue net.ipv4.ip_forward = 1 setenforce: SELinux is disabled Saved 1 file(s) /usr/share/foreman-installer /usr/share/openstack-foreman-installer/bin Info: Loading facts in /usr/share/foreman-installer/modules/postgresql/lib/facter/postgres_default_version.rb Info: Loading facts in /usr/share/foreman-installer/modules/concat/lib/facter/concat_basedir.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/root_home.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/pe_version.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/puppet_vardir.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/facter_dot_d.rb Warning: Config file /etc/puppet/hiera.yaml not found, using Hiera defaults Notice: Compiled catalog for cert-23.pd.infn.it in environment production in 5.72 seconds Info: Loading facts in /usr/share/foreman-installer/modules/postgresql/lib/facter/postgres_default_version.rb Info: Loading facts in /usr/share/foreman-installer/modules/concat/lib/facter/concat_basedir.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/root_home.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/pe_version.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/puppet_vardir.rb Info: Loading facts in /usr/share/foreman-installer/modules/stdlib/lib/facter/facter_dot_d.rb Info: Applying configuration version '1383863836' Info: FileBucket adding {md5}3c1e7165d02bce597f3a46960fd34063 Info: /Stage[main]/Foreman::Config::Passenger/File[foreman_vhost]: Filebucketed /etc/httpd/conf.d/foreman.conf to puppet with sum 3c1e7165d02bce597f3a46960fd34063 Notice: /Stage[main]/Foreman::Config::Passenger/File[foreman_vhost]/content: content changed '{md5}3c1e7165d02bce597f3a46960fd34063' to '{md5}9774a83f2e949d4c3103268a6edbebad' Info: /Stage[main]/Foreman::Config::Passenger/File[foreman_vhost]: Scheduling refresh of Exec[reload-apache] Info: FileBucket adding {md5}f976badcfebfaf553ad0e3931f96bd54 Info: /Stage[main]/Foreman::Config/File[/etc/foreman/database.yml]: Filebucketed /etc/foreman/database.yml to puppet with sum f976badcfebfaf553ad0e3931f96bd54 Notice: /Stage[main]/Foreman::Config/File[/etc/foreman/database.yml]/content: content changed '{md5}f976badcfebfaf553ad0e3931f96bd54' to '{md5}c3f02c5c4a3bf340158ebd74f4831f60' Info: /Stage[main]/Foreman::Config/File[/etc/foreman/database.yml]: Scheduling refresh of Class[Foreman::Service] Info: Class[Foreman::Config]: Scheduling refresh of Class[Foreman::Database] Info: Class[Foreman::Database]: Scheduling refresh of Exec[dbmigrate] Notice: /Stage[main]/Puppet::Service/Service[puppet]/ensure: ensure changed 'running' to 'stopped' Notice: /Stage[main]/Foreman::Database::Mysql/Mysql::Db[foreman]/Mysql_database[foreman]/ensure: created Notice: /Stage[main]/Foreman::Database::Mysql/Mysql::Db[foreman]/Mysql_user[foreman@localhost]/password_hash: password_hash changed '*37FAB51427DEA4429075D7AB1E625CD553CBCE06' to '*4F44F33FAAC7672EB072C36E635AA74239CE3FFF' Notice: /Stage[main]/Foreman::Database::Mysql/Mysql::Db[foreman]/Mysql_grant[foreman@localhost/foreman.*]/ensure: created Info: Class[Foreman::Database::Mysql]: Scheduling refresh of Exec[dbmigrate] Notice: /Stage[main]/Foreman::Database/Exec[dbmigrate]: Triggered 'refresh' from 2 events Info: Class[Foreman::Database]: Scheduling refresh of Class[Foreman::Service] Info: Class[Foreman::Service]: Scheduling refresh of Service[foreman] Notice: /Stage[main]/Foreman::Service/Service[foreman]: Triggered 'refresh' from 1 events Info: FileBucket adding {md5}edc001925aa56870c003bed8e1e3b189 Info: /Stage[main]/Puppet::Config/File[/etc/puppet/puppet.conf]: Filebucketed /etc/puppet/puppet.conf to puppet with sum edc001925aa56870c003bed8e1e3b189 Notice: /Stage[main]/Puppet::Config/File[/etc/puppet/puppet.conf]/content: content changed '{md5}edc001925aa56870c003bed8e1e3b189' to '{md5}9c6dae855ae4393c4c309ad91c62931e' Notice: /Stage[main]/Puppet::Cron/Cron[puppet]/ensure: created Info: FileBucket adding {md5}a869feee3eb40f0ee7bedacea51db527 Info: /Stage[main]/Puppet::Server::Rack/File[/etc/puppet/rack/config.ru]: Filebucketed /etc/puppet/rack/config.ru to puppet with sum a869feee3eb40f0ee7bedacea51db527 Notice: /Stage[main]/Puppet::Server::Rack/File[/etc/puppet/rack/config.ru]/content: content changed '{md5}a869feee3eb40f0ee7bedacea51db527' to '{md5}bf52c982bf4e679f120f98cc762ae19d' Info: /Stage[main]/Puppet::Server::Rack/File[/etc/puppet/rack/config.ru]: Scheduling refresh of Exec[puppet_server_rack-restart] Notice: /Stage[main]/Puppet::Server::Rack/Exec[puppet_server_rack-restart]: Triggered 'refresh' from 1 events Info: FileBucket got a duplicate file {md5}bde8062ad58d9cae7cf646b990dfc472 Info: /Stage[main]/Puppet::Server::Passenger/File[puppet_vhost]: Filebucketed /etc/httpd/conf.d/puppet.conf to puppet with sum bde8062ad58d9cae7cf646b990dfc472 Notice: /Stage[main]/Puppet::Server::Passenger/File[puppet_vhost]/content: content changed '{md5}bde8062ad58d9cae7cf646b990dfc472' to '{md5}16b0d2ef51fa19e37be186f4a9eaead7' Info: /Stage[main]/Puppet::Server::Passenger/File[puppet_vhost]: Scheduling refresh of Exec[reload-apache] Notice: /Stage[main]/Apache::Service/Exec[reload-apache]: Triggered 'refresh' from 2 events Info: FileBucket adding {md5}37c8333d032d884f432db823ec530ad6 Info: /Stage[main]/Foreman_proxy::Config/File[/etc/sudoers.d/foreman-proxy]: Filebucketed /etc/sudoers.d/foreman-proxy to puppet with sum 37c8333d032d884f432db823ec530ad6 Notice: /Stage[main]/Foreman_proxy::Config/File[/etc/sudoers.d/foreman-proxy]/content: content changed '{md5}37c8333d032d884f432db823ec530ad6' to '{md5}6e7393cffe1da1fe8b731dabbf47d989' Info: FileBucket adding {md5}cd4a09c8b8efac781898c35093edf6a5 Info: /Stage[main]/Foreman_proxy::Config/File[/etc/foreman-proxy/settings.yml]: Filebucketed /etc/foreman-proxy/settings.yml to puppet with sum cd4a09c8b8efac781898c35093edf6a5 Notice: /Stage[main]/Foreman_proxy::Config/File[/etc/foreman-proxy/settings.yml]/content: content changed '{md5}cd4a09c8b8efac781898c35093edf6a5' to '{md5}daa9d1374d99812d653b49b53afe594b' Info: /Stage[main]/Foreman_proxy::Config/File[/etc/foreman-proxy/settings.yml]: Scheduling refresh of Class[Foreman_proxy::Service] Info: Class[Foreman_proxy::Config]: Scheduling refresh of Class[Foreman_proxy::Service] Info: Class[Foreman_proxy::Service]: Scheduling refresh of Service[foreman-proxy] Notice: /Stage[main]/Foreman_proxy::Service/Service[foreman-proxy]: Triggered 'refresh' from 1 events Info: Class[Foreman_proxy::Service]: Scheduling refresh of Class[Foreman_proxy::Register] Notice: /Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[cert-23.pd.infn.it]/ensure: created Notice: Finished catalog run in 37.66 seconds /usr/share/openstack-foreman-installer/bin Reset to user:admin, password:changeme W, [07/11/2013 23:38:11#23674] WARN -- : POST KO: {:smart_proxy=>{:name=>"proxy1", :url=>"https://cert-23.pd.infn.it:8443"}} => {"smart_proxy":{"id":null,"errors":{"url":["nur eine Angabe eines Proxy ist erlaubt"]},"full_messages":["URL nur eine Angabe eines Proxy ist erlaubt"]}} Foreman is installed and almost ready for setting up your OpenStack First, you need to alter a few parameters in Foreman. Visit: https://cert-23.pd.infn.it/hostgroups From this list, click on each class that you plan to use Go to the Smart Class Parameters tab and work though each of the parameters in the left-hand column Then copy /tmp/foreman_client.sh to your openstack client nodes Run that script and visit the HOSTS tab in foreman. Pick some host groups for your nodes based on the configuration you prefer For further directions, see: http://openstack.redhat.com/Deploying_RDO_Using_Foreman Once puppet runs on the machines, OpenStack is ready!