Skip to content

Instantly share code, notes, and snippets.

View ozanerturk's full-sized avatar
😝
09:00-18:00 at work GMT +3

Ozan ERTÜRK ozanerturk

😝
09:00-18:00 at work GMT +3
  • sensemore.io
  • istanbul
View GitHub Profile
@ozanerturk
ozanerturk / gist:721dd6b60fd33d0704044e09c2a7c647
Created June 11, 2025 14:06
Wordpress Stuck/hang/inresponsive/504/timeout/CPU
If you're seeing 100% CPU usage and `504 Gateway Timeout` errors from NGINX, but you've disabled plugins and the issue persists, you're likely dealing with a **lower-level issue** in WordPress or the server environment. Here's how to **debug this methodically and critically**:
---
## 🔍 1. **Check What Is Actually Using CPU**
Run the following command on the server to identify what's consuming CPU:
```bash
top -o %CPU
@ozanerturk
ozanerturk / merge.sh
Created March 5, 2025 14:49
ESP binary merger script for production releases
chip=esp32
outfolder=production
mkdir -p $outfolder
rm -rf $outfolder/*
# get application bin name
application_bin_name=$(grep "project(" CMakeLists.txt | cut -d "(" -f2 | cut -d ")" -f1)
echo "application bin name: $application_bin_name"
@ozanerturk
ozanerturk / signalGeneration.py
Last active August 10, 2020 19:24
Python simple signal generator
import numpy as np
samplingFrequency = 3000
referenceFrequency = 166
time = 2
harmonic_coefficients = [
#harmoic, amplitude
(0.5, 0.6),
(1, 1),