How to install and use SQuirreL SQL on Linux

Introduction

In the world of database administration, having a graphical tool that allows you to explore schemas, run queries, and manage permissions intuitively is essential. In this article we focus on SQuirreL SQL, a cross‑platform open‑source client that works excellently in Linux environments. We will see how to install it, configure it, and get the most out of it to improve your daily productivity.

What is SQuirreL SQL?

SQuirreL SQL is a Java application based on the JDBC standard that lets you connect to practically any compatible database engine, such as MySQL, PostgreSQL, Oracle, SQL Server, and many more. Its interface is organized in tabs that show the object tree, a query editor, and a results console. Being cross‑platform, the same version you download for Windows works unchanged in Linux distributions, provided you have a Java runtime installed.

Advantages of Using SQuirreL on Linux

Using SQuirreL on a Linux system brings several advantages: first, integration with the package manager makes installation and updates easy; second, resource consumption tends to be lower than in Windows environments thanks to the efficiency of the Linux kernel; third, you can run it without problems on headless servers by using lightweight desktop environments like XFCE or LXQt, or even via X11 forwarding. Moreover, being free software, you can inspect its code, contribute, or adapt it to your specific needs.

Installation on Ubuntu and Debian

On Debian‑based distributions the package is available in the official repositories. Open a terminal and run:

  • sudo apt update
  • sudo apt install squirrel-sql

If you prefer the latest version, you can download the generic installer from the official website, give it execution permissions, and run it with Java:

  • chmod +x squirrel-sql-*-installer.jar
  • java -jar squirrel-sql-*-installer.jar

During the process the installer will ask you to choose the installation directory and whether you want to create a shortcut in the applications menu.

Installation on Fedora

On Fedora the package is located in the RPM Fusion repositories. First make sure the repository is enabled:

  • sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm

Then install SQuirreL SQL:

  • sudo dnf install squirrel-sql

For users who prefer the most recent version, the same generic installer method works; just make sure you have java-11-openjdk or a newer version installed.

Installation on Arch Linux

On Arch the package is found in the community AUR repository. You can install it with a helper like yay:

  • yay -S squirrel-sql

If you prefer to compile it manually, download the PKGBUILD from AUR, review the changes, and run makepkg -si. After installation, run squirrel-sql from the menu or the terminal.

Initial Configuration and Database Connection

Once installed, launch the application. In the first window a wizard appears to create a connection alias. The steps are:

  • Select the appropriate JDBC driver for your database engine (e.g., org.postgresql.Driver for PostgreSQL).
  • Enter the connection URL, typically something like jdbc:postgresql://localhost:5432/database_name.
  • Provide the username and password.
  • Test the connection with the «Test» button; if successful, save the alias.

After saving, the alias will appear in the left panel; expanding it will show tables, views, stored procedures, and other objects that your user has permission to see.

Notable Features

SQuirreL SQL includes several functionalities that make it useful for both developers and administrators:

  • Object Browser: navigable tree showing schemas, tables, columns, indexes, and triggers.
  • SQL Editor: with syntax highlighting, autocomplete, and query history.
  • Result Viewer: displays data in a table format, allows sorting, filtering, and exporting to CSV, Excel, or XML.
  • DDL Generator: lets you create table creation scripts from existing objects.
  • Plugins: an active community contributes extensions for NoSQL database support, version‑control system integration, and more.

As a Java application, you can adjust its appearance using Look and Feel themes such as Nimbus or the GTK theme of your desktop environment.

Tips and Best Practices

  • Use a distinct alias for each environment (development, test, production) and protect configuration files with restrictive permissions (chmod 600).
  • Increase the JVM memory allocation if you work with very large databases; edit the squirrel-sql.sh file and add -Xmx1024m or more as needed.
  • Schedule maintenance tasks by running queries via the command line with squirrel-sql -cmd if you need automation.
  • Keep your database’s JDBC driver up to date; it is usually available from the vendor’s site and improves compatibility and performance.
  • Take advantage of the ability to create favorites in the SQL editor to reuse frequently used code snippets.

Common Problem Troubleshooting

  • «JDBC driver not found»: verify that the driver JAR is added in the «Drivers» tab of the alias wizard and that the mentioned class matches the driver name.
  • «Application closes on startup»: ensure you have a compatible Java version (Java 11 or higher) and that the JAVA_HOME environment variable is set correctly.
  • «Special characters appear as strange symbols»: make sure the connection encoding is set to UTF‑8 in the alias properties tab.
  • «Performance is slow when loading large schemas»: disable automatic loading of unnecessary objects in preferences and use schema filters to limit exposure.

Conclusion

SQuirreL SQL establishes itself as a robust and flexible option for working with databases on Linux. Its cross‑platform nature, wide range of JDBC drivers, and active plugin community make it suitable for both novice users and experienced professionals. By following the installation and configuration steps described, you can integrate this tool into your daily workflow and fully leverage its capabilities to query, manage, and visualize your data efficiently.

This post is also available in ESPAÑOL.

Leave a Reply

Your email address will not be published. Required fields are marked *

Esta obra está bajo una Licencia Creative Commons Atribución 4.0 Internacional para Francesc Roig francesc@vivaldi.net .