This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function my_explode($delimiter, $string, $limit = null) { | |
$array = call_user_func_array('explode', func_get_args()); | |
if (count($array) === 1 && strlen($array[0]) === 0) { | |
return array(); | |
} | |
return $array; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WITH table_opts AS ( | |
SELECT | |
pg_class.oid, relname, nspname, array_to_string(reloptions, '') AS relopts | |
FROM | |
pg_class INNER JOIN pg_namespace ns ON relnamespace = ns.oid | |
), storage_settings AS ( | |
SELECT | |
oid, relname, nspname, | |
CASE | |
WHEN relopts LIKE '%autovacuum_vacuum_threshold%' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
schema | table | rowcount | dead_rowcount | autovacuum_threshold | expect_autovacuum | relfrozenxid_age | autovacuum_freeze_table_age | next_autovacuum_will_be_a_freeze | autovacuum_freeze_max_age | % til forced vacuum freeze | |
---------+---------+----------------+----------------+----------------------+-------------------+------------------+-----------------------------+----------------------------------+---------------------------+---------------------------- | |
public | table01 | 1,336,112,512 | 4,641,856 | 267,222,552 | | 165311956 | 1.5e+08 | yes | 2e+08 | 82.7% | |
public | table02 | 777,657,088 | 20,662,775 | 155,531,468 | | 165311956 | 1.5e+08 | yes | 2e+08 | 82.7% | |
public | table03 | 642,018,368 | 9 | 128,403,724 | | 165311956 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mydb=> SELECT name, current_setting(name), source | |
mydb-> FROM pg_settings | |
mydb-> WHERE source NOT IN ('default', 'override'); | |
name | current_setting | source | |
---------------------------------+------------------+-------------------- | |
application_name | psql | client | |
archive_command | exit 0 | configuration file | |
archive_mode | on | configuration file | |
autovacuum | on | configuration file | |
autovacuum_analyze_scale_factor | 0.1 | configuration file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
listen_addresses = '*' | |
port = 5432 | |
max_connections = 300 | |
shared_buffers = 2GB | |
work_mem = 10MB | |
maintenance_work_mem = 256MB | |
max_stack_depth = 8MB | |
wal_buffers = 16MB | |
checkpoint_segments = 32 | |
checkpoint_completion_target = .9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2014/01/03 11:24:26 Packer Version: 0.5.1 eeefde8fc71444fdfc77711dc0e2789fa9b3b7d2 | |
2014/01/03 11:24:26 Packer Target OS/Arch: darwin amd64 | |
2014/01/03 11:24:26 Built with Go Version: go1.2 | |
2014/01/03 11:24:26 Detected home directory from env var: /Users/stevek | |
2014/01/03 11:24:26 Attempting to open config file: /Users/stevek/.packerconfig | |
2014/01/03 11:24:26 File doesn't exist, but doesn't need to. Ignoring. | |
2014/01/03 11:24:26 Packer config: &{PluginMinPort:0 PluginMaxPort:0 Builders:map[amazon-ebs:packer-builder-amazon-ebs digitalocean:packer-builder-digitalocean googlecompute:packer-builder-googlecompute virtualbox-ovf:packer-builder-virtualbox-ovf vmware-iso:packer-builder-vmware-iso amazon-chroot:packer-builder-amazon-chroot amazon-instance:packer-builder-amazon-instance docker:packer-builder-docker openstack:packer-builder-openstack qemu:packer-builder-qemu virtualbox-iso:packer-builder-virtualbox-iso vmware-vmx:packer-builder-vmware-vmx] Commands:map[build:packer-command-build fix:packer-command-fix in |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
freenas# dmesg | less | |
Copyright (c) 1992-2013 The FreeBSD Project. | |
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 | |
The Regents of the University of California. All rights reserved. | |
FreeBSD is a registered trademark of The FreeBSD Foundation. | |
FreeBSD 9.2-RELEASE #0 r+2315ea3: Fri Dec 20 12:48:50 PST 2013 | |
root@build.ixsystems.com:/tank/home/jkh/checkout/freenas/os-base/amd64/tank/home/jkh/checkout/freenas/FreeBSD/src/sys/FREENAS.amd64 amd64 | |
gcc version 4.2.1 20070831 patched [FreeBSD] | |
CPU: Intel(R) Xeon(R) CPU E3-1230 v3 @ 3.30GHz (3292.44-MHz K8-class CPU) | |
Origin = "GenuineIntel" Id = 0x306c3 Family = 0x6 Model = 0x3c Stepping = 3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
freenas# less textdump.tar.last | |
"textdump.tar.last" may be a binary file. See it anyway? | |
ddb.txt^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@0600^@^@^@^@0^@^@^@^@^@^@^@0^@^@^@^@^@^@^@140000^@^@^@^@^@^@12267724774^@ 7114^@ ^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@ustar^@^@^@root^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@wheel^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@ | |
^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
postgres=# SELECT version(); | |
version | |
--------------------------------------------------------------------------------------------------------------- | |
PostgreSQL 9.4.5 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-44), 64-bit | |
(1 row) | |
postgres=# SELECT name, current_setting(name), SOURCE | |
postgres-# FROM pg_settings | |
postgres-# WHERE SOURCE NOT IN ('default', 'override'); | |
name | current_setting | source |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
postgres=# SELECT version(); | |
version | |
--------------------------------------------------------------------------------------------------------------- | |
PostgreSQL 9.4.4 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-44), 64-bit | |
(1 row) | |
postgres=# SELECT name, current_setting(name), SOURCE | |
postgres-# FROM pg_settings | |
postgres-# WHERE SOURCE NOT IN ('default', 'override'); | |
name | current_setting | source |