Installing Informix Client SDK on Raspberry pi - python

I wanted my raspberry pi to connect to an Informix database thru Python.
I tried installing the InformixDB module for python but I get an error as
NameError: name 'arch_' is not defined
But this is caused because I didn't have an Informix Client SDK installed on the pi which does the underlying work of connecting to the DB and the module is just a wrapper. I searched the IBM downloads but couldn't find the package for ARM architecture.
I've also tried the following links but to no good.
https://code.google.com/p/ibm-db/
https://code.google.com/p/ibm-db/wiki/README
Could someone help me with this ?

Try downloading the Informix Developer Edition for Raspberry Pi. It contains the engine and the client.
Regards.

Related

Raspberry Pi unable to connect to Windows Websocket

I am attempting to send data from a Python script running on a Raspberry Pi to a Java Micronaut ServerWebSocket running on a Windows machine, but I am getting asyncio.exceptions.TimeoutError errors during the process.
I attempted to use the websockets library in Python on the Raspberry Pi to establish a websocket connection, but encountered a ConnectionRefusedError. Is this issue related to a network problem as mentioned here, and should I ask somewhere else like Superuser or Serverfault? Or is there another solution to this problem?
As #life888888 suggested, it had something to do with Windows firewall.
But instead of the public firewall being the problem, it was the one for the domain network instead.

Cx Oracle 'TNS could not resolve the connect identifier'

I am connecting to an Oracle DB using LDAP and the Python cx_Oracle library. I have proper sqlnet.ora, ldap.ora and tnsnames.ora files. On my Windows machine everything works fine using the 12.1 Oracle client and the following Python code:
import cx_Oracle
connection = cx_Oracle.connect(user/password#db, mode=cx_Oracle.SYSDBA)
I have installed the Oracle instant client 12.1 on my Linux machine (Debian) following the zip file installation method advised on the Oracle website (at the bottom of https://www.oracle.com/be/database/technologies/instant-client/linux-x86-64-downloads.html).
ldconfig correctly lists the oracle client libraries and their paths.
I copy the exact same sqlnet.ora, ldap.ora and tnsnames.ora files from my Windows machine to my Linux machine
in /opt/oracle/instantclient_12_1/network/admin, as advised by the cx_Oracle documentation.
Now running the above Python code on my Linux machine I have the following error:
cx_Oracle.DatabaseError: ORA-12154: TNS:could not resolve the connect identifier specified
I tried as well setting the environment variable TNS_ADMIN=/opt/oracle/instantclient_12_1/network/admin and ORACLE_HOME=/opt/oracle/instantclient_12_1/ with no success neither
Could any of you help me debugging this and understand why the client config on my Linux machine does not work?
Installed the latest 19 client and everything works as expected.

mqtt on esp8266 with micropython

I have a modem and four Esp8266 and a Raspberry Pi. I want to control Esp with Python language via internet. I have read this project.
https://randomnerdtutorials.com/micropython-mqtt-esp32-esp8266/
Instead of ESP2, I implemented the code on Windows. But I got the error ModuleNotFoundError: No module named 'ustruct'.
Is there a way for me to remotely check the Raspberry Pi and ESPs using Windows?
Of course I want to use MQTT.
This photo shows what I have described.
ustruct is a MicroPython Module that is available on all if not most MicroPython firmwares ( including the Win32 version of MicroPython)
If you need to / want to port your code to Cpython (on windows or other) that should not be too much work as the two are quite compatible.
as your project needs network capabilities using the Windows port of MicroPython is not an option as neither the Unix nor the Widows ports come with a network stack you compile/download a windows port of MicroPython

PythonAnywhere cx_Oracle DPI-1047: Cannot locate a 64-bit Oracle Client library: "libclntsh.so:

I am attempting to connect to an external Oracle database using cx_Oracle on PythonAnywhere.com.
I have followed the instructions available on Oracle's website, GitHub, StackOverflow and the python anywhere forum but struggle to resolve the issue cx_Oracle.DatabaseError: DPI-1047: Cannot locate a 64-bit Oracle Client library: "libclntsh.so: cannot open shared object file: No such file or directory".
The main instructions I followed were https://www.oracle.com/au/database/technologies/instant-client/linux-x86-64-downloads.html but it is unclear how I complete this task as a Python Anywhere user.
I have uploaded and unzipped the instant client files and tried every which way to get $LD_LIBRARY_PATH to do something but, to be honest, it isn't fully making sense.
Any help would be greatly appreciated.

Firebird x32-x64 bits

I have developed a Python executable programm (with PyInstaller).
This executable use Firebird.
My computer is 64bits, so as my Python and my libraires then.
My executable works perfectly with Firebird 64bits.
The issue is that I want my executable to work on other computers that have only Firebird 32bits installed.
For now, when I try on an other computers the log tells me that (Sorry I have only the picture because my client only send me this and not the 'text' error) :
Is there a way to make it work with Firebird x32 ?
Thanks
You application need client libraries of Firebird.
[Application] <--> [Firebird client libraries] <==> (local or remote connection) <==> [Firebird client libraries] <-> [Firebird server]
If your application is Win64, then it needs Win64 client libraries of Firebird to make connection to ANY Firebird server.
So you need to distribute and install client libraries of Firebird matching your application architecture together with your app. Or you may require users to download and install client part of Firebird with the required architecture, before installing your app.
See also:
connecting to firebird server from client
https://firebirdsql.org/manual/qsg10-client-only-install.html
https://firebirdsql.org/file/documentation/reference_manuals/driver_manuals/odbc/html/fbodbc205-download-fbclient.html
https://firebirdsql.org/file/documentation/reference_manuals/user_manuals/html/qsg3-installing.html
If your app is 32bit than you need 32bit fb client dll/so to load, even on 64bit platform. You can connect on any compatible fbserver(regardless 64 or 32bit). So fb client lib(dll) issues are those you need to resolve. If you use fb as embedded library you need only one dll, and it must be compatible with your app binary interface and on 32bit system you need 32bit fbclient.dll to load. I hope this helps.

Categories

Resources