Category : windows

Currently, you have to manually connect to a remote database to extract info via an openvpn connection openvpn-gui.exe to extract the info and disconnect after each extraction job. Connection is authenticated by a config.ovpn file stored locally. Is there a way to automate the (connect > extract data > disconnect) process? Source: Python..

Read more

I have python code that sends self-built udp packets over a raw socket. This works on Linux (Ubuntu) but not on Windows (10). The socket is opened like this: #!/usr/bin/env python3 import argparse import ipaddress import socket import struct import sys if __name__ == "__main__": sender = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_RAW) message = "myMessage" addr = ..

Read more

I am trying to use parallel processing in python using the following code: import os import datetime import numpy as np import FarimaModule from statsmodels.tsa.arima.model import ARIMA import matplotlib.pyplot as plt import multiprocessing as mp # Here I define some variables: p_max,q_max,m_list,wlen,mstep,fs, listFile def implement(fname,p_max,q_max,m_list,wlen,mstep,fs): # It is a really long code # run the ..

Read more

i’ve search to google but I can’t found the correct code for remote my windows on ubuntu. oh ya, by the way this is code which i run in ubuntu: import paramiko ssh = paramiko.SSHClient() ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy()) ssh.connect(hostname=’192.***.**.***’,username=’Advisor’,password=’Jol*************’,port=22) sftp_client=ssh.open_sftp() print(dir(sftp_client)) ssh.close() Source: Python..

Read more