i have install Nginx with this command on Debian :
sudo apt install nginx
There is no error during the installation. but after when i want to use Nginx command :
nginx -v
-bash: nginx : commande introuvable
echo $PATH :/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
There is no file on /usr/local/sbin for Nginx
Try it with sudo
sudo nginx -V
Related
I followed these commands to install R and Shiny server on REHL 7 AWS.
sudo yum update
yum install wget gcc pcre-devel libXt-devel cairo-devel pango-devel
pango libpng-devel curl-devel unixODBC-devel python-devel java-1.8.0-
openjdk-devel xz-devel
yum groupinstall "Development tools"
wget http://www.bzip.org/1.0.6/bzip2-1.0.6.tar.gz
tar xzvf bzip2-1.0.6.tar.gz
cd bzip2-1.0.6
make -f Makefile-libbz2_so
make clean
make
make -n install
make install
cd ~
wget https://cran.r-project.org/src/base/R-3/R-3.3.2.tar.gz
tar -xzvf R-3.3.2.tar.gz
cd R-3.3.2
./configure --with-readline=no --with-x=no
make
make install
cp -r /usr/local/bin/R /usr/local/sbin/R
cp -r /usr/local/bin/Rscript /usr/local/sbin/Rscript
--Installing R packages
R
install.packages(c('shiny', 'rmarkdown', 'Cairo', 'png', 'rJava',
'RCurl'))
--Changing folder permissions
chmod 777 -R /usr/local/bin
chmod 777 -R /usr/local/sbin
chmod 777 -R /usr/local/lib64/R
chmod 777 -R /usr/local/lib64/R/library
chmod 777 /usr/local/lib64/R/etc/ldpaths
--shiny server installation
wget https://download3.rstudio.org/centos5.9/x86_64/shiny-server-
1.5.1.834-rh5-x86_64.rpm
sudo yum install --nogpgcheck shiny-server-1.5.1.834-rh5-x86_64.rpm
R CMD javareconf
chmod 777 /usr/local/lib64/R/etc/ldpaths
Everything ran fine with some warnings. But the shiny-server.service file is missing. When I try to execute
systemctl restart shiny-server
it says: Failed to restart shiny-server.service: Unit not found.
I also tried installing the newer version of R (3.4.1) and Shiny server(shiny-server-1.5.3.838-rh5-x86_64.rpm) but I am still getting the same error. This is the message I got when I installed shiny server:
/var/tmp/rpm-tmp.kIBODd: line 62: initctl: command not found
/var/tmp/rpm-tmp.kIBODd: line 65: initctl: command not found
Verifying : shiny-server-1.5.1.834-1.x86_64
1/1
Installed:
shiny-server.x86_64 0:1.5.1.834-1
Also I noticed that shiny-server.service is missing in /etc/systemd/system folder. Has anyone resolved this or knows how to resolve this?
I had the same problem.
As suggested in https://github.com/rstudio/shiny-server/issues/316,
entering these three lines manually solved it for me:
sudo cp /opt/shiny-server/config/systemd/shiny-server.service /etc/systemd/system/
sudo systemctl enable shiny-server
sudo systemctl restart shiny-server
I'm trying to reinstall nginx, but I have this
nginx -t
nginx: [alert] could not open error log file: open()
"/var/log/nginx/error.log" failed (2: No such file or directory)
2015/01/25 16:18:01 [emerg] 1400#0: open() "/etc/nginx/nginx.conf"
failed (2: No such file or directory)
nginx: configuration file /etc/nginx/nginx.conf test failed
How to install and start nginx if I removed all the nginx folders?
Login as root or:
sudo su -
Then uninstall nginx:
apt-get purge nginx nginx-common nginx-full
And then install it:
apt-get install nginx
The other way is to run sudo command with -H:
sudo -H apt-get purge nginx nginx-common nginx-full
sudo -H apt-get install nginx
apt-get --purge remove nginx-*
apt-get install nginx
Try:
sudo aptitude purge nginx && sudo aptitude install nginx
This code will remove and reinstall Nginx
In Plesk panel I get the log error : wget command not found. But there is already wget command installed.
How could I solve this issue ?
cron command: wget -q -O – http://www.example.com/wp-cron.php?doing_wp_cron
This should simple and straight forward. what you need to do is install
On Ubuntu: sudo apt-get install wget
or on Fedora/Redhat/Centos: sudo yum install wget
make sure you have rights to run apt-get install or yum install. After you install wget that error in Plesk should go away. By the way, instead of wget -q -O you can also use cURL as an alternate solution to call your cron script.
04).
I want to use grunt.
I install grunt following this http://gruntjs.com/getting-started
I also installed nodejs.
But when i type the command grunt -h it has no effect and just a new line for a new command !
I try to remove nodejs it output a error like. grunt is not recognize..
Any idea to debug that ?
Many thanks !
I had a problem with my node installation I did:
sudo apt-get --purge remove node
sudo apt-get --purge remove nodejs
sudo apt-get install nodejs
sudo ln -s /usr/bin/nodejs /usr/bin/node
and it solve my problem!
Set up using AWS instance running centOS 6.4 with R and shiny server using my Macbook and trying to figure out what is wrong with it as there are issues with this process
# set up AWS Redhat 6.4 instance (dont forget to download .pem)
# set the .pem file into your ~/.ssh/ folder and make sure you chmod the file
chmod 400 ~/.ssh/myshinypemexample.pem
ssh into machine
ssh -i ~/.ssh/myshinypemexample.pem root#yourPublicDNS
# the first time you run this, just press yes, don't be scared :)
# use ec2-user and log into machine
ssh -i ~/.ssh/myshinypemexample.pem ec2-user#yourPublicDNS
Get the EPEL rpm
wget http://mirror.us.leaseweb.net/epel/6/i386/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm --test
Import the EPEL GPG key
wget https://www.fedoraproject.org/static/0608B895.txt
sudo mv 0608B895.txt /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
sudo rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Verify that the key has been imported.
rpm -qa gpg*
## You should see a line like this: gpg-pubkey-0608b895-4bd22942
Install the rpm
sudo rpm -ivh epel-release-6-8.noarch.rpm
Install shiny server
sudo su - -c "R -e \"install.packages('shiny', repos='http://cran.rstudio.com/')\""
# this gives error and have to install Rcpp and httr manually
wget http://cran.r-project.org/src/contrib/Rcpp_0.11.1.tar.gz
sudo R CMD INSTALL --build Rcpp_0.11.1.tar.gz
wget http://cran.r-project.org/src/contrib/httpuv_1.2.3.tar.gz
sudo R CMD INSTALL --build httpuv_1.2.3.tar.gz
run shiny server again
sudo su - -c "R -e \"install.packages('shiny', repos='http://cran.rstudio.com/')\""
Install Shiny Server
wget http://download3.rstudio.org/centos-5.9/x86_64/shiny-server-1.0.0.42-x86_64.rpm
sudo yum install --nogpgcheck shiny-server-1.0.0.42-x86_64.rpm
# test server
sudo status shiny-server
check location of example shiny app
sudo R -e "system.file('examples/01_hello', package='shiny')"
[1] "/usr/lib64/R/library/shiny/examples/01_hello"
#copy example file from R to /srv as Shiny looks for this location to work
sudo cp -R /usr/lib64/R/library/shiny/examples/01_hello /srv/shiny-server/
MYIP:3838 does not resolve. Why?