redhat

redhat 7.x主机名修改

*爱你&永不变心* 提交于 2019-12-10 17:09:58
先说一下我之前改主机名怎么改的: 1.修改/etc/hostname文件 2.修改/etc/hosts文件 但是今天改的时候主机名没有变,开始百度执行如下: 1.执行hostnamectl set-hostname AITT_01 2.执行hostnamectlf发现Transient、Static对应的主机名不一样,Transient变成小写aitt_01,Static是大写AITT_01。 现在说一下如何正确修改主机名: 备注:AITT_01是我要修改的主机名 1. hostnamectl 查看,现下的static 和 transient名 2. hostnamectl --static set-hostname AITT_01 3. hostnamectl --transient set-hostname AITT_01 这样执行完,你就可以查看你的主机名改过来了,不需要重启服务器!!!最多把xshell关了,重新登陆一下。可以执行hostname看一下,或者执行hostnamectl 来源: CSDN 作者: TuDestiny 链接: https://blog.csdn.net/TuDestiny/article/details/103477376

IO Error: The Network Adapter could not establish the connection - with Oracle 11gR2. Connecting with SQL developer

坚强是说给别人听的谎言 提交于 2019-12-10 13:38:06
问题 I have installed Oracle 11g ON a RedHat6 linux instance, by following all the steps mentioned in "http://technologylair.net/2013/08/oracle-11g-installation-linux/#comment-50" I am trying to connect to the database from a remote machine using the sql developer. But always ending up with - " IO Error: The Network Adapter could not establish the connection ". The parameters i am using are Username: sys as sysdba Password: <oracle password> Hostname: IP address of the server on which Oracle SQL

Restart service from CGI Script

只愿长相守 提交于 2019-12-10 12:19:27
问题 Im am trying to get a cgi stript run by apache to command service network restart I just put the command in a bash file but I get a permission denied error. #!/bin/bash service network restart Maybe I need a perl solution? 回答1: You could add a rule in sudoers to let your CGI scripts run the script (and nothing else) as root. Edit sudoers using sudo visudo to add this line: apache ALL = NOPASSWD: /path/to/script.sh And then your CGI script will be able to do sudo service network restart

Set preferred listen address in weblogic 11g

自古美人都是妖i 提交于 2019-12-10 12:14:15
问题 I have a WebLogic 11g domain with 1 admin server and 4 managed servers running on 2 machines. Each machine has 3 ip addresses, but only one of those addresses is seen by another machine. Each machine is running a node manager which seems to communicate fine between each other and admin server. Though when managed server starts on the second machine it can't communicate to admin server because it uses wrong ip address. It appears that when weblogic starts it maps itself to all ip addresses,

Error installing matplotlib - python2.7 (RHEL 5.9)

二次信任 提交于 2019-12-10 12:07:08
问题 I have an altinstall of python 2.7 on my RHEL 5.9 desktop (python 2.4 ships with rhel5). I have installed numpy1.7.1 and scipy-0.12.0 successfully from source. However when I try to build matplotlib1.2.1 ( python2.7 setup.py build ) I get the following error message which I am unable to debug ============================================================================ BUILDING MATPLOTLIB matplotlib: 1.2.1 python: 2.7.5 (default, May 16 2013, 15:45:29) [GCC 4.1.2 20080704 (Red Hat 4.1.2-54)]

Offline pip installation

南笙酒味 提交于 2019-12-10 11:01:43
问题 How can I install pip in an offline server? I have SSH access and can send files via scp. The server has Red Hat. I did this https://pip.pypa.io/en/stable/installing.html#install-pip but tries to download something. Is there a way to package pip and all its dependencies, so then I can send that to the server and install it from there? I already did this with python packages that to install with pip. 回答1: Download python-pip yum package. pip RHEL install, yum download package Move it to your

Number of subdirectories in a directory?

拥有回忆 提交于 2019-12-10 10:15:10
问题 How to find the number of subdirectories in a specified directory in HDFS? When I do hadoop fs -ls /mydir/ , I get a Java heap space error, since the directory is too big, but what I am interested in is the number of subdirectories in that directory. I tried: gsamaras@gwta3000 ~]$ hadoop fs -find /mydir/ -maxdepth 1 -type d -print| wc -l find: Unexpected argument: -maxdepth 0 I know that the directory is not empty, thus 0 is not correct: [gsamaras@gwta3000 ~]$ hadoop fs -du -s -h /mydir 737.5

Redhat openshift - Cron Runtime - Is there a default time for how long cron executes

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-10 09:37:34
问题 Cron on Redhat openshift is cancelled by SIGTERM after some minutes. Is there a default timeout on how long cron tasks can execute? If yes, how to get long running tasks working? 回答1: Yes, There is apparently a default timeout of 5 min on top level script for cron tasks execution on Redhat openshift. The solution is to use "nohup" to get long running tasks working. For ex: File .openshift/cron/minutely/task1 - nohup /path-to/some-other-script > $OPENSHIFT_LOG_DIR/logfile 2>&1 & 来源: https:/

[转]linux 启动 oracle

核能气质少年 提交于 2019-12-10 08:51:46
一、如何启动数据库实例 1.进入到sqlplus启动实例 [oracle@redhat ~]$ su - oracle --“切换到oracle用户” Password: [oracle@redhat ~]$ lsnrctl start --“打开监听” LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 14-OCT-2009 19:06:40 Copyright (c) 1991, 2005, Oracle. All rights reserved. Starting /home/oracle/product/10g/bin/tnslsnr: please wait... TNSLSNR for Linux: Version 10.2.0.1.0 - Production System parameter file is /home/oracle/product/10g/network/admin/listener.ora Log messages written to /home/oracle/product/10g/network/log/listener.log Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC2))) Listening

linux上安装nodejs的步骤和注意问题

风流意气都作罢 提交于 2019-12-10 07:46:03
Linux(Ubuntu)下安装NodeJs 安装nodeJS之前,如果没有安装g++及 libssl-dev,则先要安装好,安装方法如下: $ sudo apt-get install g++ $ sudo apt-get install libssl-dev 接下来,就可以下载安装nodeJS了,目前稳定版本为 Node.js 0.6.18,下面是安装步骤: $ wget http://nodejs.org/dist/v0.8.16/node-v0.8.16.tar.gz (根据自己想要的版本修改对应的版本号) $ tar zxvf node-v0.8.16.tar.gz $ ./configure $ make && make install 安装好后,在 控制台下输入: $ node -v v0.8.16 即可看到安装好的nodeJS版本号。 一切就绪后,按照惯例来一个HelloWorld. $ node >console.log(‘Hello World!’); 在redhat上面安装nodejs也是一样的步骤,如果出现 系统没有g++的问题,运行一下 su -c "yum install gcc-c++", 系统就会安装g++,在redhat上面g++是gcc-c++。这一点切记。 来源: oschina 链接: https://my.oschina.net/u