Skip to content

Instantly share code, notes, and snippets.

Harshavardhana harshavardhana

Block or report user

Report or block harshavardhana

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
@harshavardhana
harshavardhana / go-os-arch.md
Created Jun 18, 2019 — forked from asukakenji/go-os-arch.md
Go (Golang) GOOS and GOARCH
View go-os-arch.md

Go (Golang) GOOS and GOARCH

All of the following information is based on go version go1.8.3 darwin/amd64.

A list of valid GOOS values

(Bold = supported by go out of the box, ie. without the help of a C compiler, etc.)

  • android
  • darwin
@harshavardhana
harshavardhana / random-servers.go
Last active Dec 26, 2018 — forked from fwessels/random-servers.go
Create a list of random servers
View random-servers.go
package main
import (
"fmt"
"hash/crc32"
)
func randomServers(token string, count int) []int {
hTok := crc32.Checksum([]byte(token), crc32.IEEETable)
val := uint32(hTok)
View nfs-cache-coherence.txt
DATA AND METADATA COHERENCE
Some modern cluster file systems provide perfect cache coherence among their clients. Perfect cache coherence among disparate NFS clients is expensive to achieve, especially on wide area networks. As such, NFS settles for weaker cache coherence that satisfies the requirements of most file sharing types.
Close-to-open cache consistency
Typically file sharing is completely sequential. First client A opens a file, writes something to it, then closes it. Then client B opens the same file, and reads the changes.
When an application opens a file stored on an NFS version 3 server, the NFS client checks that the file exists on the server and is permitted to the opener by sending a GETATTR or ACCESS request. The NFS client sends these requests regardless of the freshness of the file's cached attributes.
When the application closes the file, the NFS client writes back any pending changes to the file so that the next opener can view the changes. This al
View quota.md
"quota": {                                                                                        
            "storage": {                                                                                  
                "capacity": "1TiB",                                                                       
            }                                                                                             
            "network": {                                                                                  
                "iops": 1024,                                                                             
                "bandwidth": "250MiB",                                                                    
            }                                                                                             
            "cpu": {                                                                                      
@harshavardhana
harshavardhana / COPYING
Created May 6, 2018 — forked from davedoesdev/COPYING
Quietening Syslinux
View COPYING
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
@harshavardhana
harshavardhana / minio-gateway-azure.bat
Last active Feb 8, 2018
Minio windows batch examples
View minio-gateway-azure.bat
rem This program starts the minio batch.
@echo off
setlocal
path=C:\programs\minio;%path%
set MINIO_ACCESS_KEY=accountname1
set MINIO_SECRET_KEY=secretForAccountName
call minio gateway azure --address=:9001 >c:\test\c1.out
endlocal
@harshavardhana
harshavardhana / upload-minio.html
Last active Dec 14, 2017
Upload to play.minio.io:9000 from browser using minio-js
View upload-minio.html
<!DOCTYPE html>
<html>
<head>
<title>Minio SDK for JavaScript - Sample Application</title>
@harshavardhana
harshavardhana / upload_upon_close.py
Created Nov 18, 2017
Watch for CLOSE events and upload the file to S3
View upload_upon_close.py
import inotify.adapters
from minio import Minio
from minio.error import ResponseError
minioClient = Minio('play.minio.io:9000',
access_key='Q3AM3UQ867SPQQA43P2F',
secret_key='zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG',
secure=True)
def _main():
View keybase.md

Keybase proof

I hereby claim:

  • I am harshavardhana on github.
  • I am y4m4 (https://keybase.io/y4m4) on keybase.
  • I have a public key ASAufnZvMt56rQ9785OSHLgz8g3ed1v-P_uBfie-iG5FRAo

To claim this, I am signing this object:

You can’t perform that action at this time.