Ghostboard pixel

I Ditched Claude Code and Now Using Open Source Qwen AI for Real Sysadmin Work

An AI assistant in the terminal can help you guide through the process, help you move faster with your tasks. I tested Qwen Code and share my findings with you.
Warp Terminal

Over the past year, I have been experimenting more with AI-powered CLI tools, particularly for day-to-day sysadmin work. The idea is appealing. You describe what you want in plain English and let the tool handle the boring, error-prone parts, including fetching binaries, wiring paths, generating config files, and running sanity checks.

Claude Code does this reasonably well, but in my experience, it quickly becomes limiting. You see, access is gated, and it doesn’t feel like something I can casually drop into a Linux VM or a homelab without getting a paid subscription. Privacy is definitely a concern here.

What I really wanted was a tool I could treat like any other Linux utility. Install it once, use it when it makes sense, and ignore it when it doesn’t.

That’s what led me to Qwen Code. It positions itself as an open source, general-purpose alternative to Claude Code. I chose it because it's a very good model, can be installed locally and is free to use.

🚧
I ran everything on a clean Linux system, Ubuntu 25.10, in my case, inside a virtual machine, and that’s deliberate. When I’m evaluating, I always start in a disposable environment where I can observe its behavior without worrying about collateral damage. This is the same advice I give to anyone trying new automation tools. Treat them like untrusted scripts until they earn your confidence.

Installing Qwen Code on Linux

Qwen Code is distributed as a standard Node.js package. If you’re comfortable with npm, this will feel completely normal.

Before installing Qwen Code itself, make sure Node.js and npm are ready for use. On a fresh system, I usually install them from the distro packages or via nvm, either works fine. Check out the steps for installing Node on Ubuntu, if you need help with it.

Once Node.js and npm are in place, installation is a single command:

npm install -g @qwen-code/qwen-code@latest

This installs the qwen binary globally, making it available system-wide without touching system directories directly. 

If you’ve installed Node.js and npm through apt or the system repository on your Linux system, you might get this filesystem permission error.

The operation was rejected by your operating system. It is likely you do not have the permission to access this file as the current user.
Qwen Code CLI installation error without running as a Sudo User
Qwen Code installation error without running as a sudo user.

To resolve it, you will need to run this command as a sudo user:

sudo npm install -g @qwen-code/qwen-code@latest

After installation, verify that the CLI was correctly installed and is reachable in your $PATH with this command:

qwen --version
Screenshot of installing Qwen Code CLI via npm in a terminal
Installing Qwen Code with sudo npm.

For the first time, when you enter the qwen command, you'll be prompted to authenticate via your Qwen account.

Terminal showing Qwen Code CLI requesting authentication when running qwen for the first time
Authenticating Qwen Code.
🚧
While Qwen can be installed and used locally with a tool like Ollama, I went for the hosted service as my goal was to focus on its usage.

Test 1: Using Qwen for installing Golang with a single prompt

My goal was to perform a fully automated Go installation without manual steps. This was the first real test I ran, because installing Go is a task I have done dozens of times.

You have to look up the correct version, grab the right architecture, extract it into the right directory, fix your PATH, and then verify if everything worked. It’s simple, but easy to get wrong when you’re in a hurry.

I started by giving Qwen Code a very plain-English prompt:

Install the latest stable Golang on this system, set up the PATH correctly, create a small demo program, compile it, and verify it runs.

Qwen Code didn’t immediately run anything. Instead, it analyzed the system and came back with a clear plan. After I reviewed and approved the plan, Qwen Code executed the steps one by one.

Installing Golang on Ubuntu 25.04 server with Qwen CLI
Qwen Code installling Golang on Ubuntu 25.04 server.

It breaks down requirements into six steps. First, it checks if Golang is already installed. That’s an intelligent decision it makes.

I love how it asks for permissions before executing any commands. I could have written these commands myself, but I didn’t have to.

Terminal showing Qwen Code CLI prompting for approval to run a shell command
Qwen Code asking for permissions while trying to run shell command.

