I'm getting this error while installing/listing firefox or python on a Linux server. Any ideas how to fix it.
# yum install firefox
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was:
/usr/lib64/libnssutil3.so: undefined symbol: PL_ClearArenaPool
Please install a package which provides this module, or
verify that the module is installed correctly.
It's possible that the above module doesn't match the
current version of Python, which is:
2.4.3 (#1, Oct 23 2012, 22:02:41)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-54)]
If you cannot solve this problem yourself, please go to
the yum faq at:
http://wiki.linux.duke.edu/YumFaq
Instead of getting the following output/value for firefox -version command.
$ firefox --version
Mozilla Firefox 17.0.9
I'm getting:
XPCOMGlueLoad error for file /opt/firefox/libxpcom.so:
libxul.so: cannot open shared object file: No such file or directory
Couldn't load XPCOM.
python -h command output looks valid.
python -V shows:
Python 2.4.3
When I'm running Selenium tests (which requires firefox and Xvfb), I get the following error:
org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:
XPCOMGlueLoad error for file /opt/firefox/libxpcom.so:
libxul.so: cannot open shared object file: No such file or directory
Couldn't load XPCOM.
XPCOMGlueLoad error for file /opt/firefox/libxpcom.so:
libxul.so: cannot open shared object file: No such file or directory
Couldn't load XPCOM.
The problem is not python, it’s the LD_LIBRARY_PATH that does not include /lib64 and /usr/lib64 setting values. we fixed this by pre-pending /lib64:/usr/lib64 to the LD_LIBRARY_PATH.
export LD_LIBRARY_PATH=/usr/lib64/:/lib64:$LD_LIBRARY_PATH
After this point, when I did yum help or yum install firefox (it didn't give the above error) BUT:
firefox --version still gave the error:
XPCOMGlueLoad error for file /opt/firefox/libxpcom.so:
libxul.so: cannot open shared object file: No such file or directory
Couldn't load XPCOM.
Now, I finally ran yum install firefox and it installed bunch of components and at the end said:
Installing : alsa-lib 20/23
Installing : xulrunner 21/23
Installing : firefox 22/23
Installing : firefox 23/23
Installed:
firefox.i386 0:17.0.9-1.el5_9 firefox.x86_64 0:17.0.9-1.el5_9
Dependency Installed:
GConf2.i386 0:2.14.0-9.el5 ORBit2.i386 0:2.14.3-5.el5 alsa-lib.i386 0:1.0.17-1.el5 atk.i386 0:1.12.2-1.fc6 avahi.i386 0:0.6.16-10.el5_6 avahi-glib.i386 0:0.6.16-10.el5_6 cairo.i386 0:1.2.4-5.el5
cups-libs.i386 1:1.3.7-30.el5_9.3 gamin.i386 0:0.1.7-10.el5 gnome-vfs2.i386 0:2.16.2-12.el5_9 gnutls.i386 0:1.4.1-10.el5_9.2 gtk2.i386 0:2.10.4-29.el5 libIDL.i386 0:0.8.7-1.fc6 libXcursor.i386 0:1.1.7-1.2
libXfixes.i386 0:4.0.1-2.1 libXinerama.i386 0:1.0.1-2.1 libXrandr.i386 0:1.1.1-3.3 libacl.i386 0:2.2.39-8.el5 libattr.i386 0:2.4.32-1.1 pango.i386 0:1.14.9-8.el5_7.3 xulrunner.i386 0:17.0.9-1.el5_9
Complete!
Now firefox version is showing correctly.
firefox --version
Mozilla Firefox 17.0.9
Everything is working now.
Related
I am trying to use the GDB debugger using OpenOCD (Ubuntu) for a RISC-V processor running on hardware. I have successfully connected to the RISC-V core with OpenOCD. When I try to run GDB I get the following error message:
riscv32-unknown-elf-gdb: error while loading shared libraries: libpython3.8.so.1.0: cannot open shared object file: No such file or directory***
I don't know why Python is needed to run this command but I do have Python 3.10 installed on Ubuntu. Do I need Python 3.8 or what is wrong here?
I have checked the GDB toolchain and it is installed correctly.
EDIT
I am not very experienced with software involving compilers etc and Ubuntu so I will try add whatever I think may be useful. Or if anyone can advise any way of checking decencies or have any tests I could do to check, let me know.
Below shows trying to run the RISC-V GDB command on Ubuntu, and showing the error message:
david#DESKTOP-3UBE0P7:/mnt/c/Users/David/.Xilinx/Neorv32_basys3_test_setup_on_chip_debugger/neorv32-main/sw/example/demo_blink_led$ export PATH=$PATH:/opt/riscv/bin
david#DESKTOP-3UBE0P7:/mnt/c/Users/David/.Xilinx/Neorv32_basys3_test_setup_on_chip_debugger/neorv32-main/sw/example/demo_blink_led$ riscv32-unknown-elf-gdb
riscv32-unknown-elf-gdb: error while loading shared libraries: libpython3.8.so.1.0: cannot open shared object file: No such file or directory
IN RESPONSE TO CHARLES DUFFY'S COMMENT
I think I am in the correct place you are talking about but it seems like it is not there.
david#DESKTOP-3UBE0P7:/$ ls
bin etc lib libx32 mnt riscv-openocd run srv usr
boot home lib32 lost+found opt riscv32-unknown-elf.gcc-12.1.0.tar.gz sbin sys var
dev init lib64 media proc root snap tmp
david#DESKTOP-3UBE0P7:/$ cd opt
david#DESKTOP-3UBE0P7:/opt$ ls
riscv
david#DESKTOP-3UBE0P7:/opt$ cd riscv/
david#DESKTOP-3UBE0P7:/opt/riscv$ ls
bin include lib libexec riscv32-unknown-elf share
david#DESKTOP-3UBE0P7:/opt/riscv$ cd lib
david#DESKTOP-3UBE0P7:/opt/riscv/lib$ ls
bfd-plugins gcc libcc1.la libcc1.so libcc1.so.0 libcc1.so.0.0.0 libriscv32-unknown-elf-sim.a
when executing a python script, I get this after generating a figure:
libGL error: MESA-LOADER: failed to open iris: /usr/lib/dri/iris_dri.so: cannot open shared object file: No such file or directory (search paths /usr/lib/x86_64-linux-gnu/dri:$${ORIGIN}/dri:/usr/lib/dri, suffix _dri) libGL error: failed to load driver: iris libGL error: MESA-LOADER: failed to open iris: /usr/lib/dri/iris_dri.so: cannot open shared object file: No such file or directory (search paths /usr/lib/x86_64-linux-gnu/dri:$${ORIGIN}/dri:/usr/lib/dri, suffix _dri) libGL error: failed to load driver: iris libGL error: MESA-LOADER: failed to open swrast: /usr/lib/dri/swrast_dri.so: cannot open shared object file: No such file or directory (search paths /usr/lib/x86_64-linux-gnu/dri:$${ORIGIN}/dri:/usr/lib/dri, suffix _dri) libGL error: failed to load driver: swrast
I dont know how to fix it, i have searched for information but have found nothing to help me
Here are two possible solutions. Try them both and see what works.
Solution 1
Follow the instructions in this answer.
Solution 2
If you are using Anaconda to run this Python script, Anaconda may be the reason. This solution was taken from here (update 3), which in turn was taken from here.
From the latter link:
According to online information, there is a problem with the libstdc++.so file in Anaconda (I use this commercial python distribution). It cannot be associated with the driver of the system, so we removed it and used the libstdc++ that comes with Linux. so creates a soft link there.
To solve this problem, run this in bash:
$ cd /home/$USER/miniconda/lib
$ mkdir backup # Create a new folder to keep the original libstdc++
$ mv libstd* backup # Put all libstdc++ files into the folder, including soft links
$ cp /usr/lib/x86_64-linux-gnu/libstdc++.so.6 ./ # Copy the c++ dynamic link library of the system here
$ ln -s libstdc++.so.6 libstdc++.so
$ ln -s libstdc++.so.6 libstdc++.so.6.0.19
where $USER should be your own username.
This worked for me:
mv ~/anaconda3/lib/libstdc++.so.6 ~/libstdc++.so.6
i resolved this issue with spyder 5.3.3 python 3.10.9 using this answer
https://stackoverflow.com/a/71421355/9153119
conda install -c conda-forge libstdcxx-ng
I'm running JupyterLab from Anaconda, and installed a JupyterLab plotly extension using:
conda install -c conda-forge jupyterlab-plotly-extension
Apparently, the installation was successful, but something is still wrong.
When launching JuyterLab, I'm getting this prompt:
Clicking BUILD gives me this:
And clicking RELOAD relods JupyterLab, BUT I'm getting this again:
And on and on it spins. Does anyone know why?
Clicking CANCEL does not help either because plotly won't produce any plots, only blank spaces:
Solution:
Deactivate firewall and run the following command in a windows command prompt:
jupyter lab build
The details:
This turned out to be a firewall problem, and I'm not sure why it would not be prompted as such in the JupyterLab interface. The following command in a windows command prompt returned the error message below:
Command:
jupyter lab build
Output:
C:>jupyter labextension list JupyterLab v0.34.9 Known labextensions:
app dir:
C:\Users*******\AppData\Local\Continuum\anaconda3\share\jupyter\lab
#jupyterlab/plotly-extension v0.18.2 enabled ok
Build recommended, please run jupyter lab build:
#jupyterlab/plotly-extension needs to be included in build
C:>jupyter lab build [LabBuildApp] JupyterLab 0.34.9 [LabBuildApp]
Building in
C:\Users*******\AppData\Local\Continuum\anaconda3\share\jupyter\lab
[LabBuildApp] > node
C:\Users*******\AppData\Local\Continuum\anaconda3\lib\site-packages\jupyterlab\staging\yarn.js
install yarn install v1.9.4 info No lockfile found. [1/4] Resolving
packages... error An unexpected error occurred:
"https://registry.yarnpkg.com/#jupyterlab%2fapplication: self signed
certificate in certificate chain". info If you think this is a bug,
please open a bug report with the information provided in
"C:\Users\*******\AppData\Local\Continuum\anaconda3\share\jupyter\lab\staging\yarn-error.log".
What pointed me towards suspecting a firewall problem was this part:
self signed certificate in certificate chain
Running the same command on less rigid fire-wall settings triggers this output (shortened):
WARNING in d3-array Multiple versions of d3-array found:
1.2.4 ./~/d3-scale/~/d3-array from ./~/d3-scale/~/d3-array\src\index.js
2.2.0 ./~/d3-array from ./~/d3-array\src\index.js
Check how you can resolve duplicate packages:
https://github.com/darrenscerri/duplicate-package-checker-webpack-plugin#resolving-duplicate-packages-in-your-bundle
Child html-webpack-plugin for "index.html":
1 asset
Entrypoint undefined = index.html
[KTNU] ./node_modules/html-loader!./templates/partial.html 567 bytes {0} [built]
[YuTi] (webpack)/buildin/module.js 497 bytes {0} [built]
[aS2v] ./node_modules/html-webpack-plugin/lib/loader.js!./templates/template.html
1.22 KiB {0} [built]
[yLpj] (webpack)/buildin/global.js 489 bytes {0} [built]
+ 1 hidden module
And despite some warning messages, JupyterLab now produces plotly figures without any problems:
I upgraded apache from 2.4.25 to 2.4.29 due to security reasons in Mac OSX.
Also installed mod_wsgi via pip.
Now facing difficulty while restarting the apache server!
I ran this command as per the mod_wsgi docs,
> mod_wsgi-express module-config
LoadModule wsgi_module "/Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so"
WSGIPythonHome "/System/Library/Frameworks/Python.framework/Versions/2.7"
Copied the above two lines in apache.conf file and tried to start the apache server but getting the following error:
> sudo apachectl start
/usr/local/apache/bin/apachectl: line 79: 51863 Illegal instruction: 4 $HTTPD -k $ARGV
Any help would be appreciated. Thanks!
EDIT as per Graham answer:
# I upgraded the mod_wsgi
> sudo pip install --upgrade --no-cache-dir mod_wsgi
Collecting mod_wsgi
Downloading mod_wsgi-4.5.21.tar.gz (2.5MB)
100% |████████████████████████████████| 2.5MB 2.1MB/s
Installing collected packages: mod-wsgi
Found existing installation: mod-wsgi 4.5.20
Uninstalling mod-wsgi-4.5.20:
Successfully uninstalled mod-wsgi-4.5.20
Running setup.py install for mod-wsgi ... done
Successfully installed mod-wsgi-4.5.21
But when i tried:
> mod_wsgi-express start-server
Traceback (most recent call last):
File "/Library/WebServer/Documents/DSFENV/bin/mod_wsgi-express", line 11, in <module>
load_entry_point('mod-wsgi==4.5.21', 'console_scripts', 'mod_wsgi-express')()
File "/Library/WebServer/Documents/DSFENV/lib/python2.7/site-packages/mod_wsgi/server/__init__.py", line 3484, in main
cmd_start_server(args)
File "/Library/WebServer/Documents/DSFENV/lib/python2.7/site-packages/mod_wsgi/server/__init__.py", line 3332, in cmd_start_server
config = _cmd_setup_server('start-server', args, vars(options))
File "/Library/WebServer/Documents/DSFENV/lib/python2.7/site-packages/mod_wsgi/server/__init__.py", line 2999, in _cmd_setup_server
language, encoding = locale.getdefaultlocale()
File "/Library/WebServer/Documents/DSFENV/lib/python2.7/locale.py", line 543, in getdefaultlocale
return _parse_localename(localename)
File "/Library/WebServer/Documents/DSFENV/lib/python2.7/locale.py", line 475, in _parse_localename
raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8
getting the above error.
Also I have installed apache 2.4.29 following this blog:
2nd Edit
I have resolved ValueError: unknown locale: UTF-8, now the output of mod_wsgi-express start-server shows:
> mod_wsgi-express start-server
Server URL : http://localhost:8000/
Server Root : /tmp/mod_wsgi-localhost:8000:501
Server Conf : /tmp/mod_wsgi-localhost:8000:501/httpd.conf
Error Log File : /tmp/mod_wsgi-localhost:8000:501/error_log (warn)
Request Capacity : 5 (1 process * 5 threads)
Request Timeout : 60 (seconds)
Startup Timeout : 15 (seconds)
Queue Backlog : 100 (connections)
Queue Timeout : 45 (seconds)
Server Capacity : 20 (event/worker), 20 (prefork)
Server Backlog : 500 (connections)
Locale Setting : en_US.UTF-8
But when I try to do config test, still showing the same error:
> sudo apachectl configtest
/usr/local/apache/bin/apachectl: line 79: 53944 Illegal instruction: 4 $HTTPD -t
xcode version:
> xcodebuild -version
Xcode 8.3.2
Build version 8E2002
3rd EDIT as per comments:
> /usr/local/apache/bin/httpd
Illegal instruction: 4
> /Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so
-bash: /Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so: cannot execute binary file
> sys.prefix
'/System/Library/Frameworks/Python.framework/Versions/2.7'
> sys.version
'2.7.10 (default, Feb 7 2017, 00:08:15) \n[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]'
I followed this blog to install Apache 2.4.29:
http://mac-dev-env.patrickbougie.com/apache/
--with-ssl option as we need to https for the website.
4th EDIT:
> file /usr/local/apache/bin/httpd
/usr/local/apache/bin/httpd: Mach-O 64-bit executable x86_64
> file /Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so
/Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so: Mach-O universal binary with 2 architectures: [x86_64: Mach-O 64-bit bundle x86_64] [i386: Mach-O bundle i386]
/Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so (for architecture x86_64): Mach-O 64-bit bundle x86_64
/Library/Python/2.7/site-packages/mod_wsgi/server/mod_wsgi-py27.so (for architecture i386): Mach-O bundle i386
Please let me know how to proceed forward.
If you have updated your Apache installation in some way, usually the mod_wsgi.so binary from an older release should still work as Apache maintains ABI compatibility across patch level updates.
If it isn't working, then you may need to re-build mod_wsgi. If there is no newer version of mod_wsgi, you will need to force a full re-build to ensure cached binaries from pip cache are not used.
pip install --upgrade --no-cache-dir mod_wsgi
Next problem though is if you have upgraded to Xcode 9.1, Apple have further broken things by completely removing apxs, meaning that my prior workaround for Apple brokeness no longer works. In this case you need to ensure you are installing mod_wsgi 4.5.21 or later. That version only just got released with fixes to accomodate for Xcode 9.1
So try that pip command above and make sure mod_wsgi-express still works by running:
mod_wsgi-express start-server
Then validate configuration snippet to use in Apache config by running again:
mod_wsgi-express module-config
If still issues with main Apache, then ensure you do a complete stop of Apache and then a start, and not just restart. Let me know how that all goes.
UPDATE 1
Above presumes you were using Apple supplied Apache in respect of Xcode 9.1 comments. You seem to be using your own Apache, maybe form Homebrew. Still try the same thing.
As suggested by Graham:
pip install --upgrade --no-cache-dir mod_wsgi
Upgrade to mod_wsgi 4.5.22 did the trick.
I'm working on Plone.
PRELUDE
I've installed:
oracle-instantclient12.1-basic-12.1.0.1.0-1.x86_64.rpm
oracle-instantclient12.1-devel-12.1.0.1.0-1.x86_64.rpm
oracle-instantclient12.1-sqlplus-12.1.0.1.0-1.x86_64.rpm
and also cx_Oracle.
I've tested the installations and it's all ok: db connection successfully.
echo $ORACLE_HOME
/usr/lib/oracle/12.1/client64
echo $TNS_ADMIN
/usr/lib/oracle/12.1/client64/admin
echo $LD_LIBRARY_PATH
/usr/lib/oracle/12.1/client64/lib
THE PROBLEM
I've edited buildout.cfg as follows:
[...]
eggs =
Plone
Pillow
collective.documentviewer
Products.OpenXml
Products.AROfficeTransforms
tus
wildcard.foldercontents==2.0a7
**cx_Oracle**
[...]
I receive this error:
Unused options for buildout: 'environment-vars'.
Installing instance.
Getting distribution for 'cx-Oracle'.
error: cannot locate an Oracle software installation
An error occurred when trying to install cx-Oracle 5.1.3. Look above this message for any errors that were output by easy_install.
While:
Installing instance.
Getting distribution for 'cx-Oracle'.
Error: Couldn't install: cx-Oracle 5.1.3
I have no idea how to solve this.
"cannot locate an Oracle software installation" How to fix this?
Got the same problem, background is:
echo $ORACLE_HOME
/usr/lib/oracle/12.1/client64
But:
sudo env | grep ORACLE_HOME
yields nothing.
The solution:
sudo visudo
Then add the line :
Defaults env_keep += "ORACLE_HOME"
As found here
You must be sure that the right envvars are setted for the user that run the Plone instance.
The best way is to add those vars in the buildout configuration::
[buildout]
...
[instance]
...
environment-vars =
...
LD_LIBRARY_PATH /usr/lib/oracle/10.2.0.3/client64/lib
ORACLE_HOME /usr/lib/oracle/10.2.0.3/client64
(This is what I have on a CentOS installation)