Skip to content

Instantly share code, notes, and snippets.

Grant Firefishy

Block or report user

Report or block Firefishy

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@Firefishy
Firefishy / docker-compose.yml
Created Oct 21, 2019
PostgreSQL docker-compose managing a data volume
View docker-compose.yml
version: '3'
services:
db:
image: postgres:9
volumes:
- db-data:/var/lib/postgresql/data
volumes:
db-data:
@Firefishy
Firefishy / gist:928cfb2d4a4bd9d4dcbeb9e6aa5fd8a0
Created Jan 3, 2019
% OpenStreetMap Tile Bandwidth Traffic increase over last ~ 6 months
View gist:928cfb2d4a4bd9d4dcbeb9e6aa5fd8a0
SN: 603.983%
TR: 480.698%
MY: 395.515%
SA: 229.806%
UY: 217.383%
VN: 177.495%
TH: 176.646%
DZ: 158.348%
PK: 156.190%
IR: 147.665%
View gist:984566107afb95542329bbf46adf60f9
2018-09-22 17:41:38.417 7f776c7c3700 -1 /build/ceph-13.2.1/src/osd/PGLog.h: In function 'static void PGLog::_merge_object_divergent_entries(const PGLog::IndexedLog&, const hobject_t&, mempool::osd_pglog::
list<pg_log_entry_t>&, const pg_info_t&, eversion_t, missing_type&, PGLog::LogEntryHandler*, const DoutPrefixProvider*) [with missing_type = pg_missing_set<true>; mempool::osd_pglog::list<pg_log_entry_t>
= std::__cxx11::list<pg_log_entry_t, mempool::pool_allocator<(mempool::pool_index_t)14, pg_log_entry_t> >]' thread 7f776c7c3700 time 2018-09-22 17:41:38.421384
/build/ceph-13.2.1/src/osd/PGLog.h: 921: FAILED assert(objiter->second->version > last_divergent_update)
ceph version 13.2.1 (5533ecdc0fda920179d7ad84e0aa65a127b20d77) mimic (stable)
1: (ceph::__ceph_assert_fail(char const*, char const*, int, char const*)+0x102) [0x7f778f1554e2]
2: (()+0x2e26a7) [0x7f778f1556a7]
3: (void PGLog::_merge_object_divergent_entries<pg_missing_set<true> >(PGLog::IndexedLog const&, hobject_t const&, std::__cxx11::list<p
View gist:a1bf8806ea60561fb77e02f877dffc4f
-2> 2018-09-22 17:56:11.830 7fe76e603700 5 -- 10.89.121.203:6809/8690 >> 10.89.121.202:6810/3429 conn(0x55fe26068300 :6809 s=STATE_OPEN_MESSAGE_READ_FOOTER_AND_DISPATCH pgs=118 cs=1 l=0). rx osd.10 s
eq 57 0x55fe25e41600 pg_query(1.1b4s5 epoch 41227) v4
-1> 2018-09-22 17:56:11.830 7fe76e603700 1 -- 10.89.121.203:6809/8690 <== osd.10 10.89.121.202:6810/3429 57 ==== pg_query(1.1b4s5 epoch 41227) v4 ==== 162+0+0 (2599670235 0 0) 0x55fe25e41600 con 0x55
fe26068300
0> 2018-09-22 17:56:11.830 7fe7533ca700 -1 /build/ceph-13.2.1/src/osd/PGLog.h: In function 'static void PGLog::_merge_object_divergent_entries(const PGLog::IndexedLog&, const hobject_t&, mempool::osd
_pglog::list<pg_log_entry_t>&, const pg_info_t&, eversion_t, missing_type&, PGLog::LogEntryHandler*, const DoutPrefixProvider*) [with missing_type = pg_missing_set<true>; mempool::osd_pglog::list<pg_log_e
ntry_t> = std::__cxx11::list<pg_log_entry_t, mempool::pool_allocator<(mempool::pool_index_t)14, pg_log_entry_t> >]' thread 7fe7533ca700 tim
View gist:3929df6a63107136492fb9a526fbfecf
-1> 2018-09-22 17:51:49.602 7f74bef84700 1 -- 10.89.121.204:6802/6710 <== osd.23 10.89.121.206:6809/3478 91 ==== pg_info((query:41162 sent:41162 1.91s0( v 5903'139734 (2469'136649,5903'139734] local-lis/les=41161/41162 n=66920 ec=71/51 lis/c 41152/40494 les/c/f 41153/40495/0 41157/41161/41017) 0->3)=([40494,41160] intervals=([40597,40598] acting 0(1),2(3),3(4),16(5),23(0)),([41017,41021] acting 1(2),2(3),3(4),6(1),8(5),23(0)),([41124,41130] acting 0(1),1(2),3(4),16(5),23(0)),([41157,41160] acting 0(1),1(2),2(3),16(5),23(0))) epoch 41162) v5 ==== 1384+0+0 (164758133 0 0) 0x5585a0bdea00 con 0x5585993cf500
0> 2018-09-22 17:51:49.602 7f74a2548700 -1 *** Caught signal (Aborted) **
in thread 7f74a2548700 thread_name:tp_osd_tp
ceph version 13.2.1 (5533ecdc0fda920179d7ad84e0aa65a127b20d77) mimic (stable)
1: (()+0x9169e0) [0x558522b249e0]
2: (()+0x11390) [0x7f74c356f390]
3: (gsignal()+0x38) [0x7f74c2aa2428]
4: (abort()+0x16a) [0x7f74c2aa402a]
5: (ceph::__ceph_assert_fail(char const*, char const*, int
View gist:8cc0ce5462ae052b8bfaa788df26824e
-1> 2018-09-22 17:56:11.862 7fe760e04700 3 osd.5 41227 handle_osd_map epochs [41222,41227], i have 41227, src has [3142,41227]
0> 2018-09-22 17:56:11.874 7fe7533ca700 -1 *** Caught signal (Aborted) **
in thread 7fe7533ca700 thread_name:tp_osd_tp
ceph version 13.2.1 (5533ecdc0fda920179d7ad84e0aa65a127b20d77) mimic (stable)
1: (()+0x9169e0) [0x55fda92789e0]
2: (()+0x11390) [0x7fe772bee390]
3: (gsignal()+0x38) [0x7fe772121428]
4: (abort()+0x16a) [0x7fe77212302a]
5: (ceph::__ceph_assert_fail(char const*, char const*, int, char const*)+0x250) [0x7fe774559630]
@Firefishy
Firefishy / gist:b2bc79e9d4460e020a0631da839dcfa3
Created Mar 29, 2017
Plusnet MTR traceroute ICMP and TCP port 443 to rubygems
View gist:b2bc79e9d4460e020a0631da839dcfa3
grant@redbox:~$ mtr --report -c 60 --no-dns rubygems.org
Start: Wed Mar 29 10:44:31 2017
HOST: redbox Loss% Snt Last Avg Best Wrst StDev
1.|-- 195.166.130.248 0.0% 60 4.7 5.6 4.4 30.4 3.9
2.|-- 84.93.253.71 0.0% 60 5.2 5.2 5.0 5.7 0.0
3.|-- 195.99.125.140 0.0% 60 5.3 5.2 4.8 5.9 0.0
4.|-- 62.172.103.13 0.0% 60 6.6 6.1 5.5 6.7 0.0
5.|-- 166.49.211.238 0.0% 60 5.4 6.6 5.2 28.8 3.6
6.|-- 213.248.82.249 0.0% 60 6.1 6.4 5.7 21.4 2.2
7.|-- 149.11.4.90 0.0% 60 5.6 5.7 5.3 6.1 0.0
@Firefishy
Firefishy / sysctl-tune.conf
Created Mar 23, 2017
Safe sysctl tuning for modern high traffic systems
View sysctl-tune.conf
# Enable Packetization Layer Path MTU Discovery.
net.ipv4.tcp_mtu_probing = 1
net.ipv4.tcp_base_mss = 1024
# Ensure slow start is disabled
# https://github.com/ton31337/tools/wiki/tcp_slow_start_after_idle---tcp_no_metrics_save-performance
net.ipv4.tcp_slow_start_after_idle = 0
net.ipv4.tcp_no_metrics_save = 0
# Tune network buffers - servers have more than 16MB of RAM in 2017
@Firefishy
Firefishy / apache-worker.conf
Created Mar 23, 2017
Recommended apache worker MPM config for high connection systems
View apache-worker.conf
# Set the number of seconds before receives and sends time out
Timeout 300
# Decide whether or not to allow persistent connections
Keepalive On
# Configure worker MPM
StartServers 2
ServerLimit 20
MinSpareThreads 75
MaxSpareThreads 525
ThreadLimit 64
@Firefishy
Firefishy / SACRS.md
Created Sep 7, 2016 — forked from gubuntu/SACRS.md
southern African coordinate reference systems (CRS) definitions in proj4 and WKT
View SACRS.md

Use this file to get the CRS definitions you need in southern Africa, particularly South Africa, Lesotho, Swaziland and Zimbabwe.

Most GIS software now implements the South African CRS (SACRS; incorrectly but popularly known as the "LO" system) which is based on south-oriented (or south-facing) transverse mercator (TMSO). The EPSG codes for these are:

  • odd numbers from 22275 to 22293 for the Cape datum
  • all numbers from 2046 to 2055 for the Hartebeesthoek94 or WGS84 datum.

If you have data in one of these south-oriented CRSs it will draw upside down and back to front in its native CRS but if you have on-the-fly transformation enabled, your layers will overlay your other data perfectly in whatever project CRS you choose. This feature request will result south-oriented coordinates and visualisation being more intutitive to GIS users.

Note on datums: Although there are a few metres difference between the WGS84 and Hartebeethoek94 datums, for all intents and purpos

You can’t perform that action at this time.