Description
Details
- Other Assignee
- Dzahn
| Title | Reference | Author | Source Branch | Dest Branch | |
|---|---|---|---|---|---|
| phabricator-targets: add phab1005 | repos/phabricator/deployment!115 | aokoth | T377889 | wmf/stable |
Event Timeline
Info: Applying configuration version '(53672bf49c) Dzahn - Revert "phabricator: comment out scap::target in migration class"' Error: Execution of '/usr/bin/scap deploy-local --repo phabricator/deployment -D log_json:False' returned 1: 17:14:53 Fetch from: http://deploy1003.eqiad.wmnet/phabricator/deployment/.git 17:14:54 Update submodules 17:14:54 Updating .gitmodule: /srv/deployment/phabricator/deployment-cache/cache 17:15:12 Checkout rev: f8d7b38df39896e5e2792d70fa04b81f3b6450e3 17:15:12 Updating .gitmodule: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/local.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/local.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/mail.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/mail.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/phd.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/phd.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/vcs.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/vcs.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/www.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/www.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/preamble.php using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/preamble.php: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/redirect_config.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/redirect_config.json: [rendered] 17:15:31 Executing check 'config_deploy' 17:15:31 Check 'config_deploy' failed: /usr/local/sbin/phab_deploy_config_deploy: 8: .: cannot open /etc/phabricator/script-vars: No such file Error: /Stage[main]/Profile::Phabricator::Migration/Scap::Target[phabricator/deployment]/Package[phabricator/deployment]/ensure: change from 'absent' to 'present' failed: Execution of '/usr/bin/scap deploy-local --repo phabricator/deployment -D log_json:False' returned 1: 17:14:53 Fetch from: http://deploy1003.eqiad.wmnet/phabricator/deployment/.git 17:14:54 Update submodules 17:14:54 Updating .gitmodule: /srv/deployment/phabricator/deployment-cache/cache 17:15:12 Checkout rev: f8d7b38df39896e5e2792d70fa04b81f3b6450e3 17:15:12 Updating .gitmodule: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/local.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/local.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/mail.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/mail.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/phd.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/phd.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/vcs.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/vcs.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/www.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/conf/local/www.json: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/preamble.php using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/preamble.php: [rendered] 17:15:31 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/redirect_config.json using /etc/phabricator/config.yaml 17:15:31 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/redirect_config.json: [rendered] 17:15:31 Executing check 'config_deploy' 17:15:31 Check 'config_deploy' failed: /usr/local/sbin/phab_deploy_config_deploy: 8: .: cannot open /etc/phabricator/script-vars: No such file
BUT also:
Notice: /Stage[main]/Profile::Phabricator::Migration/Scap::Target[phabricator/deployment]/Ssh::Userkey[phab-deploy]/File[/etc/ssh/userkeys/phab-deploy]/ensure: defined content as '{sha256}0965c405d7f4d3b0b470328a0d4cb9e8dc6b4440a6b11608a09caf10016c6d64'
Info: Scap::Target[phabricator/deployment]: Unscheduling all events on Scap::Target[phabricator/deployment]
Notice: /Stage[main]/Scap::Ferm/Firewall::Service[deployment-ssh]/Nftables::Service[deployment-ssh]/File[/etc/nftables/input/10_deployment-ssh.nft]/ensure: defined content as '{sha256}e686be75ea00532efa5deab346ddfb9f59905bac3c3cbdc2e0d84cc7d82ef475'
Info: /Stage[main]/Scap::Ferm/Firewall::Service[deployment-ssh]/Nftables::Service[deployment-ssh]/File[/etc/nftables/input/10_deployment-ssh.nft]: Scheduling refresh of Service[nftables]
Notice: /Stage[main]/Nftables/Systemd::Service[nftables]/Service[nftables]: Triggered 'refresh' from 1 event
Info: Stage[main]: Unscheduling all events on Stage[main]
Notice: Applied catalog in 59.19 secondsOn second puppet run, after that scap::target was created and the phab-deploy SSH key was written.. and the firewall hole was opened.
Still have this though:
17:24:46 Check 'config_deploy' failed: /usr/local/sbin/phab_deploy_config_deploy: 8: .: cannot open /etc/phabricator/script-vars: No such file
Mentioned in SAL (#wikimedia-operations) [2025-06-17T17:27:48Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889
Mentioned in SAL (#wikimedia-operations) [2025-06-17T17:28:11Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (duration: 00m 23s)
Change #1160217 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: add /etc/phabricator/script-vars for scap
Change #1160217 merged by Dzahn:
[operations/puppet@production] phabricator::migration: add /etc/phabricator/script-vars for scap
After my latest merge, puppet created that missing /etc/phabricator/script-vars file now.
Now we are at:
fatal: destination path '/srv/deployment/phabricator/deployment-cache/cache' already exists and is not an empty directory. 18:14:40 deploy-local failed: <FailedCommand> Command 'git clone --jobs 46 --config lfs.url=https://gitlab.wikimedia.org/repos/phabricator/deployment.git/info/lfs http://deploy1003.eqiad.wmnet/phabricator/deployment/.git /srv/deployment/phabricator/deployment-cache/cache' failed with exit code 128;
Did a manual rm -rf /srv/deployment/phabricator/deployment-cache/cache and trying again.
After this, the "fatal: destination path .. already exists" part is gone.
Now at:
Error: Execution of '/usr/bin/scap deploy-local --repo phabricator/deployment -D log_json:False' returned 1: 18:17:29 Fetch from: http://deploy1003.eqiad.wmnet/phabricator/deployment/.git
When trying to run this manually.. it's back to the previous issue before.
Mentioned in SAL (#wikimedia-operations) [2025-06-17T18:24:13Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T18:24:31Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling) (duration: 00m 18s)
Deleted that .cache dir one more time. Ran the command manually as phab-deploy user, before puppet ran again..and:
[phab1005:~] $ sudo -u phab-deploy /usr/bin/scap deploy-local --repo phabricator/deployment -D log_json:False 18:23:14 Fetch from: http://deploy1003.eqiad.wmnet/phabricator/deployment/.git 18:23:14 Update submodules 18:23:14 Updating .gitmodule: /srv/deployment/phabricator/deployment-cache/cache .. 18:23:33 Rendering config_file: /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/redirect_config.json using /etc/phabricator/config.yaml 18:23:33 /srv/deployment/phabricator/deployment-cache/revs/f8d7b38df39896e5e2792d70fa04b81f3b6450e3/phabricator/support/redirect_config.json: [unchanged] 18:23:33 Executing check 'config_deploy' 18:23:33 Check 'config_deploy' failed: $SCAP_REV_PATH is not defined. Note: This script is only intended to run as a scap deploy check
Looking much greener now :)
Change #1160231 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: add missing sudo_defaults file for scap
Change #1160231 merged by Dzahn:
[operations/puppet@production] phabricator::migration: add missing sudo_defaults file for scap
The mssing scap_sudo_defaults file has been created:
Notice: /Stage[main]/Profile::Phabricator::Migration/File[/etc/sudoers.d/scap_sudo_defaults]/ensure
Now the puppet run finishes without any issues :)
@brennen Please try again now.
Mentioned in SAL (#wikimedia-operations) [2025-06-17T19:12:36Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T19:12:46Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling) (duration: 00m 10s)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T21:26:57Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T21:27:04Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling) (duration: 00m 07s)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T21:29:29Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T21:29:36Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling) (duration: 00m 07s)
Change #1160270 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: include phabricator::httpd, add /srv/phab dir
Change #1160270 merged by Dzahn:
[operations/puppet@production] phabricator::migration: include phabricator::httpd, add /srv/phab dir
Change #1160280 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: install PHP
Change #1160280 merged by Dzahn:
[operations/puppet@production] phabricator::migration: install PHP
Mentioned in SAL (#wikimedia-operations) [2025-06-17T22:25:36Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T22:25:43Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling) (duration: 00m 07s)
Mentioned in SAL (#wikimedia-operations) [2025-06-17T22:26:59Z] <brennen@deploy1003> Started deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling)
Change #1160310 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: ensure /srv/phab is the correct symlink
Mentioned in SAL (#wikimedia-operations) [2025-06-17T23:30:03Z] <brennen@deploy1003> Finished deploy [phabricator/deployment@f8d7b38]: re-test deploy to phab1005 for T377889 (once more, with feeling) (duration: 63m 03s)
Change #1160310 merged by Dzahn:
[operations/puppet@production] phabricator::migration: ensure /srv/phab is the correct symlink
A scap phab deployment has been working now! :)
I re-enabled puppet after we had applied some manual hacks. (like commenting out apache restart before apache was installed, re-enabling puppet by deployment script, creating missing symlink,)..
The symlink is now puppetized; apache can be restarted, puppet can be enabled and disabled; just one thing is left: variable values in /etc/phabricator/script-vars are not expanded. The file itself is created by puppet from a template.
Also: PHP8.2 is installed..with all the same modules a prod phab host has.. and if this works then Phorge is just fine with bookworm default version for T372619.
Change #1161042 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: add parameters phabdir,storage_user,deploy_user
Change #1161042 merged by Dzahn:
[operations/puppet@production] phabricator::migration: add parameters phabdir,storage_user,deploy_user
Change #1161048 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: puppetize password for testdb in script-vars
Change #1161051 had a related patch set uploaded (by Dzahn; author: Dzahn):
[labs/private@master] add fake password for phab test db admin user
Change #1161051 merged by Dzahn:
[labs/private@master] add fake password for phab test db admin user
Change #1161048 merged by Dzahn:
[operations/puppet@production] phabricator::migration: puppetize password for testdb in script-vars
Change #1161053 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: fix variable name used for testdb storage pass
Change #1161053 merged by Dzahn:
[operations/puppet@production] phabricator::migration: fix variable name used for testdb storage pass
Change #1161059 had a related patch set uploaded (by Dzahn; author: Dzahn):
[operations/puppet@production] phabricator::migration: fix /srv/phab symlink, /srv/repos dir
Change #1161059 merged by Dzahn:
[operations/puppet@production] phabricator::migration: fix /srv/phab symlink, /srv/repos dir
This is also fixed now. The password for the test db is now properly puppetized in the private repo in it's own class.. without touching prod phab db passwords.
And puppet ensures /srv/phab is the proper symlink to the deployment dir.
Change #1137818 merged by Dzahn:
[operations/puppet@production] scap: stop hardcoding scap user home to fix puppet breakage
Change #1306283 had a related patch set uploaded (by AOkoth; author: AOkoth):
[operations/puppet@production] phabricator: add multi-replica support
Change #1310621 had a related patch set uploaded (by AOkoth; author: AOkoth):
[operations/puppet@production] site: revert phab1005 to insetup
Cookbook cookbooks.sre.hosts.reimage was started by aokoth@cumin1003 for host phab1005.eqiad.wmnet with OS trixie
Cookbook cookbooks.sre.hosts.reimage started by aokoth@cumin1003 for host phab1005.eqiad.wmnet with OS trixie completed:
- phab1005 (PASS)
- Downtimed on Icinga/Alertmanager
- Disabled Puppet
- Removed from Puppet and PuppetDB if present and deleted any certificates
- Removed from Debmonitor if present
- Forced PXE for next reboot
- Host rebooted via IPMI
- Host up (Debian installer)
- Checked BIOS boot parameters are back to normal
- Host up (new fresh trixie OS)
- Generated Puppet certificate
- Signed new Puppet certificate
- Run Puppet in NOOP mode to populate exported resources in PuppetDB
- Found Nagios_host resource for this host in PuppetDB
- Downtimed the new host on Icinga/Alertmanager
- Removed previous downtime on Alertmanager (old OS)
- First Puppet run completed and logged in /var/log/spicerack/sre/hosts/reimage/202607142023_aokoth_4137552_phab1005.out
- configmaster.wikimedia.org updated with the host new SSH public key for wmf-update-known-hosts-production
- Rebooted
- Automatic Puppet run was successful
- Forced a re-check of all Icinga services for the host
- Icinga status is optimal
- Icinga downtime removed
- Updated Netbox data from PuppetDB
Change #1320217 had a related patch set uploaded (by AOkoth; author: AOkoth):
[operations/puppet@production] site: apply migration role to phab1005
Change #1320217 merged by AOkoth:
[operations/puppet@production] site: apply migration role to phab1005
Change #1306283 merged by AOkoth:
[operations/puppet@production] phabricator: add multi-replica support
Change #1321048 had a related patch set uploaded (by AOkoth; author: AOkoth):
[operations/puppet@production] hieradata: reenable scap bootstrapping on phab1005
Change #1321048 merged by AOkoth:
[operations/puppet@production] hieradata: reenable scap bootstrapping on phab1005
aokoth opened https://gitlab.wikimedia.org/repos/phabricator/deployment/-/merge_requests/115
phabricator-targets: add phab1005
brennen merged https://gitlab.wikimedia.org/repos/phabricator/deployment/-/merge_requests/115
phabricator-targets: add phab1005
Change #1321581 had a related patch set uploaded (by AOkoth; author: AOkoth):
[operations/puppet@production] mariadb: add grants for phab1005
Change #1321581 merged by AOkoth:
[operations/puppet@production] mariadb: add grants for phab1005
@Aklapper I was hoping to use this to track decommissioning phab1004. I think once we've done that we can consider this complete.
Change #1332730 had a related patch set uploaded (by AOkoth; author: AOkoth):
[operations/puppet@production] phabricator: decom phab1004 and add phab1006
There is a dedicated form for decoms: https://phabricator.wikimedia.org/maniphest/task/edit/form/52/.
For the sake of finding tickets again I'd also prefer a separate ticket for phab1004 decommission. This ticket is called "install a service on phab1005". Different machine... :)