On execution of the second step, it didn’t perform an intelligent job. Instead of fixing environment variables, it tried to download the same golang version that I had on my system earlier before. That’s sad! This is where we need to guide these AI tools.

Terminal showing Qwen Code CLI proposal with instruction to press Esc to cancel
Cancelling Qwen Code proposed execution with the escape key.

To cancel the proposed execution at any point, you can press the Esc key.

After this, I provided an instruction to keep the existing Golang installation and just fix env variables. In the next step, it tried to create a sample directory and a sample golang file.

Qwen Code CLI execution proposal screen with Esc to cancel
Qwen Code trying to create a main.go file with sample code.

Here are the additional series of steps it took:

  1. Running go build
Terminal showing Qwen Code CLI prompting for approval to execute go build
Qwen Code asking permissions for running go build
  1. Running binary
Terminal showing Qwen Code CLI prompting for approval to execute binary
Qwen Code asking permissions for running golang binary
  1. The final success message
Terminal output confirming successful Golang installation on Ubuntu Server using Qwen CLI
Successful installation of Golang on Ubuntu Server using Qwen Code.

From a sysadmin’s perspective, this example shows where the tool shines. It didn’t just install a package. It validated the entire toolchain end to end. That combination of intent, execution, and verification is what turns a one-line prompt into something genuinely useful.

Although, you do need to press the Enter key half a dozen times.

Test 2: Installing Caddy and Creating Multiple Local Websites

My goal was to install Caddy server, automate its configuration for three websites, create local DNS entries, and verify the final setup.

Here's the prompt I used:

Install Caddy and create three local websites: blog.demo.com, backend.demo.com, and frontend.demo.com. Configure local DNS entries so they resolve on this machine.

This is an instance where Qwen Code really started to feel useful for day-to-day admin work. Setting up a web server with multiple virtual hosts isn’t hard, but it’s repetitive, and it touches several parts of the system at once: packages, config files, services, and DNS.

These characteristics makes it a good test of whether the tool understands real-world workflows instead of just individual commands.

Terminal showing Qwen Code outlining steps to install Caddy and generate website configuration files
Qwen Code's plan to install Caddy and create website configurations.

Again, Qwen Code didn’t execute anything immediately. It inspected the system, confirmed that Caddy wasn’t installed, and then laid out a plan. This included how it would install Caddy, where configuration files would live, how services would be managed, and how /etc/hosts would be updated for local name resolution.

I don’t know why every time it prefers downloading tar packages from the internet instead of downloading them from the apt repository. I cancelled the execution once again with the Esc key and provided it another prompt to go the apt route.

Terminal showing Qwen Code CLI running an automated Caddy installation command
Qwen trying to do automated installation of caddy

Qwen Code tried twice to use sudo, and gave up on the third attempt to fetch the binary manually.

Qwen CLI requires elevated permissions to run apt installation on Ubuntu
Qwen Code requiring sudo access.

This time, I ran qwen with sudo. A warning for you here, if you have a privacy-oriented setup, review the risk of running sudo with qwen:

sudo qwen

It may require you to log in to Qwen again since the user is different. It’s good at resolving dependencies too. Below are the additional steps it performed. 👇

Here’s the final result and setup Qwen came up with.

Manual verification step using curl to test the configured website
Manual verification via curl.

That’s not bad. But I wanted to navigate frontend.demo.com and see the frontend webpage, which I was unable to. So, I guided Qwen to accomplish that goal.

User instructs Qwen Code to re-evaluate generated commands and configuration steps
Prompting Qwen Code to re-evaluate its outputs.

After going through two rounds of different approaches, it finally came up with something I was expecting.

Terminal showing Qwen CLI automatically running curl to verify the website is working
Qwen Code doing automated verification via curl.

Then after, I tried to verify the result manually via cURL.

Screenshot showing curl results for frontend.demo.com website
Running manual verification with curl.

Tast 3: Running BorgBackup

Backups are one of those things every sysadmin agrees are critical, yet the tooling can be intimidating if you don’t use it every day.

