Skip to content

Instantly share code, notes, and snippets.

#! /bin/bash
# lsof-tree: list open files in a given directory tree (default /home)
NAME=9 # set to 10 for CentOS
BASE="${1:-/home}"
lsof | awk -v NAME=$NAME '{print $NAME}' | grep "^$BASE" | sort -u
<VirtualHost {host}:80>
ServerName {host}
Redirect permanent / https://{host}
LogLevel warn
ErrorLog /var/log/apache2/misp.local_error.log
CustomLog /var/log/apache2/misp.local_access.log combined
ServerSignature Off
</VirtualHost>
<VirtualHost {host}:443>
@IanGabes
IanGabes / zookeeper.log
Last active October 18, 2017 13:17
zookeeper.log
This file has been truncated, but you can view the full file.
2017-09-28 17:28:22,120 [myid:] - INFO [main:QuorumPeerConfig@116] - Reading configuration from: /elastic_cloud_apps/zookeeper/bin/../conf/zoo.cfg
2017-09-28 17:28:22,129 [myid:] - INFO [main:QuorumPeerConfig@318] - clientPortAddress is 0.0.0.0/0.0.0.0:2191
2017-09-28 17:28:22,130 [myid:] - INFO [main:QuorumPeerConfig@322] - secureClientPort is not set
2017-09-28 17:28:22,137 [myid:] - WARN [main:QuorumPeerConfig@581] - No server failure will be tolerated. You need at least 3 servers.
2017-09-28 17:28:22,142 [myid:10] - INFO [main:DatadirCleanupManager@78] - autopurge.snapRetainCount set to 3
2017-09-28 17:28:22,143 [myid:10] - INFO [main:DatadirCleanupManager@79] - autopurge.purgeInterval set to 1
2017-09-28 17:28:22,144 [myid:10] - INFO [PurgeTask:DatadirCleanupManager$PurgeTask@138] - Purge task started.
2017-09-28 17:28:22,145 [myid:10] - INFO [main:ManagedUtil@46] - Log4j found with jmx enabled.
2017-09-28 17:28:22,155 [myid:10] - INFO [PurgeTask:DatadirCleanupManager$PurgeTask@144] - Purge task
@IanGabes
IanGabes / client-forwarder.log
Last active October 18, 2017 13:18
client-forwarder.log
[2017-09-28 17:28:23,482][INFO ][org.apache.curator.framework.imps.CuratorFrameworkImpl] Starting {}
[2017-09-28 17:28:23,507][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:zookeeper.version=3.5.1-alpha-1693007, built on 07/28/2015 07:19 GMT {}
[2017-09-28 17:28:23,507][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:host.name=ecs01-gw {}
[2017-09-28 17:28:23,507][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:java.version=1.8.0_121 {}
[2017-09-28 17:28:23,508][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:java.vendor=Oracle Corporation {}
[2017-09-28 17:28:23,508][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:java.home=/usr/lib/jvm/java-1.8-openjdk/jre {}
[2017-09-28 17:28:23,508][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:java.class.path=/elastic_cloud_apps/services.jar:. {}
[2017-09-28 17:28:23,508][INFO ][org.apache.zookeeper.ZooKeeper] Client environment:java.library.path=/usr/lib/jvm/java-1.8-openjdk/jre/lib/amd64/server:/usr/lib/jv
[2017-10-17 13:40:01,734][INFO ][org.apache.zookeeper.ZooKeeperTestable] injectSessionExpiration() called {}
[2017-10-17 13:40:01,734][WARN ][org.apache.curator.framework.state.ConnectionStateManager] Session timeout has elapsed while SUSPENDED. Injecting a session expiration. Elapsed ms: 345348710. Adjusted session timeout ms: 15000 {}
[2017-10-17 13:40:01,737][INFO ][no.found.curator.ForwardedEnsembleProvider] Resolved connection string from [http://containerhost:2180/zookeeper/clients/ensemble/connection-string?namespace=/v1] to [containerhost:22191/v1] with local namespace [/v1] {}
[2017-10-17 13:40:01,737][INFO ][org.apache.zookeeper.ZooKeeperTestable] injectSessionExpiration() called {}
[2017-10-17 13:40:01,738][WARN ][org.apache.curator.framework.state.ConnectionStateManager] Session timeout has elapsed while SUSPENDED. Injecting a session expiration. Elapsed ms: 345348714. Adjusted session timeout ms: 15000 {}
[2017-10-17 13:40:01,739][INFO ][no.found.curator.ForwardedEnsembleProvider] Resolved connec
@IanGabes
IanGabes / ECE DIAG
Last active October 16, 2017 16:19
### INFRASTRUCTURE AND ALLOCATORS ###
[
{
"zone_id": "ece-region-1a",
"allocators": [
{
"public_hostname": "192.168.57.90",
"instances": [
{
#!/bin/bash
#UBUNTU <= 16.04 only
#Better alt-tab
sudo apt-get install compiz-plugins
sudo apt-get install compizconfig-settings-manager
#Disable the keyboard shortcuts for Unity's switcher by unchecking
#CompizConfig Settings Manager ▸ Desktop ▸ Ubuntu Unity Plugin ▸ Switcher ▸ Key to start the switcher ▸ Enabled and Key to start the switcher in reverse ▸ Enabled
#Enable the Static Application Switcher by checking CompizConfig Settings Manager ▸ Window Management ▸ Static Application Switcher ▸ Enable Static Application Switcher