AKZN Notes

Archives for My Lazy and Forgetful Mind

Category: IT Stuff

Fixing Expo + npm ERR_INVALID_URL and Permission Issues on WSL

Fixing Expo + npm ERR_INVALID_URL and Permission Issues on WSL Problem Summary When running Expo inside WSL, npm errors appear such as: ERR_INVALID_URL expo: Permission denied Cause: Windows Node/NPM is being used inside WSL, and Windows-mounted paths block Linux permissions. Fix Instructions 1. Use WSL Terminal Open your Linux shell (Ubuntu app) instead of PowerShell/CMD. […]

Running Qwen Code in a Sidecar Docker Container

Running Qwen Code in a Sidecar Docker Container 1. Why Sidecar? Instead of installing Qwen Code on your host, you can run it in its own container. Keeps API keys out of your project repo. Only shares your project folder via a bind mount. Works across different projects. 2. Dockerfile Create a Dockerfile for Qwen […]

Batch resize image on windows 11 using powershell

This script below work as resize all image with jpg, jpeg, JPG, JPEG extension inside folder and subfolder save the result into ‘web’ folder at same folder as this script make file with ps1 extension Add-Type -AssemblyName System.Drawing $w = 300 $h = 400 $quality = 70 # JPEG quality 0–100 $root = Get-Location $outDir […]

iPerf3 on Windows 11 with Docker

# iPerf3 on Windows 11 with Docker This guide explains how to install Docker Desktop on Windows 11, run iPerf3 for network performance testing, and use a single .bat script for quick local, remote, and dual-direction tests. — ## 1. Install Docker Desktop 1. Download Docker Desktop: – [https://www.docker.com/products/docker-desktop/](https://www.docker.com/products/docker-desktop/) 2. Install it with **WSL 2 […]

How to Remove a Specific Command from PowerShell History in VS Code

How to Remove a Specific Command from PowerShell History in VS Code If you accidentally typed a password or sensitive command in the VS Code terminal using PowerShell, and you want to remove only that specific command from history, follow these steps: 📂 Step-by-Step Instructions Close the VS Code terminal to prevent file locking. Open […]

Upgrade Mysql / MariaDB version 10.1.xx to 10.6.xx on XAMPP Windows

To upgrade MariaDB in XAMPP, follow these steps carefully: 🔄 Replace MariaDB in XAMPP with a New Version ✅ 1. Backup your data Copy: \xampp\mysql\data → \xampp\mysql_backup\data Or export all DBs via phpMyAdmin. ✅ 2. Download MariaDB (ZIP version) Go to: https://downloads.mariadb.org/ Choose version 10.6 or later. Select Windows ZIP Archive, e.g.: mariadb-10.6.16-winx64.zip ✅ 3. […]

How to import big table using mysql command on terminal

Understanding the MySQL Import Command with Custom Parameters When importing large SQL dump files into MySQL, it is often necessary to adjust MySQL’s configuration parameters to handle large queries and improve performance. The following command is an example of importing a database dump while customizing MySQL’s memory settings and disabling foreign key checks: "D:\xampp\mysql\bin\mysql" –max_allowed_packet=512M […]

How to Backup VPS to Home Server using BORG

To back up your VPS to your home server using BorgBackup, follow these steps: 1. Install Borg on Both VPS & Home Server On VPS: sudo apt update && sudo apt install borgbackup -y On Home Server: sudo apt update && sudo apt install borgbackup -y 2. Set Up SSH Access (Passwordless Login) On your […]

laravel Migration Specified key was too long problem

https://stackoverflow.com/questions/42244541/laravel-migration-error-syntax-error-or-access-violation-1071-specified-key-wa check if ‘mysql’ => [ …, …, ‘engine’ => env(‘DB_ENGINE’, ‘InnoDB’), ] or InnoDB ROW_FORMAT=DYNAMIC solve the problem, if still error, try accepted answer about Schema::defaultStringLength(191);

How to Composer Install using different php version

1. Find Composer Installation Path Windows Run the following command to check system paths: php -r "echo getenv('PATH');" Look for a path similar to: C:\ProgramData\ComposerSetup\bin\ Or search for "composer" in the output. linux no need to search phar, we can use which below 2. Run Composer Using a Specific PHP Version Windows Once you find […]