centos7

Bash Centos7 “which” command

佐手、 提交于 2019-12-23 07:29:34
问题 I realize this might be a dumb question but I have a Centos-7 minimal server install and the "which" command does not exist or is missing. I have a script that needs it and I cannot find out what the yum package is that installs it. The code is below and is from a make file. which grep > /dev/null 2> /dev/null if test "$?" != "0" then echo "\"grep\" command not found." echo "Installation is aborted." exit 1 fi Any help would be appreciated... this is difficult if not impossible to google 回答1:

git-http-backend with apache2.4 Centos 7

一笑奈何 提交于 2019-12-23 03:05:14
问题 I try to set up a Git-server on my apache server but it dont work! I got the following git.conf SetEnv GIT_PROJECT_ROOT /var/www/html/git/project1 SetEnv GIT_HTTP_EXPORT_ALL ScriptAlias /git/ /usr/libexec/git-core/git-http-backend/ <Directory "/var/www/html/git/project1"> Options ExecCGI Indexes Require all granted </Directory> <LocationMatch "^/git/.*/git-receive-pack$"> AuthType Basic AuthName "Git Access" AuthUserFile /var/www/html/git/users/.htpasswd Require valid-user </LocationMatch> I

How to enable regular linux users to access postgres database without sudo access?

℡╲_俬逩灬. 提交于 2019-12-23 01:45:11
问题 We have a postgres database server(10.3) installed on Centos7, and created a database with the name of "db_name". We have database access. The setting in pg_hba.conf is as the following: # "local" is for Unix domain socket connections only local all all trust host all all 127.0.0.1/32 trust host all all ::1/128 trust local replication all peer host replication all 127.0.0.1/32 ident host replication all ::1/128 ident When I have sudo access, I can access the database "db_name". [root

centos 7 get latest apache package

十年热恋 提交于 2019-12-22 22:18:11
问题 This question comes from my lack of understanding of package managers, I run yum list and get httpd-2.4.6-40.el7.centos.4.x86_64 https://rpmfind.net/linux/RPM/centos/updates/7.2.1511/x86_64/Packages/httpd-2.4.6-40.el7.centos.4.x86_64.html Build date: Mon Jul 18 17:32:11 2016 I did yum update && yum install httpd , will this get me the latest version of httpd? where can I check online to confirm my package/build is the latest? how can I periodically install security patches for my version of

Execute an external BLAST program in PHP

痴心易碎 提交于 2019-12-22 13:59:14
问题 I want to execute a blastx search application in PHP instead of Linux console text terminal. The actual command line arguments would be (see definition of refer): ./blastx -query $input -db ${Sbjct}_db -evalue 0.0001 -outfmt 6 -out /path/to/output.tsv Here's my PHP partial code. exec(' /path/to/blastx -query /path/to/PAO1.fasta -db /path/to/VFDB_setB_pro -evalue 0.0001 -outfmt 6 -out /path/to/output.tsv '); However, when I call exec() function in PHP program there is nothing happened. I also

Centos 7 - where is jfx library for openjdk8?

夙愿已清 提交于 2019-12-22 11:18:58
问题 I have centos 7.1. And I installed openjdk8 and openjdk-devel8. However, when I tried to compile in netbeans my jfx application I get package javafx.* does not exist. After some investigation I see that there is no jfxrt.jar in jdk. Besides [root@localhost ext]# yum provides jfxrt.jar Loaded plugins: fastestmirror, langpacks Loading mirror speeds from cached hostfile * base: mirror.astpage.ru * epel: epel.besthosting.ua * extras: mirror.astpage.ru * nux-dextop: mirror.li.nux.ro * updates:

ansible yum not working

China☆狼群 提交于 2019-12-22 09:19:30
问题 when i run command on the ops machine: ansible web -b -l 192.168.31.101 -m yum -a "name=gcc state=latest" it returns error shows below: 192.168.31.101 | FAILED! => { "changed": false, "failed": true, "msg": "python2 bindings for rpm are needed for this module. python2 yum module is needed for this module" } but when i execute the command sudo yum install gcc directly on 192.168.31.101 , executed properly. it seems like ansible can't use the right yum and python 回答1: I find the solution, just

Error executing Puppeteer from PHP

走远了吗. 提交于 2019-12-22 00:20:00
问题 I have a node script which converts a webpage into a PDF document. The user enters some content and PHP builds a HTML page, which then is used in a node script (that runs Puppeteer, using a slightly modified version of an example script) to convert it to PDF. But when I exec in PHP the command to run the node script, it fails with the following error: (node:14832) UnhandledPromiseRejectionWarning: Error: Failed to launch chrome! [0424/165455.239499:ERROR:icu_util.cc(133)] Invalid file

PostgreSQL “initdb” (Database Initialization) on Linux

若如初见. 提交于 2019-12-21 14:35:08
问题 I'm working on creating a Database Cluster (single database) in PostgreSQL 9.x working on a Linux system (CentOS - RedHat - Fedora). I've installed the correct PostgreSQL packages (server & client) however, I'm unable to create a database and get some type of initializing dependencies error: Bus Error / Exit Code 135 . I've changed my user to "postgres" with "su postgres" and then tried to initialize the database with "initdb" (this may be the problem) Installed: postgresql-libs-9.2.13-1.el7

How to change docker daemon root directory in CentOS7

こ雲淡風輕ζ 提交于 2019-12-21 04:58:21
问题 I am running docker in CentOS7. I'd like to change my basic directory from /var/lib/docker to /data/docker . I found this guide from official site, but do not know how to apply this to my case. I just make new daemon.json in /etc/docker/ . After that when I am trying to run daemon occurs an error. follow is systemctl status -l docker.service . ● docker.service - Docker Application Container Engine Loaded: loaded (/usr/lib/systemd/system/docker.service; disabled; vendor preset: disabled)