Skip to content

Instantly share code, notes, and snippets.

View johanburati's full-sized avatar
😄
Alive and Kicking

Johan Burati johanburati

😄
Alive and Kicking
  • Red Hat
  • Tokyo
  • 07:46 (UTC +09:00)
View GitHub Profile
@johanburati
johanburati / gpu.lua
Created March 28, 2018 09:04
gpu.lua
-- Max Jaderberg 4/9/13
-- GPU Effectiveness test
require 'torch'
require 'sys'
require 'nn'
require 'xlua'
cmd = torch.CmdLine()
cmd:text()
@johanburati
johanburati / cpu.lua
Created March 28, 2018 09:05
cpu.lua
-- Max Jaderberg 4/9/13
-- GPU Effectiveness test
require 'torch'
require 'sys'
require 'nn'
require 'xlua'
cmd = torch.CmdLine()
cmd:text()
@johanburati
johanburati / monitrc
Last active September 12, 2018 05:30
monit basic config
set daemon 60
set logfile /var/log/monit.log
set idfile /var/lib/monit/id
set statefile /var/lib/monit/state
set eventqueue
basedir /var/lib/monit/events
slots 100
set httpd port 2812
allow monit:monit read-only
2018/10/11 15:28:28 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: 3284: [Info] encryption settings counter file not found, returning index value 0
2018/10/11 15:28:29 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: 3284: [Info] 500 [('date', 'Thu, 11 Oct 2018 15:28:28 GMT'), ('content-length', '1208'), ('content-type', 'text/html'), ('server', 'Microsoft-IIS/10.0')]
2018/10/11 15:28:29 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: 3284: [Info] result_content is <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
2018/10/11 15:28:29 <html xmlns="http://www.w3.org/1999/xhtml">
2018/10/11 15:28:29 <head>
2018/10/11 15:28:29 <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
2018/10/11 15:28:29 <title>500 - Internal server error.</title>
2018/10/11 15:28:29 <style type="text/css">
2018/10/11 15:28:29 <!--
2018/10/11 15:28:29 body{margin:0;font-size:.7em;font-family:Verdana, Arial, Helvetica, sa
2018/10/11 00:50:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: 9133: [Info] Command /bin/mount /dev/sdc1 /mnt/azure_bek_disk -t vfat failed with return code 32
2018/10/11 00:50:51 stdout:
2018/10/11 00:50:51
2018/10/11 00:50:51 stderr:
2018/10/11 00:50:51 mount: /dev/sdc1 is already mounted or /mnt/azure_bek_disk busy
2018/10/11 00:50:51 /dev/sdc1 is already mounted on /mnt/azure_bek_disk
2018/10/11 00:50:51
--
2018/10/11 00:50:54 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: 9133: [Info] Command /bin/mount /dev/sdc1 /mnt/azure_bek_disk -t vfat failed with return code 32
2018/10/11 00:50:54 stdout:
This file has been truncated, but you can view the full file.
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: Parsing context for sequence number: 0
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: setting file path is/var/lib/waagent/Microsoft.Azure.Security.AzureDiskEncryptionForLinux-0.1.0.999322/config/0.settings
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: Config decoded correctly.
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: Encryption operation: EnableEncryption
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: [StatusReport (0)] op: Install
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: [StatusReport (0)] status: success
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: [StatusReport (0)] code: 0
2018/10/12 22:32:51 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: [StatusReport (0)] msg: Installing pre-requisites
2018/10/12 22:32
#! /bin/bash
#
# Troubleshooting tool for Azure File Shares
#
# Options:
# -u Azure File Path (Ex: storageaccount.file.core.windows.net\sharename )
# -a Name of the storage account
# -s Share name
# -e Azure Environment, usually AzureCloud
#
@johanburati
johanburati / install-systemtap-on-centos-7.sh
Last active January 30, 2019 02:27
Install systemtap on Centos 7
#!/bin/sh
# Install systemtap on Centos 7
sudo yum install systemtap systemtap-runtime -y
sudo yum install kernel-debuginfo kernel-debuginfo-common --enablerepo=base-debuginfo -y
sudo yum install yum-utils -y
sudo debuginfo-install kernel-$(uname -r) -y
sudo yum install kernel-devel-$(uname -r) -y
@johanburati
johanburati / index.html
Created September 27, 2019 09:53
index.html
<!doctype html>
<html>
<head>
<title>Hello World Page</title>
</head>
<body>
<p>Hello <strong>World</strong> !</p>
</body>
</html>
@johanburati
johanburati / disable-hyperthreading.sh
Last active January 30, 2020 11:32
Disable hyperthreading
#!/bin/bash
for cpu in $(cat /sys/devices/system/cpu/cpu*/topology/thread_siblings_list)
do
echo 0 > /sys/devices/system/cpu/cpu${cpu}/online
done