CodeWithMMAK

What is PuTTY and How Do QA Engineers Use It? A Complete Guide

Discover why PuTTY is an essential tool for Quality Engineering. Learn how to connect to remote servers, check logs, and perform backend testing efficiently.

CodeWithMMAK
March 15, 2024
8 min

Introduction

🎯 Quick Answer

PuTTY is a free, open-source terminal emulator and network file transfer application that supports several network protocols, including SSH, Telnet, and Rlogin. For QA Engineers, PuTTY is primarily used to connect to remote Linux/Unix servers to monitor application logs, verify database states, restart services, and manage test environments via a Command Line Interface (CLI).

In the world of software testing, especially for web and enterprise applications, the "frontend" is only half the story. To truly validate a system, QA Engineers often need to peek under the hood at the servers where the application lives. This is where PuTTY becomes an indispensable tool in a tester's toolkit.

📖 Key Definitions

PuTTY

A free and open-source terminal emulator, serial console, and network file transfer application.

SSH (Secure Shell)

A cryptographic network protocol for operating network services securely over an unsecured network.

Terminal Emulator

A program that allows the use of a computer terminal in a graphical user interface (GUI) environment.

Logs

Files that record events occurring within an operating system or software application, critical for debugging.

Why Do QA Engineers Use PuTTY?

While developers use PuTTY for coding and deployment, QA engineers use it for verification and troubleshooting. Here are the most common use cases:

  1. Log Monitoring: Using commands like tail -f to watch real-time application logs while performing actions in the UI. This helps identify hidden errors or stack traces.
  2. Environment Setup: Modifying configuration files or cleaning up temporary directories before starting a test cycle.
  3. Database Verification: Connecting to a database CLI (like MySQL or PostgreSQL) on the server to verify that data submitted via the UI is correctly stored.
  4. Process Management: Restarting application servers (like Tomcat, JBoss, or Node.js) when they become unresponsive during testing.
  5. File Transfer: Moving test data files or build artifacts between a local machine and a remote server (often using the companion tool, PSCP).

🚀 Step-by-Step Implementation

1

Download and Install

Visit the official PuTTY website and download the installer for Windows. Run the setup and launch the application.

2

Enter Host Details

In the Session category, enter the Host Name (or IP address) of your test server. Ensure the port is set to 22 (default for SSH).

3

Configure Appearance (Optional)

Go to Window > Appearance to change the font or Window > Colours to adjust the background for better readability during long log-watching sessions.

4

Open the Connection

Click Open. A black terminal window will appear. If it's your first time connecting, you'll see a security alert; click Yes to trust the host.

5

Login

Enter your username and password when prompted. Note: For security, the cursor won't move while typing your password.

6

Execute Commands

Once logged in, you can navigate directories (cd), list files (ls), or view logs (tail -f myapp.log).

Essential Linux Commands for QA

If you're using PuTTY, you're likely interacting with a Linux server. Here are the "Must-Know" commands for any tester:

  • tail -f <filename>: View the end of a file in real-time (perfect for logs).
  • grep -i "error" <filename>: Search for the word "error" in a file, ignoring case.
  • ps -ef | grep <service>: Check if a specific service or process is running.
  • top: View system resource usage (CPU/RAM), useful for performance testing.
  • df -h: Check disk space, as full disks often cause application crashes.

Common Errors & Best Practices

⚠️ Common Errors & Pitfalls

  • Network error: Connection timed out

    Usually means the IP address is wrong, the server is down, or a firewall is blocking port 22.

  • Access Denied

    Occurs if the username or password is incorrect, or if your user account doesn't have SSH permissions on that server.

  • Connection closed by remote host

    Often happens due to inactivity. You can fix this by enabling "Keepalives" in the Connection settings.

Best Practices

  • Save your sessions! Instead of typing the IP every time, give the connection a name in the "Saved Sessions" list and click Save.
  • Use SSH Keys instead of passwords for better security and faster logins if your organization supports it.
  • Enable Logging in PuTTY settings to save your entire terminal session to a text file for later analysis or bug reporting.
  • Never run rm -rf unless you are 100% sure of the directory. As a QA, you should rarely need to delete files recursively.

Frequently Asked Questions

Is PuTTY available for macOS?

While there are ports, macOS users typically use the built-in Terminal app, which has SSH built-in.

Can I transfer files with PuTTY?

PuTTY itself is for terminal access. Use WinSCP or FileZilla for a graphical file transfer experience, or PSCP for command-line transfers.

How do I copy-paste in PuTTY?

Simply highlight text with your mouse to copy it. To paste, just Right-Click anywhere in the terminal window.

Conclusion

PuTTY is more than just a "black box" terminal; it is a window into the server-side logic of the applications we test. By mastering PuTTY and basic Linux commands, a QA Engineer can move beyond surface-level UI testing and provide much deeper insights into why a system is failing, making them a far more effective member of any technical team.

📝 Summary & Key Takeaways

PuTTY is a vital tool for Quality Engineers, providing secure SSH access to remote servers for backend validation and troubleshooting. By connecting to the server's CLI, testers can monitor real-time logs, verify database integrity, and manage test environments. Success with PuTTY involves understanding basic Linux navigation, configuring saved sessions for efficiency, and following security best practices like using SSH keys. Ultimately, the ability to use PuTTY allows QA professionals to bridge the gap between frontend behavior and backend execution, leading to more comprehensive bug reports and faster resolution times.

Share it with your network and help others learn too!

Follow me on social media for more developer tips, tricks, and tutorials. Let's connect and build something great together!