How to install Maven in Putty.exe? - c

I have to build and compile my project through Putty(through a remote linux environment). I am unable to execute maven commands(such as mvn compile, mvn test etc) in Putty as it cannot identify "mvn" as a command. For this I need to install maven in my remote system. How do I do it?

Is putty used to connect via ssh to the remote computer? If you are logged in type the following command in the terminal:
curl http://apache.panu.it/maven/maven-3/3.3.3/binaries/apache-maven-3.3.3-bin.tar.gz > maven.tar.gz
Then follow instruction on site to install it: LINK
You can also use sudo apt-get install maven but I don't know which version is on repository.

sudo apt-get update
sudo apt-get install maven
That is, if you have Ubuntu.
How to install maven2 on redhat linux
there is a thread for maven on red hat.

Related

sudo apk: command not found on Linux

I'm attempting to install SQL Server driver on AWS SageMaker Notebook instance running Amazon Linux 2. I am following the documentation here - Alpine Linux section: https://learn.microsoft.com/en-us/sql/connect/odbc/linux-mac/installing-the-microsoft-odbc-driver-for-sql-server?view=sql-server-ver16
When I attempt to install after downloading using the following commands, I get an error:
#Install the package(s)
sudo apk add --allow-untrusted msodbcsql18_18.1.1.1-1_amd64.apk
sudo apk add --allow-untrusted mssql-tools18_18.1.1.1-1_amd64.apk
sudo apk: command not found on Linux
Linux version:
5.10.102-99.473.amzn2.x86_64
What do I need to do before running the commands?

Apache start libphp7.3.so not found

I have Install php 7.3 and apache2 but when I try to start apache2 , I have this error :
service apache2 start
apache2: Syntax error on line 146 of /etc/apache2/apache2.conf: Syntax error on line 3 of /etc/apache2/mods-enabled/php7.3.load: Cannot load /usr/lib/apache2/modules/libphp7.3.so into server: /usr/lib/apache2/modules/libphp7.3.so: cannot open shared object file: No such file or directory
I really don't know how to resolve this problem, I have tried to remove and reinstall without success.
You're getting that error because the PHP 7.3 library for Apache is not installed.
sudo apt install -y libapache2-mod-php7.3
The above command should fix it.
It solved my problem:
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install php7.3
sudo apt-get install php7.3-cli php7.3-common php7.3-json php7.3-opcache php7.3-mysql php7.3-mbstring php7.3-zip php7.3-fpm php7.3-intl php7.3-simplexml
sudo service apache2 restart
For me the problem was that I did not install apache tools for php.
On arch linux:
yaourt -S php-apache
After that, module appeared in the folder.
The best way not to make a mistake is to follow guide: https://wiki.archlinux.org/title/Apache_HTTP_Server#PHP

Install Adminer on Ubuntu 18.04 bionic

I'm trying to install Adminer from Ubuntu repository using:
sudo apt install adminer
Installation works fine but can't find the file /etc/adminer/apache.conf to use with Apache server. The folder /etc/adminer/ is empty and can't find it anywhere with find command.
Any help?
Thanks in advance.
In the next few steps, I'll show you how I installed adminer for Ubuntu 18.04.1 LTS .
After installation with apt package manager change into the adminer directory.
cd /usr/share/adminer
There you will find a file called compile.php.
Run the following command and the adminer-X.X.X.php (X.X.X for your version) file will be created.
sudo php compile.php
Create the apache adminer configuration file.
sudo echo "Alias /adminer.php /usr/share/adminer/adminer-X.X.X.php" | sudo tee /etc/apache2/conf-available/adminer.conf
Now you'll need to activate the configuration.
cd /etc/apache2/conf-available/
sudo a2enconf adminer.conf
Reload your apache webserver.
sudo systemctl reload apache2.
Test in your browser of choice (localhost/adminer.php)
This source was really helpful:
https://www.linuxhelp.com/how-to-install-adminer-on-ubuntu-16-04/
Install Apache:
sudo apt-get install apache2
Install PHP:
sudo apt-get install php libapache2-mod-php php-mysql
Install Adminer:
sudo wget "http://www.adminer.org/latest.php" -O /var/www/html/adminer.php
Once the installation completes, restart Apache.
sudo service apache2 restart
At this point, the setup is complete. You can access Adminer at the following address.
http://[SERVER_IP]/adminer.php

WebDriverError: Cannot define class using reflection

I am using gulp-angular-protractor for end-to-end testing of my web app. I am getting the following error recently but earlier it used to work perfectly.
Any help to fix this issue will be appreciated.
Details:
OS - Ubuntu 16.04,
node - v6.12.2,
npm - v3.10.10,
Vagrant - v1.9.3,
karma - v0.13.22,
gulp-angular-protractor - v1.1.1,
protractor - v5.1.2,
webdriver-manager - v12.0.6
Removing java-common and installing openjdk-8-jre fixed the issue for me.
To remove java-common and its dependencies, run below command
sudo apt-get purge --auto-remove java-common
To install openjdk-8-jre, run below command
sudo add-apt-repository ppa:openjdk-r/ppa
sudo apt-get update
sudo apt-get install openjdk-8-jdk
Additionally, if you have more than one Java versions installed on your system. Run below command set the default Java
sudo update-alternatives --config java
and type in a number to select a Java version.

Install rst2man failed for varnish agent [fix]

I'm trying install varnish agent on ubuntu server using virtual box. There is a message in the middle installation process that say "you need rst2man installed to make dist".
When I tried install rst2man using "sudo apt-get install rst2man" another message come in :
Reading package list....done
Building dependecy tree
Reading state information....done
E: unable to locate package rst2man
"unable to locate package rst2man" what does it mean ? anyone know ? please help.
Problem fix:
I tried to install python-docutils for the rst2man.
rst2man is a virtual package, then you need install python-docutils package than provide rst2man and utilities for the documentation of Python modules.
sudo apt-get install python-docutils
After install this package, try the command:
sudo which rst2man
python-docutils wasn't working for me
I had to install the package docutils-common
sudo apt-get install docutils-common
In case if you installing varnish-agent-2 - after
sudo apt-get install python-docutils
you should execute again
./configure
Working on CentOS and likely RHEL as well:
yum install python-docutils

Resources