I've been searching all the Internet looking for this answer but couldn't find. The thing is, I have a graphics card from AMD (R9 380). From what I was reading on the lammps manual, the gpu package would only work with NVIDIA cards, since AMD's doesn't have cuda cores. But they also have a Makefile.linux_opencl, which, in theory, would work with AMD cards. I'm trying to install this gpu package for 2 days with no success...Has someone succeed to install this package in an AMD card? If so, what is the catch?
Quick look says it supports both AMD & NVidia (OpenCL & CUDA), so the answer is likely "yes". Did you try to clone from their github repo and build it with CMake ?
cmake /path/to/lammps/source/cmake -DENABLE_GPU=ON
i'm wildly guessing whatever makefiles they have are outdated...
Did you ever get this to work? This works on my system:
git clone https://github.com/lammps/lammps -b stable
cd lammps/lib/gpu
make -f Makefile.linux_opencl
cd ../../src
make yes-gpu
make mpi
The CMake build system works here too.
I had the same problem, running R9 280x from some mining equipment. I had succeeded with this configuration:
My prereqs:
Motherboard: Gigabyte P55A-UD4
CPU: intel core i5 760
GPU: R9 280x
Drivers
Set the hardware switch on the gpu to position 1 (default position)
Download and install Ubuntu 14.06.3 (make sure that the kernel is Linux 3.19)
Check if the correct kernel is installed with uname -r
Run: apt-get update and upgrade
Run: sudo apt-get install git make cmake gcc g++ gzip libfftw3-dev libtbb-dev mklibs mpich mpi-default-dev openmpi-bin ocl-icd-opencl-dev lib32gcc1 libc6-i386 dkms
From the AMD’s official site (for 280x: https://www.amd.com/en/support/graphics/amd-radeon-r9-series/amd-radeon-r9-200-series/amd-radeon-r9-280x) download all 4 drivers (fglrx, fglrx-core, fglrx-dev and fglrx-amdcccle) version 15.302 for Ubuntu 14.04. Use the installer notes file to install them properly (in the order specified below (or in the notes file)!)
Run: sudo dpkg -i fglrx-core_15.302-0ubuntu1_amd64_ub_14.01.deb fglrx_15.302-0ubuntu1_amd64_ub_14.01.deb fglrx-dev_15.302-0ubuntu1_amd64_ub_14.01.deb fglrx-amdcccle_15.302-0ubuntu1_amd64_ub_14.01.deb
Check if all drivers are installed properly with: dpkg -l fglrx-core fglrx fglrx-dev fglrx-amdcccle
Reboot machine
Run: clinfo and check if any errors exist (I had problems with fglrx)
LAMMPS
From home directory run: git clone http://github.com/lammps/lammps.git or extract any older version of lammps (from Github or other sites). Currently the version is 19 sep 2019
In the folder ~/lammps/lib/gpu check if Makefile.linux_opencl is ok with your sistem (for 280x i had used the default settings)
Compile the file using “make -f Makefile.linux_opencl” from the lib/gpu folder
Go to LAMMPS's src directory and run from there : make yes-gpu, make yes-user-omp
In the folder src/MAKE enable the cxx98 C++ compiler by deleting the comment (# mark) in the file make_mpi, line: LMP_INC = -DLAMMPS_GZIP -DLAMMPS_MEMALIGN=64 # -DLAMMPS_CXX98
from folder src/ run: make mpi
Your LAMMPS program should be compiled, the main file is located in the folder lammps/src/lmp_mpi.
When running the program you should run it via this directory or add this directory to PATH (export PATH="$PATH:/lammps/src")
Further work
Although when I wanted to install on newer hardware (ASUS prime b250m-k and intel pentium g4600) I had problems with graphical drivers, but I hadn't resolved the problem.
Related
I tried to build QEMU for RISC-V ISA simulator.
However, after I downloaded it and type the following:
$ ./configure --target-list=riscv-softmmu
It gave me this:
ERROR: Unknown target name 'riscv-softmmu'
Can anyone shed some lights on it?
I am using Mac OS.
The first issue with the configure command in your question is that the target name is invalid. The available RISC-V configure targets are
riscv64-softmmu
riscv32-softmmu
riscv64-linux-user (linux only)
riscv32-linux-user (linux only)
Also, the RISC-V port was accepted into QEMU 2.12, so you need to be using the most recent version. There are more details on SiFive's blog:
https://www.sifive.com/blog/2018/04/25/risc-v-qemu-part-2-the-risc-v-qemu-port-is-upstream/
If you want to try the latest version of the RISC-V QEMU port, you can clone and build the riscv-qemu GitHub repository:
Linux
git clone --recursive https://github.com/riscv/riscv-qemu.git
cd riscv-qemu
./configure --target-list=\
riscv64-softmmu,riscv32-softmmu,\
riscv64-linux-user,riscv32-linux-user
macOS
git clone --recursive https://github.com/riscv/riscv-qemu.git
cd riscv-qemu
./configure --target-list=\
riscv64-softmmu,riscv32-softmmu
The RISC-V QEMU Port Wiki contains a collection of information on the port include links to Operating System images for RISC-V QEMU:
https://github.com/riscv/riscv-qemu/wiki
Very nooby question, but I'm trying to install Atom text editor on Raspbian Stretch. Is it possible? I've heard because it runs on Electron, it's quite slow for Raspbian. I keep getting an error saying:
E: Unable to locate package atom
I'm following the official instructions for Debian. How can I fix this?
As of today you can't install the official package provided for Debian for its mismatching the hardware platform. Provided binary is for running on x86 hardware, but RPi doesn't come with an Intel/AMD processor, but ARM. So, you most probably need to build it from source yourself.
Primer
So, if you really want to build this from source, you should be aware of the waste of disk space caused by the IMHO poorly implemented build tool which is downloading tons of deps and copying and transpiling code around so you'll end up with 2GB+ of files with 80% accounting to dependencies, only. Since my RPi works with 8GB smartcard, only, I couldn't ever meet the need for disk space even though I was bleeding out Linux by manually removing docs, manpages, locales, ton's of outdated and mostly unused apps etc. The build also requires a whole build tooling chain, tons of dev packages for libraries, so there is a limit to milk the system ... 8GB disk drive simply isn't enough for this.
Eventually I tried moving all the files to a USB pen drive. But that drive must be formatted using a filesystem capable of symlinking. So you can't use vfat or FAT32. I didn't succeed to get a 16GB stick formatted with either version of extfs. The mkfs always ended up in a deadlock on trying to write its superblocks. Astonishingly, I couldn't even kill the mkfs with -KILL, but unplugging the drive did help in that case.
So, as a conclusion: here is a short list of steps I passed in expectation to get this working, but in the end I didn't finish due to the memory issues above. And frankly, I stopped caring ... I'd rather work with nano/vi in a terminal than using this ridiculous lego-like built software. I guess, atom is today's version of emacs with regards to the latter's acronym. Maybe you succeed with this, but I won't ...
Build from Source
Inspired by https://discuss.atom.io/t/atom-on-the-raspberry-pi/33332
Install toolchain for building native stuff
sudo apt-get install build-essential git libgnome-keyring-dev fakeroot gconf2 gconf-service libgtk2.0-0 libudev1 libgcrypt20 python rpm libsecret-1-dev xorg-dev
This set of tools was sufficient to build core files without error. Since I didn't start with a fresh installation of Raspbian there might have been some tool I have been using before, so maybe in your case there are more tools to be installed here. Look out for error messages in early stage of building and try to see if some library or header file isn't found. This mostly indicates lack of some package with name ending in -dev to be installed, too. Start by searching for the package using apt search <name-of-mentioned-library> and look for a package combining the missing library's name with suffix -dev. Then install it the usual way by invoking sudo apt-get install <package-name>.
Install up-to-date nodejs
Raspbian Stretch comes with support for NodeJS 8.11 which is basically okay. Install it and its package manager npm using this command:
sudo apt-get install node-js npm
Check installed versions with
node -v
npm -v
This should display 8.x.x on behalf of NodeJs. Use n afterwards if you want to step up:
sudo npm i -g n
sudo n lts
This will switch NodeJS to latest LTS release, which is 10.x as of now. Upgrading NodeJS is optional, but feel advised to always use latest version of npm:
sudo npm i -g npm
Check if upgrades succeeded:
node -v
npm -v
Adjust configuration of npm and install some essential dep:
sudo npm config set -g python /usr/bin/python2
sudo npm i -g node-gyp
Build Atom
Get the source. One option is to pull latest code from its repository:
git clone https://github.com/atom/atom.git
This is creating subfolder atom containing all source files. You might want to download sources of a recent release instead. But this tutorial was made with the sources fetched from Github. So make sure there is subfolder called atom containing sources similar to the ones fetched above.
It's time to start the beast:
cd atom
./script/build
This process will take a while. And it is the culprit that never finished on success in my case due to eating up all disk space over and over again.
Whenever the script fails on error, try to analyze the error, find the cause, fix it, then start the script by repeating the last command above again. If you don't remove any file in subfolder atom in between, the build script keeps passing steps of building atom it has passed successfully before.
Install atom
According to the original tutorial linked before the script should finish on success eventually. Then it's time to install with:
./script/grunt install
I guess this is causing atom to be available as a command from CLI. So, try it out. If everything looks fine you are finally ready to remove the waste of files in subfolder atom.
Feel free to report if this was working in your case.
From what I recall Atom runs 64-bit architecture; need the latest raspberry Pi.
run the following
wget https://atom.io/download/deb && dpkg -i deb
When I execute ANY command, this happens.
/lib64/ld-linux-x86-64.so.2: bad ELF interpreter: No such file or directory
I believe I accidentally removed glibc. Is there any way to install it? Non of the commands works. The system is CentOS 6, on a 1GB RAM VPS.
You can reinstall Glibc from an external system only, since the installing binaries use glibc. After booting up a rescue image mount the root of your system somewhere and download the glibc version that you would like to install and execute the following:
rpm -Uvh --root=/mnt/broken_system/ --force glibc-X.rpm
This install back the Glibc on your system so you can reboot your operating system and it will work.
Use below Command to remove
sudo yum remove java
example now i removing java
If you have only removed the symbolic links associated with glibc, you can recover it back by running ldconfig utility. It is a static binary and hence can be run successfully on broken glibc systems. On some distos, ldconfig would be a script which internally calls something like ldconfig.real, which is again a static binary.
From my previous question, I know that JavaFX is not supported in RedHat 5.8 meaning, even when I have Java 8 (jdk1.8.0_05) installed on my Linux, a JAR file created in win7 can't be executed via java -jar helloworld.jar. Does that mean there is NO way to run JavaFX jars on this machine?
The problem with running JavaFX applications on RHEL5 is the version of glib that comes with that OS is not new enough. The trick, then, is to provide a newer version of that library and all of the other libraries that depend on it to the JRE. The next hurdle is that RHEL5 shared library loader won't load those libraries. You have to use a compatible loader. But the JVM has the path to the loader hard-coded in the executable! So you need a separate JVM with a custom loader path patched in. Roughly, the steps to get this working are...
Unpack the following packages from RHEL6:
glib2
libffi
glibc
glibc-common
zlib
gtk2
pango
cairo
pixman
Put all of the shared libraries from those packages in a directory on your RHEL5 system. Let's call it /YOUR-ALIEN-RHEL6-LIBS-PATH.
Unpack another copy of a JRE to, say, /YOUR-ALIEN-JVM-PATH.
Use patchelf to point the JVM executable to the new loader.
./usr/bin/patchelf --set-interpreter /YOUR-ALIEN-RHEL6-LIBS-PATH/lib/amd64/ld-linux-x86-64.so.2 /YOUR-ALIEN-JVM-PATH/jre1.8.0_25/bin/java
Run the application after setting LD_LIBRARY_PATH=/YOUR-ALIEN-RHEL6-LIBS-PATH/lib/amd64:/YOUR-ALIEN-RHEL6-LIBS-PATH/lib/amd64/jli
Although it is not pretty, I have successfully run JavaFX applications on RHEL5 using this method. Having said that, I highly recommend just upgrading your OS if it is even remotely feasible.
Note this builds upon the existing answer from James with more concrete detail
Obtain RPMs from a RedHat 6.x, e.g. http://vault.centos.org/6.2/os/i386/Packages. Copy into directory rpms/
cairo-1.8.8-3.1.el6.i686.rpm
glib2-2.22.5-6.el6.i686.rpm
glibc-2.12-1.47.el6.i686.rpm
glibc-common-2.12-1.47.el6.i686.rpm
gtk2-2.18.9-6.el6.centos.i686.rpm
libffi-3.0.5-3.2.el6.i686.rpm
libXcomposite-0.4.1-2.el6.i686.rpm <== not mentioned in other answer
pango-1.28.1-3.el6_0.centos.5.i686.rpm
pixman-0.18.4-1.el6_0.1.i686.rpm
zlib-1.2.3-27.el6.i686.rpm
libXdamage-1.1.2-1.el6.i686.rpm <== not mentioned in other answer
Extract all the contents from the RPMs into separate directory. Use rpm2cpio and xzcat. xzcat can be installed from these RPMs if necessary [xz, xz-libs, xz-lzma-compat]
mkdir redhat-6u2-libs
cd redhat-6u2-libs/
ls -1 rpms/* | xargs -i{} bash -c "rpm2cpio {} | xzcat | cpio -idmv"
Obtain copy of patchelf. I built from source as couldn't find a Redhat 5 RPM. Only requires dependent RPMs [gcc, gcc-c++, glibc-devel, kernel-headers, libstdc++-devel]
wget https://nixos.org/releases/patchelf/patchelf-0.9/patchelf-0.9.tar.bz2
tar xjf patchelf-0.9.tar.bz2
cd patchelf-0.9
./configure --prefix /tmp/patchelf
make install
Use patchelf to set location of redhat 6u2 loader (aka interpreter)
/tmp/patchelf/bin/patchelf --set-interpreter ~/redhat-6u2-libs/lib/ld-linux.so.2 jdk1.8.0_40/bin/java
Set LD_LIBRARY_PATH, this needs to have both /usr/lib and /lib, otherwise you get a segfault.
export LD_LIBRARY_PATH=/home/user/redhat-6u2-libs/usr/lib:/home/user/redhat-6u2-libs/lib
(Note that any other applications run after LD_LIBRARY_PATH is set other than java which has had its interpreter location corrected will segfault.)
Now run java app...
./jdk1.8.0_40/bin/java -cp etc...
Happy days
I am following the instruction to install Oracle 11G in Ubuntu 12.04 LTS (x64) from this web page
Oracle 11g also needs libstdc++5 in 32bits version that is not provided with Ubuntu Pangolin, So I follow these instructions:
mkdir /tmp/libstdc++5
cd /tmp/libstdc++5
wget http://old-releases.ubuntu.com/ubuntu/pool/universe/g/gcc-3.3/libstdc++5_3.3.6-17ubuntu1_amd64.deb
wget http://old-releases.ubuntu.com/ubuntu/pool/universe/g/gcc-3.3/libstdc++5_3.3.6-17ubuntu1_i386.deb
sudo dpkg --force-architecture -i libstdc++5_3.3.6-17ubuntu1_i386.deb
sudo mv /usr/lib/libstdc++.so.5* /usr/lib32/
But when executing this command:
sudo dpkg -i libstdc++5_3.3.6-17ubuntu1_amd64.deb
I get this error:
dpkg: error al procesar libstdc++5_3.3.6-17ubuntu1_amd64.deb (--install):
libstdc++5: 1:3.3.6-17ubuntu1 (Multi-Arch: no) is not co-installable with libstdc++5:i386 1:3.3.6-17ubuntu1 (Multi-Arch: no) which is currently installed
Se encontraron errores al procesar:
libstdc++5_3.3.6-17ubuntu1_amd64.deb
How should I deal this installation problem?
There is a few ways of going about this to fix it. I am not using a pentium processor, so i did not worry about that particular package model. Some of the 11gR2 make files are for older versions of the linux kernel, so the gcc compilers are also older.
Lets think it out, Oracle Enterprise is based off Red Hat. The newest version of the kernel, 'out-the-box', on Red Hat 5 was like ~ 2.6 maybe?!. So the files are gonna use a gcc version that was relative to the kernel at the time. Red Hat, unlike its daughter project Fedora, is a fairly slow evolving creature in terms of kernel version.
I have used the libstc++5_3.3.6-25.deb packages (i386 and amd64). That particular package set (3.3.6-17) is for the i686 P6 micro-architecture. Which is the Intel Pentium class of cpu's.
I do not know what you are using 11g on, or for, but the packages I have listed will work if your CPU is not a Pentium. Ive used the enterprise manager, the database, sqlplus, and SQL Developer. I even downloaded Data Modeler and use it. But thats another 5,000 words of details on how to get that puppy running. Back to the question at hand:
If not already done; create the Oracle user, and the dba, oper, and oinstall groups.
Give the /mnt_pt/././ directory to the oracle user and oinstall group with -R privleges
~$ sudo mkdir -p /mnt_pt/app (i.e. opt directory is used frequently or create one)
~$ sudo useradd -g oinstall -G dba -d /mnt_pt/app -s /bin/bash oracle
~$ sudo passwd oracle
~$ sudo chown -R oracle:oinstall /mnt_pt/app
3.1 download the synaptic package manager. $ sudo apt-get install synaptic -y
3.2 download mlocate (should be installed) $ sudo apt-get install mlocate -y
4.1 Go to the User and User Groups app: SystemSettings>users and accounts. Set the oracle account type to administrator.
4.2 Log out of your account, enter the oracle account.
4.3 From the oracle account open Synaptic Package manager. Search for the libstdc++5 (3.3.6-25) files. DO NOT INSTALL THEM!!!!
4.4 Mark both packages from installation. DO NOT INSTALL THEM!!!
4.5 On the Package menu of the Synaptic app, disable the Automatically Install feature.
4.6 Open the File menu of synaptic, and select the Generate Script option and choose the directory you made as the save destination. (In your case /tmp/libstdc++5)
4.7 QUIT without apply changes.
5.1 Manually open the file you saved the script in. Right click the libstdc++5 script, and choose run in terminal.
5.2 This will deliver two .deb packages. Change your forcearch code from 3.3.6-17 to 3.3.6-25
6.1 Find out where the libraries (libstdc++.so.5) are by running the following code:
$ sudo updatedb
$ locate libstdc++.so.5 .......(the .so. stands for libraries)
6.2 Your looking for 5 and 5.07. now run the following lines of code to move it where you want them (file is the parent directory where they are stored)
sudo mv /file/lib/libstdc++.so.5* /usr/lib32/
I installed Fedora 19 just to try and see where I was making errors and if I could get those packages. It was a learning experience. That particular package set is for the i686 P6 micro-architecture. Which is a hard one to find! Fedora 19 is EXTREMELY SHARP but, I set out to use Ubuntu, so that's what I did!! By the way the hardest part comes after that!
Anymore questions let me know!
P.S. if you are using a pentium I advise you to do a second install with fedora, wget the packages from the noarch repository, transfer those to a usb, switch back to Ubuntu, and after installing alien and rpm, from the command-line run the alien command for the packages via the directory they are in (or right click the packages), and then do a dpkg-forcearchitecure.