Is there any method to know which enviroment variables is trying to read a linux program? - linux

I'm trying to install a software in Ubuntu 20.04. When running the setup, an error occurs because it's trying to write a log file in root folder.
This error was not present when I installed the same program in Ubuntu 16.04. Even, without running it as root.
I suspect that the installation program is trying to read some enviroment variable that not longer exists in this version, and it's trying to locate the log files in root folder by default.
Is there any method to know which enviroment variables is trying to read a binary file?

Try strace, it will tell you all calls to OS.

Related

How do you properly create a pythonpath for a mavlink environment?

For a project I am currently trying to install Mavlink onto a Linux Ubuntu (v20.04.4) using Oracle Virtualbox (v6.1) using python (v3.8) on a machine named test with the user named test. Using the given instructions provided by Install Mavlink, it states to set pythonpath as PYTHONPATH=path_to_root_of_cloned_mavlink_repository. But no matter what I try ranging from ='/home/test/mavlink/pymavlink' to =home/test/mavlink, there has been no indication that it is properly working as no feedback is given after the command and modules are still not being found by the terminal. So my question is if I am using the right command for my versions of programs or if I am even doing the file path right by linux standards. The file path given after downloading the github mavlink repository is "Cloning into '/home/test/mavlink/pymavlink'..."

Permission denied when trying to run .bin on Linux webserver

I am trying to run a compiled C++ program on my webserver (Debian), but the terminal is outputting the following error message:
-bash: ./program.bin: Permission denied
The rights on program.bin are set to -rwxr-xr-x, which means that it should have the permission to be executed. I already tried running /bin/bash program.bin, but this is giving me this error:
ovInterface.bin: ovInterface.bin: cannot execute binary file
The hosting provider of the webserver probably has forbidden this, since there are a lot of websites/accounts hosted on my webserver. If that's the case, is it possible to bypass this restriction? I was able to run .php files in the background of the webserver, which had an infinite for loop and handled socket connections etc.
Any help would be appreciated!
EDIT:
I found out that the cannot execute binary file error from /bin/bash program.bin means that the compiled program is not built for the system architecture. program.bin was compiled on another machine (however both are 64-bit).
If it is possible to run the .bin file using /bin/bash: How do I compile C++ code to executables without access to gcc, g++, make and apt-get? Can I upload a compiler executable to my webserver and compile the C++ source then?

"No such file or directory" running dynamically linked executable in Ubuntu

I'm trying to install AFDKO on Ubuntu. After installation I added environmental variables also. But when I call the command
$ makeotfexe
It returns
bash: /home/randika/FDK/Tools/linux/makeotfexe: No such file or directory
But when I "cd" in to that folder in above path the file exists and can be accessed and opened. What is issue here? How can I correct it?
Guess you are trying to run a 32bit executable in a 64bit environment. Try installing ia32-libs package.

/etc/lsb-release: No such file or directory

I am running a script written by someone else on Mac OSX. And, I'm getting this error
/etc/lsb-release: No such file or directory
I researched a bit and looks like this tells the program what Linux version it is. Obviously, it's not available on OSX. Any suggestions on what it should be changed to in OSX
EDIT: Here's the script https://github.com/reddit/reddit/blob/master/install-reddit.sh
A stub might look something like...
LSB_VERSION=1.4
DISTRIB_ID=MacOSX
DISTRIB_RELEASE=10.9
DISTRIB_DESCRIPTION="Not Linux"
...but any script that's trying to look for a Linux-only file is likely to have other problems on MacOS as well.
Install Ubuntu 12.04 on a virtual machine if you want that script to work.

Xampp on linux mint

im trying to install xampp on "new" linux mint machine.
However im quite a noob to linux since i havnt used it for that long.
When i try to run the file that ive download from the following page:
Xampp download
i get the following error two errors:
Could not display "/home/marc/Downloads/xampp-linux-x64-1.8.3-0-installer.run".
and if i click yes
Installing mime type handlers isn't supported
To search and install software which can open certain file types you have to install app-install-data.
can anyone tell me what the problem is and how i might fix it?
you need to execute the file (e.g. open a terminal, navigate to your Downloads folder and run bash xampp-linux-x64-1.8.3-0-installer.run (possibly it might need to be run otherwise, but thats my best guess)).
alternatively you might be presented to run/execute the file (instead of displaying it). if so, choose this option.
on the other hand, you might consider installing apache/php/mysql via your package manager.
what you can do is that you can use the chmod +x /your folder location/.run file that you want to install
after that you can run following command
./and your .run file name
example:-
in my case :- User#user~$su root
it will ask for password so give it
User#user~chmod +x /Downloads/xampp-linux-x64-1.8.3-0-installer.run
User#user~./xampp-linux-x64-1.8.3-0-installer.run

Resources