> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/sammwyy/mikuMikuBeam/llms.txt
> Use this file to discover all available pages before exploring further.

# Troubleshooting

> Common issues and solutions for Miku Miku Beam

## Common Issues

<AccordionGroup>
  <Accordion title="Server crashes on startup with 'concurrently' error">
    This is a Node.js/React issue related to the build process.

    **Solution:**

    1. Ensure you have Node.js v18 or higher installed:
       ```bash theme={null}
       node --version
       ```
    2. Navigate to the web-client directory and reinstall dependencies:
       ```bash theme={null}
       cd web-client
       npm install
       ```
    3. Rebuild the project:
       ```bash theme={null}
       make all
       ```
  </Accordion>

  <Accordion title="Nothing appears at http://localhost:3000">
    The web client needs to be built before the server can serve it.

    **Solution:**

    1. Build the web client:
       ```bash theme={null}
       make webclient
       ```
    2. Ensure the server is running:
       ```bash theme={null}
       ./bin/mmb-server
       ```
    3. If the issue persists, rebuild everything:
       ```bash theme={null}
       make all && make run-server
       ```

    <Note>
      In production mode, both frontend and backend are served on the same port (3000).
    </Note>
  </Accordion>

  <Accordion title="Requests fail with 'Read timeout' errors">
    This typically means you don't have valid proxies configured.

    **Solution:**

    1. Add proxies to `data/proxies.txt` (one per line). Supported formats:
       * `protocol://user:password@host:port` (with authentication)
       * `protocol://host:port`
       * `host:port` (defaults to http)
       * `host` (defaults to port 8080)

    2. Alternatively, run without proxies:
       * **CLI**: Use the `--no-proxy` flag
       * **Server**: Set environment variable `ALLOW_NO_PROXY=true`

    <Warning>
      Running attacks without proxies will expose your real IP address to the target.
    </Warning>
  </Accordion>

  <Accordion title="CLI shows 'No proxies available' error">
    The attack engine requires proxies by default.

    **Solution:**

    **Option 1:** Add proxies to the file

    ```bash theme={null}
    echo "http://proxy1:8080" >> data/proxies.txt
    echo "http://proxy2:8080" >> data/proxies.txt
    ```

    **Option 2:** Run without proxies

    ```bash theme={null}
    ./bin/mmb-cli attack http_flood http://example.com --no-proxy
    ```
  </Accordion>

  <Accordion title="Build fails with 'module not found' errors">
    Dependencies are missing or out of sync.

    **Solution:**

    1. Download Go dependencies:
       ```bash theme={null}
       go mod tidy
       ```
    2. Install Node.js dependencies:
       ```bash theme={null}
       cd web-client
       npm install
       cd ..
       ```
    3. Or use the prepare command:
       ```bash theme={null}
       make prepare
       ```
    4. Rebuild the project:
       ```bash theme={null}
       make all
       ```
  </Accordion>

  <Accordion title="Web client shows errors or doesn't load properly">
    The React frontend wasn't built correctly or is outdated.

    **Solution:**

    1. Clean previous builds:
       ```bash theme={null}
       make clean
       ```
    2. Rebuild everything:
       ```bash theme={null}
       make all
       ```
    3. If issues persist, manually rebuild the web client:
       ```bash theme={null}
       cd web-client
       npm install
       npm run build
       cd ..
       ```
  </Accordion>
</AccordionGroup>

## Build Issues

### Prerequisites Not Met

Ensure you have all required software installed:

<CardGroup cols={3}>
  <Card title="Go" icon="golang">
    Version 1.21 or above

    ```bash theme={null}
    go version
    ```
  </Card>

  <Card title="Node.js" icon="node">
    Version 18 or above

    ```bash theme={null}
    node --version
    ```
  </Card>

  <Card title="npm" icon="npm">
    Comes with Node.js

    ```bash theme={null}
    npm --version
    ```
  </Card>
</CardGroup>

### Missing Data Files

Miku Miku Beam requires certain data files to function:

<Steps>
  <Step title="Create data directory">
    ```bash theme={null}
    mkdir -p data
    ```
  </Step>

  <Step title="Create proxies file">
    ```bash theme={null}
    touch data/proxies.txt
    # Add your proxies (one per line)
    echo "http://proxy1:8080" > data/proxies.txt
    ```
  </Step>

  <Step title="Create user agents file">
    ```bash theme={null}
    touch data/uas.txt
    # Add user agents (one per line)
    echo "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36" > data/uas.txt
    ```
  </Step>
</Steps>

<Note>
  You can also manage proxies and user agents directly through the web interface by clicking the text button to the right of the beam button.
</Note>

## Runtime Issues

### Performance Problems

If attacks are running slowly or not performing as expected:

* **Increase thread count**: Use the `--threads` flag in CLI or adjust in the web interface
  ```bash theme={null}
  ./bin/mmb-cli attack http_flood http://example.com --threads 16
  ```

* **Check proxy quality**: Slow or dead proxies will impact performance. Test your proxies before use.

* **Adjust packet delay**: Lower delays send more packets but use more resources
  ```bash theme={null}
  ./bin/mmb-cli attack http_flood http://example.com --delay 50
  ```

### Connection Issues

<Warning>
  If attacks consistently fail to connect, verify:

  * Target URL is accessible
  * Proxies are working and not blocked
  * Firewall settings allow outbound connections
  * Target isn't using advanced DDoS protection
</Warning>

## Multi-Client Issues

### Simultaneous Attacks Not Working

Each web client maintains its own attack instance. If you're having issues:

1. Clear browser cache and reload
2. Ensure each client has a unique Socket.IO connection
3. Check browser console for connection errors
4. Verify the server supports multiple connections (it does by default)

## Getting Help

If you're still experiencing issues:

1. Check the [FAQ](/faq) for common questions
2. Review the [installation guide](/installation) to ensure proper setup
3. Open an issue on [GitHub](https://github.com/sammwyy/mikumikubeam/issues) with:
   * Your OS and version
   * Go and Node.js versions
   * Complete error messages
   * Steps to reproduce the issue

<Tip>
  Enable verbose mode in CLI to get detailed logs that can help diagnose issues:

  ```bash theme={null}
  ./bin/mmb-cli attack http_flood http://example.com --verbose
  ```
</Tip>
