Catalog / MobaXterm Cheatsheet

MobaXterm Cheatsheet

A comprehensive cheat sheet for MobaXterm, covering essential features, shortcuts, and configurations to enhance your remote computing experience.

Getting Started

Basic Interface

Sessions Tab: Manage and launch different types of sessions (SSH, Telnet, RDP, etc.).

Tools Menu: Access various network tools like port scanners, network packet capture and text editors.

Sidebar (Left Panel): Quick access to saved sessions, files, and MobaXterm tools.

Terminal Window: The main area for interacting with remote servers or local commands.

Creating Sessions

SSH Session

Go to Session -> New session -> SSH. Enter the remote host, username, and port (if not default 22). You can also specify a password or private key.

RDP Session

Go to Session -> New session -> RDP. Enter the remote host IP address. You can configure username, password, and other display settings.

Telnet Session

Go to Session -> New session -> Telnet. Enter the remote host IP address and port.

Serial Session

Go to Session -> New session -> Serial. Configure serial port settings like baud rate, data bits, parity, and stop bits.

MobaXterm Home Directory

MobaXterm provides a local home directory accessible through the /home/mobaxterm path within the terminal. This directory persists across sessions and can be used for storing configuration files, scripts, and other data.

To access files from your Windows environment, you can navigate to the MobaXterm personal settings folder (usually in Documents\MobaXterm).

Key Features and Customization

X11 Server

MobaXterm includes an embedded X11 server, enabling you to run graphical applications from remote Linux/Unix systems directly within Windows.

Ensure the X11-forwarding is enabled in your SSH session settings to use this feature. You might also need to install X11 client packages on the remote server (e.g., xauth, xclock).

Example: ssh -X user@remote_host (The -X flag enables X11 forwarding.)

Multi-Execution

MobaXterm allows you to send the same command to multiple SSH sessions simultaneously. Right-click on the session tabs you want to group, select ‘Multi execution’, and then type your command.

This is useful for performing the same task across multiple servers, such as updating configuration files or running scripts.

Plugins

Extend MobaXterm’s functionality by installing plugins. Plugins can provide support for additional protocols, tools, or customization options.

To manage plugins, go to Plugins -> Manage plugins. You can download and install plugins directly from within MobaXterm.

Some popular plugins include enhanced syntax highlighting, additional terminal themes, and support for specific development tools.

Customization

Terminal Appearance

Change the terminal font, colors, and background in Settings -> Terminal. Choose from predefined themes or create your own.

Keyboard Shortcuts

Customize keyboard shortcuts in Settings -> Keyboard. Assign custom actions to different key combinations.

Sessions Settings

Configure session-specific settings like automatic login, macros, and environment variables in the session properties.

Advanced Features

Port Forwarding

MobaXterm allows you to create SSH tunnels for port forwarding, enabling you to securely access services running on remote servers.

To configure port forwarding, go to Tools -> MobaSSHTunnel. Add a new tunnel and specify the local port, remote host, remote port, and SSH server.

Example use case: Accessing a database server running on a remote machine from your local machine.

Macros

Automate repetitive tasks by creating macros. A macro is a sequence of commands that can be executed with a single keystroke or command.

To create a macro, go to Tools -> MobaMacro. Record your sequence of commands, assign a trigger (e.g., a keyboard shortcut), and save the macro.

Example: Automating the process of connecting to a server, navigating to a specific directory, and running a script.

File Transfer

SFTP Browser

MobaXterm provides an integrated SFTP browser in the left sidebar for easy file transfer between your local machine and the remote server. Simply drag and drop files or use the context menu options.

Command-Line Tools

You can also use command-line tools like scp or sftp within the terminal to transfer files. Ensure these tools are available on both the local and remote systems.

Password Management

MobaXterm allows you to save passwords for your sessions, avoiding the need to enter them manually each time. However, it’s crucial to use a strong master password to protect your saved credentials.

You can manage saved passwords in Settings -> Password management. Consider using a password manager for enhanced security.

Troubleshooting and Tips

Connection Issues

If you’re experiencing connection issues, check the following:

  • Verify the remote host IP address or hostname is correct.
  • Ensure the remote server is reachable and running the appropriate service (e.g., SSH).
  • Check your firewall settings to ensure that the necessary ports (e.g., 22 for SSH) are open.
  • Review your MobaXterm session settings for any incorrect configurations.

X11 Forwarding Problems

If X11 forwarding is not working, try these steps:

  • Ensure that X11-forwarding is enabled in your SSH session settings.
  • Verify that the xauth package is installed on the remote server.
  • Try using the -Y flag instead of -X for trusted X11 forwarding (use with caution).
  • Check the $DISPLAY environment variable on the remote server.

Tips and Tricks

  • Use the Ctrl+Shift+C and Ctrl+Shift+V shortcuts for copying and pasting in the terminal.
  • Customize your MobaXterm environment with themes and plugins to enhance your workflow.
  • Explore the various tools available in the Tools menu, such as the port scanner and network packet capture.
  • Use the integrated SFTP browser for easy file transfer between your local machine and remote servers.
  • Consider using saved sessions for frequently accessed servers.