Skip to content

Instantly share code, notes, and snippets.

einkoro / 0. Synology RAID Expansion-Resync
Created January 13, 2024 17:46 — forked from fbartho/0. Synology RAID Expansion-Resync
Walkthrough of what I did to increase performance on my Synology NAS box during an expansion, and afterwards.

Performance on Synology RAIDs

(especially while expanding)

Warning: The exact commands may not match for your particular linux OS / Synology(NAS) device. I had to customize the commands after exploring my particular system's setup.

If you're new to linux, or this is a new piece of hardware / a new synology device, jump down to the section called "Inspecting a setup"


einkoro / antiDebuggerDefeat
Created June 15, 2020 07:13
Work around for the anti debugger junk in the C&C Remastered launcher
#include <windows.h>
#include <stdio.h>
#include <psapi.h>
int main( void )
// find the process ID
HANDLE hProcess = NULL;
einkoro /
Created January 1, 2020 16:59 — forked from sykesm/
Transform dnsmasq leases to ISC lease file format.
use NetAddr::IP;
use POSIX qw(strftime);
my $dnsmasq_leases_path = '/var/run/dnsmasq-dhcp.leases';
my $dhcpd_leases_path = '/var/run/dhcpd.leases';
my $network_names_path = '/opt/vyatta/config/active/service/dhcp-server/shared-network-name';
my %networks_by_subnet;
einkoro / CustomWordPressValetDriver.php
Last active November 11, 2022 11:01
Custom WordPress Valet driver for installs that aren't in the root project directory
class CustomWordPressValetDriver extends WordPressValetDriver
* Custom suffix for site path.
* @var string
const sitePathSuffix = '/www';
einkoro / private.xml
Created July 20, 2015 06:12
Karabiner config for Microsoft Sculpt Ergonomic Desktop's mouse
<?xml version="1.0"?>
einkoro / wp-config.php
Last active December 15, 2021 18:50
Easy WP SSL configuration: HTTPS and HTTP with reverse proxying support
* The base configurations of the WordPress.
* This file has the following configurations: MySQL settings, Table Prefix,
* Secret Keys, WordPress Language, and ABSPATH. You can find more information
* by visiting {@link Editing
* wp-config.php} Codex page. You can get the MySQL settings from your web host.
* This file is used by the wp-config.php creation script during the
einkoro / setcookie.php
Created May 25, 2014 02:23
HHVM vs PHP setcookie tests
ini_set('date.timezone', 'UTC');
setcookie('name', 'value');
setcookie('name', 'value');
setcookie('name', 'space value');
setcookie('name', 'value', 0);
setcookie('name', 'value', $tsp = time() + 5);
setcookie('name', 'value', $tsn = time() - 6);
einkoro / disable_admin_user_notifications.php
Last active January 29, 2020 15:32
Must-use plugin to disable new user and password reset email notifications to administrators.
* Plugin Name: WP Disable Admin User Notifications
* Plugin URI:
* Description: Disables new user and password reset notification emails sent to administrators.
* Author: BitPiston Studios
* Author URI:
* Version: 1.0
* Licence: BSD
einkoro / site.conf
Created May 6, 2014 06:27
Oyster fastcgi with lighttpd
$HTTP["host"] =~ "(^www\.|^)bitpiston\.com" { = ""
server.document-root = "/home/bitpiston/www/"
server.error-handler-404 = "/oyster.fcgi"
alias.url = (
"/styles/" => "/home/bitpiston/oyster/site/styles/",
"/files/" => "/home/bitpiston/oyster/site/files/"
fastcgi.server = ( ".fcgi" =>
( "bitpiston" =>
einkoro / site.conf
Created May 6, 2014 06:25
Oyster fastcgi with nginx
server {
listen 80;
listen [::]:80;
root /home/bitpiston/www;
#access_log /var/log/nginx/;
access_log off;
error_log /var/log/nginx/;