Skip to content

Instantly share code, notes, and snippets.

View pavank's full-sized avatar
:octocat:

Pavan Keerthi pavank

:octocat:
View GitHub Profile
@pavank
pavank / copyInstalledPackages.r
Last active December 28, 2018 16:10 — forked from florianhartig/copyInstalledPackages.r
Script to copy the packages installed on one computer or R version to another. Originally from http://stackoverflow.com/questions/1401904/painless-way-to-install-a-new-version-of-r-on-windows
# run on win computer / r version
setwd("C:/Users/pavan/RLibrary/") # or any other existing temp directory
packages <- installed.packages()[,"Package"]
save(packages, file="Rpackages")
# run on ubuntu computer / r version
setwd("/RLibrary") # or any other existing temp directory
load("Rpackages")
for (p in setdiff(packages, installed.packages()[,"Package"]))
@pavank
pavank / CUDA 8.0 & cuDNN v6.0 Setup
Created January 12, 2018 12:53 — forked from mjdietzx/waya-dl-setup.sh
Install CUDA Toolkit v8.0 and cuDNN v6.0 on Ubuntu 16.04
#!/bin/bash
# install CUDA Toolkit v8.0
# instructions from https://developer.nvidia.com/cuda-downloads (linux -> x86_64 -> Ubuntu -> 16.04 -> deb (network))
CUDA_REPO_PKG="cuda-repo-ubuntu1604_8.0.61-1_amd64.deb"
wget http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/${CUDA_REPO_PKG}
sudo dpkg -i ${CUDA_REPO_PKG}
sudo apt-get update
sudo apt-get -y install cuda
#!/bin/bash
#Install dev tools
echo "Installing linux tools..."
sudo -S apt-get update && DEBIAN_FRONTEND=noninteractive sudo apt-get install -y --no-install-recommends \
apt-transport-https \
ca-certificates \
build-essential \
software-properties-common \
sysfsutils rename unzip\
@pavank
pavank / Powershell TCP Socket Listener
Last active August 29, 2015 14:20
Simple TCP Socket listener for testing
function TCPSocketListener ([string]$IPAddress , [int]$Port ,[int] $MinstoListen)
{
Write-Host ("Starting TCP Socket Listener on $IPAddress..")
try {
$listener = new-object System.Net.Sockets.TcpListener([System.Net.IPAddress]::Parse($IPAddress), $Port)
$listener.start()
@pavank
pavank / Disable IPv6 Adapter
Created April 30, 2015 14:43
Disabling IP6 Adapter in Windows Server
Disable-NetAdapterBinding -InterfaceAlias "Ethernet" -ComponentID "ms_tcpip6"
#Use Enable-NetAdapterBinding again to re enable
@pavank
pavank / WinRM Trusted Hosts
Last active January 27, 2017 13:41
WinRM Trusted Hosts
#List existing Hosts
ls WSMan:\localhost\Client\TrustedHosts
#Add new Host
winrm set winrm/config/client '@{TrustedHosts="HostName"}'
@pavank
pavank / Win 8 Cisco VPN Fix
Last active August 29, 2015 14:00
Windows 8 -Old Cisco VPN Software Error - Fix via Registry Hack
1) Go to path [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\vpnva]
2) There might be some junk characters in the Display name before the word "Cisco....". Delete them
3) the display name should read like "DisplayName"="Cisco AnyConnect VPN Virtual Miniport Adapter for Windows x64"
@pavank
pavank / List Installed Apps on PC
Last active March 5, 2020 18:32
List out Installed Programs on PC
Get-WmiObject Win32_Product | Sort-Object Name | Select Name,version,Vendor |export-csv myprogramlist.csv
@pavank
pavank / Enabling WinRM HTTPS Listener
Last active April 8, 2019 13:28
Enabling WinRM HTTPS Listener
1)Generate SSL Certificate with one of these options
-CA Authority(e.g:Versign)
-Active Directory Certificate Services
-Self Signed(Not to be used in Production)
Code : cd 'C:\Program Files (x86)\Windows Kits\8.0\bin\x64\'
makecert -r -pe -n "CN=3dmxvm-solar.cloudapp.net " -b 01/01/2012 -e 01/01/2022 -eku 1.3.6.1.5.5.7.3.1 -ss my -sr localMachine -sky exchange -sp "Microsoft RSA SChannel Cryptographic Provider" -sy 12
2) Export Certificate in .pfx format to store into Trusted Root Store of Client Machine
3) Enable WinRm Trusted Source IP addresses
@pavank
pavank / Dropbox Network Drive Hack
Last active April 6, 2020 03:48
Dropbox Network Drive Hack
Follow these steps
============
1) Create a folder on local disk Eg: C:\Users\keerthip\Documents\Dropbox
2) Create a Drive Letter Mapping eg:(H:) to the folder path in windows with following command
subst H: C:\Users\keerthip\Documents\Dropbox
3) Install Dropbox desktop software in advanced Mode.
Select the new local drive H: and sync either selective folders or all folder to local drive ( which is original folder path)
4) Wait till content is fully synced from web account
5) Pause Syncing and Exit Dropbox
6) Delete local folder drive mapping with following command