A comprehensive IBM AIX command simulation environment for learning and training purposes. This project provides a realistic AIX command-line experience without requiring actual AIX hardware or systems.
π Authentic AIX Environment: Linux-specific commands are disabled to enforce proper AIX command usage π Comprehensive Command Set: Full simulation of AIX storage, performance, network, and system commands π‘ Learning-Focused: Helpful suggestions when you try Linux commands by mistake π― Realistic Output: Commands produce actual AIX-style output π€ AI-Powered Assistant: Ask questions in natural language and get instant AIX command suggestions (OpenAI integration)
For natural language command suggestions, set up your OpenAI API key:
# Get your API key from: https://platform.openai.com/api-keys
export OPENAI_API_KEY='your-api-key-here'
# Make it permanent by adding to ~/.bashrc
echo 'export OPENAI_API_KEY="your-api-key-here"' >> ~/.bashrc
source ~/.bashrc# Source the simulation to enable AIX commands
source ./aix_simulation.shThat's it! The simulation is now active in your current terminal session.
Your prompt will change to:
[AIX-7.3] user@aix-server:/workspaces/AIX-Lab-Simulation$
This visual indicator shows you're in AIX simulation mode!
Once sourced, you can use AIX commands just like on a real system:
# Check AIX version
oslevel -r
# List physical volumes
lspv
# List logical volumes in rootvg
lsvg -l rootvg
# Check file system usage (use -g not -h!)
df -g
# Monitor system performance (use topas not top!)
topasIf you have configured the OpenAI API key, you can ask questions in plain English:
Option A: Interactive Mode (Recommended)
# Enter interactive natural language interface
aixa
# Now just type naturally without 'ask' prefix:
Query> show disk space
Query> check memory
Query> list all disks
Query> quit # to exitOption B: One-Time Questions
# Use 'ask' command for single questions
ask how do I check disk space?
ask show me all running processes
ask what command lists physical volumes?
ask how to monitor system performance?
ask what's the difference between lspv and lsvg?
# Get help about the AI assistant
aixhelpThe AI will understand your question and suggest the appropriate AIX command with explanations!
Note: Once sourced, Linux commands like top, fdisk, systemctl will be disabled and suggest AIX alternatives.
To exit and return to normal Linux environment:
Option 1 (Recommended): Type exit_aix to restore your original prompt
exit_aixOption 2: Close the terminal and open a new one
Option 3: Exit the current terminal session:
exitThe exit_aix command will cleanly exit the simulation and restore your original prompt without closing the terminal.
The integrated OpenAI-powered assistant helps you learn AIX commands naturally:
- Natural Language Understanding: Ask questions in plain English
- Smart Suggestions: Get the right AIX command for your task
- Contextual Help: Receive explanations and usage examples
- Learning Tool: Understand why a command is used, not just what it is
The interactive mode provides a conversational interface where you can ask questions naturally without typing ask each time:
$ aixa
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
AIX Natural Language Interface
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Enter your queries in natural language.
π Special Commands:
β’ 'explain <command>' - Get detailed info about a command
β’ 'history' - View command history
β’ 'clear' - Clear the screen
β’ 'quit' or 'exit' - Stop the interface
π‘ Try queries like: 'show disk space', 'check memory', 'list disks'
β¨οΈ Use ββ arrow keys to navigate command history
Query> show disk space
π Educational Info:
Report file system disk space usage in gigabytes
π‘ Tip: Use df -g for GB, df -k for KB, df -m for MB
Command: df -g
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Filesystem GB blocks Free %Used Iused %Iused Mounted on
/dev/hd4 0.25 0.19 25% 567 11% /
...
Query> [Press β to recall previous command]
Query> quitHistory Features:
- β¨οΈ Use β (up arrow) to recall previous commands
- β¨οΈ Use β (down arrow) to navigate forward through history
- π History persists within the same
aixasession - π Easily reuse and modify previous queries
For quick questions without entering interactive mode:
ask how do I check available disk space?
# Returns: df -g with explanation
ask show me memory usage
# Returns: svmon -G with usage details
ask list all network interfaces
# Returns: ifconfig -a with examples
ask how to monitor CPU performance?
# Returns: topas or nmon with comparison- OpenAI API key (get from https://platform.openai.com/api-keys)
curlandjqinstalled (usually pre-installed on most systems)- Internet connection for API calls
aixa- Enter interactive natural language mode (continuous conversation)ask <question>- Ask a single question and get command suggestionaixhelp- Show AI assistant help and status
This simulation blocks common Linux commands to help you learn proper AIX syntax:
| β Linux Command | β AIX Equivalent | Purpose |
|---|---|---|
top |
topas |
Performance monitoring |
htop |
topas or nmon |
Advanced performance |
free -h |
svmon -G |
Memory usage |
lsblk |
lspv |
List disks |
fdisk -l |
lspv |
List physical volumes |
df -h |
df -g |
Disk space (in GB) |
systemctl |
lssrc, startsrc, stopsrc |
Service management |
ip addr |
ifconfig -a |
Network interfaces |
lvextend |
extendlv or chfs |
Extend logical volume |
yum install |
installp -a |
Package installation |
When you try a Linux command, you'll see a helpful message like:
β οΈ AIX: Command 'top' not found.
π‘ Try the AIX equivalent: topas
oslevel- AIX operating system leveluname- System informationprtconf- System configurationbootinfo- Boot and hardware infogetconf- System configuration variables
lspv- List physical volumeslsvg- List volume groupslslv- List logical volumeslsfs- List file systemsdf- File system usage (supports -k, -m, -g, -i, -t flags)
lscfg- List system configurationlsdev- List deviceslsattr- List device attributes
ps- Process statusw- Show logged in userswho- Show who is logged intopas- Performance monitornmon- System performance monitorvmstat- Virtual memory statisticsiostat- I/O statisticssar- System activity reporter
ifconfig- Network interface configurationnetstat- Network statisticsentstat- Ethernet statisticsping- Network connectivity test
lssrc- List system resource controllerstartsrc- Start system servicesstopsrc- Stop system services
errpt- Error report (supports -a, -s, -j, -d flags)
This simulation comes with a comprehensive cheatsheet (aix_cheatsheet.txt) that includes:
- Command comparisons between Linux and AIX
- Advanced AIX-specific features
- Key concepts and terminology
- Practice scenarios
- Real-world examples
- Best practices
- Troubleshooting guides
- SMIT (System Management Interface Tool) reference
# View all physical volumes
lspv
# Get detailed info about a specific PV
lspv hdisk0
# List all volume groups
lsvg
# Show logical volumes in rootvg
lsvg -l rootvg
# Check file system space in GB
df -g# Start topas with 5-second intervals
topas -i 5
# Get memory information
bootinfo -r
# Check virtual memory stats
vmstat 2 5
# Monitor I/O performance
iostat 2# Show network interfaces
ifconfig -a
# Display routing table
netstat -rn
# Check network connections
netstat -an
# Test connectivity
ping 8.8.8.8# List all services
lssrc -a
# List TCP/IP services
lssrc -g tcpip
# Start a service
startsrc -s sshd
# Stop a service
stopsrc -s sshd- This is a simulation: Commands produce realistic AIX output but don't perform actual system operations
- Learning Tool: Perfect for AIX training, certification prep, and command familiarity
- Safe Environment: No risk of damaging real systems while learning
- Realistic Output: Based on real AIX systems to provide authentic learning experience
- Start with basics:
oslevel,uname,prtconf - Learn storage:
lspv,lsvg,lslv,df - Monitor performance:
topas,nmon,vmstat - Manage services:
lssrc,startsrc,stopsrc - Network diagnostics:
netstat,ifconfig,ping - Error analysis:
errpt
If you encounter issues:
- Ensure the script is executable:
chmod +x aix_simulation.sh - Source the script properly:
source ./aix_simulation.sh - Check that you're in the correct directory
- Refer to the cheatsheet for command syntax
aix_simulation.sh- Main simulation script with all AIX commandsaix_cheatsheet.txt- Comprehensive reference guideREADME.md- This documentation
Feel free to enhance the simulation by:
- Adding more AIX commands
- Improving command output realism
- Adding new scenarios
- Fixing bugs or improving documentation
Happy Learning! π
This simulation helps bridge the gap between Linux knowledge and AIX administration, making it easier to learn IBM's powerful Unix variant.