Borg is a powerful, fast, and reliable solution that is also very explicit, and forgetting even a single flag can affect the end result in ways you didn’t intend to. That makes it a perfect candidate for testing whether Qwen Code can translate intent into safe, correct, and usable commands.

I started with a straightforward request:

Create a Borg backup of my ~/Pictures folder. Initialize a repository if needed and run a backup.

This time, it checked whether Borg was installed and whether a repository already existed. This is precisely the kind of situational awareness I prefer. Blindly re-initializing a repo would be disastrous.

Since Borg was present on my test system, Qwen Code proceeded to initialize the repository.

Qwen Code CLI sets up BorgBackup and schedules automated backups on a Linux server
Qwen Code checking for Borg and creating an automated backup.

I’m impressed how it came up with a command to create backups in the future as well.

This highlighted one of Qwen Code’s biggest strengths, it turns complex, high-stakes commands into reviewable, step-by-step operations. You still get all the power of Borg, but with a second set of eyes making sure you don’t end up shooting yourself in the foot.

Screenshot of Qwen CLI doing a successful borg backup of ~/Pictures folder
Qwen Code doing a successful Borg backup.

What Qwen Code gets right

After running Qwen Code through several real tasks, a few of its strengths stood out quickly. The biggest one, in my opinion, is that it reduces cognitive load without reducing control.

I don’t have to remember exact download URLs, obscure flags, or the order of operations for a tool I haven’t touched in ages, but I still see every command before it runs. It’s exactly what I want from an AI assistant in the terminal.

I found myself learning or being reminded of best practices simply by reviewing its proposed steps. For junior admins, this could be genuinely educational. For experienced ones, it’s a fast refresher that saves time.

Limitations and things to watch out for

The first limitation is that it still depends heavily on the quality of your prompt. Vague requests lead to vague plans. When I was precise about paths, scope, and intent, the results were excellent. When I was lazy, the tool had to make assumptions, which meant more reviewing on my end.

Another thing to keep in mind is that Qwen Code doesn’t replace understanding your system. You still need to know what systemctl does, how DNS resolution works, or why a Borg repository should be encrypted.

Qwen Code will explain its choices, but it won’t protect you from approving something you don’t fully understand. In that sense, it behaves like a junior admin who follows instructions well but still needs supervision.

I also wouldn’t use it for fully unattended automation or critical production pipelines. Because it’s designed to pause for confirmation, it’s best suited for interactive workflows, exploratory setup, and one-off tasks.

It’s especially useful in scenarios like setting up a new web server, bootstrapping a backup system, or testing a piece of software I haven’t touched in months. Instead of context-switching to a browser, I stay in the terminal and review a concrete plan.

Finally, like any AI-assisted tool, it’s only as good as its training and context. It generally follows best practices, but you should still review security-sensitive changes carefully especially anything touching networking, authentication, or data storage.

From my experience, Qwen Code is best thought of as a powerful assistant.

Final thoughts: Is Qwen Code a real Claude Code alternative?

After working through these examples, I am comfortable saying that Qwen Code is a genuinely practical alternative to Claude Code, especially for Linux users and sysadmins.

It delivers the core benefit people want from AI in the terminal. It turns intent into correct, reviewable shell commands, without any fees or demanding blind trust. The fact that it’s free lowers the barrier to experimentation even further.

If you already live in the terminal and manage Linux systems, Qwen Code is worth trying. It's not a replacement for your existing tooling, but it's a capable assistant. Sometimes that’s exactly what you want, a tool that helps you move faster, without taking control away from you.

About the author

Become a Better Linux User

With the FOSS Weekly Newsletter, you learn useful Linux tips, discover applications, explore new distros and stay updated with the latest from Linux world

itsfoss happy penguin

Great! You’ve successfully signed up.

Welcome back! You've successfully signed in.

You've successfully subscribed to It's FOSS.

Success! Check your email for magic link to sign-in.

Success! Your billing info has been updated.

Your billing was not updated.