🧪 Real-World QA Scenarios
Real-World QA Scenarios: Debugging a failing CI pipeline on a live Linux agent is like performing surgery on a running engine — the system cannot be stopped, the environment cann
Debugging a failing CI pipeline on a live Linux agent is like performing surgery on a running engine — the system cannot be stopped, the environment cannot be changed, and every action you take might make things worse if you misdiagnose. The real-world QA scenario looks like this: your nightly regression suite started failing at 2 AM, the error is "Connection refused on port 5432", the logs show nothing useful, and you have 45 minutes before the next meeting. This is where Linux command fluency pays for itself — `ss -tulpn | grep 5432` tells you in two seconds whether the database is running at all; `journalctl -u postgresql -n 50` shows you the last fifty log lines; `df -h` tells you if the disk is full (a surprisingly common cause of database crashes). But here is the deeper question: why does this happen only in CI and not locally? Because CI containers are ephemeral — they start fresh from an image, they have strict memory and disk limits, they do not preserve state between runs, and they run as a restricted user without the environment variables your local shell defines automatically. In Java terms, debugging a CI-only failure is like debugging a `ClassNotFoundException` that only appears in production: the code is identical, but the runtime environment — classpath, user, permissions, available memory — is completely different.
Connecting and inspecting
Initiate the connection
Run ssh qa@jenkins-agent-01; on first connection you may be asked to confirm the host key fingerprint.
You authenticate with a password or SSH key (id_rsa/id_ed25519); the prompt changes to qa@jenkins-agent-01:~$.
Move to the workspace
Run cd /var/lib/jenkins/workspace/regression-suite — you are now inside the build folder on the remote server.
Run tail -f build.log; as the build progresses, new lines appear in the terminal instantly.
Close the connection
Stop tail with Ctrl+C, then close the ssh session with exit or Ctrl+D to return to the local terminal.
Order the process of connecting to a CI agent and watching the build log live.
ssh qa@jenkins-agent-01 — connect to the remote server
cd /var/lib/jenkins/workspace/regression-suite — move to the build folder
tail -f build.log — start watching the log live