Following on from the previous blog, lets have a play with the PASE environment and install Node.JS
Step 1: PASE from the IBM i Command Line
From your IBM i 5250 session call the PASE program to enter the environment:
CALL QP2TERM
Alternatively, you can initiate a terminal session using Powershell, PuTTY, VSCode Terminal, Git Bash, or any similar PC client.

Step 2: Define the Opensource Installation Directory to PASE using the PATH Environment Variable
Open source packages are installed in /QOpenSys/pkgs/bin on an IBM I.
The /QOpenSys/pkgs/bin
directory on IBM i (formerly known as AS/400) is a crucial part of the open systems file system. Let’s delve into its significance:
- Compatibility with UNIX Standards:
- The QOpenSys file system is designed to be compatible with open system standards based on UNIX, such as POSIX and the X/Open Portability Guide (XPG).
- Similar to the root (
/
) file system, QOpenSys leverages the stream file and directory support provided by the integrated file system. - Key characteristics of QOpenSys include:
- Hierarchical directory structure similar to UNIX systems.
- Optimization for stream file input and output.
- Support for multiple hard links and symbolic links.
- Case-sensitive names.
- Local sockets.
- Thread-safe APIs.
- Support for *FIFO objects (named pipes).
- Journaling of object changes.
- Scanning of objects using integrated file system scan-related exit points.
- Accessing QOpenSys:
- You can access QOpenSys through the integrated file system interface using either the IBM i file server or integrated file system commands, user displays, and APIs.
- Unlike the root (
/
) file system, QOpenSys distinguishes between uppercase and lowercase characters when searching for object names. - Path names in QOpenSys follow a specific form.
- Multiple hard links to the same object are allowed, and symbolic links are fully supported.
- Setting Up the PATH:
- The PATH environment variable helps resolve program names to their absolute paths, similar to library lists.
In summary, /QOpenSys/pkgs/bin
is a critical directory for open source development on IBM i, providing compatibility with UNIX standards and enabling efficient access to essential tools and utilities.
Define the opensource path on IBM i PASE
You need to add the open-source installation directory to your PATH environment variable in PASE.
Add the open-source installation directory like this:
PATH=/QOpenSys/pkgs/bin:$PATH
export PATH

Step 3: What version of Node.js do we have?

To verify that Node.js is installed and running properly type:
node -v

What version do I use – or – I do not see any version!
What version do I use?
You can have multiple versions of Node.js installed.
With a local install like this, you can manually install different Node.js versions side by side and switch between them as needed. Best practice is to always specify the desired Node.js runtime versions explicitly in your project configuration. This ensures consistency and avoids unexpected behavior.
Choose and activate your version like this:
alternatives --config node
You can select your version.
In my case I only have one version installed, so I see this:

I do not see any version!
So, if you see a screen like this:

You don’t have Node.JS installed!