半夜起来看世界杯,没啥激情,但是又怕错误意大利和英格兰的比赛,就看了rhel7 相关新功能的介绍。     rhel7的下载地址: https://access.redhat.com/site/downloads/        安装还算顺利,安装的界面比以前简洁的多,很清爽,分类很是明确。      有些奇怪的是,我安装的时候,怕有些基础的包没有装上去,所以选定了mini和Web的类型,结果还是有些基础的包没有安装,比如 ifconfig 。     虚拟机的网卡,被识别为ens,有意思。     
 
 yum groupinstall Base 这样的话,就可以把一些基础的包打上。可以正常的时候ifconfig lsof  。  这里需要说明的是,redhat7的测试的repo源貌似不能用,我跟着地址看了下。压根就没有,我想应该还是测试版的原因吧。 直接mount /dev/cdrom /mnt用的。 [rhel-iso]
name=Red Hat Enterprise Linux 7
baseurl=file:///mnt/
enabled=1[root@localhost ~]# df -T
文件系统        类型   1K-blocks  已用   可用 已用% 挂载点
/dev/mapper/rhel-root xfs     39262208 3591304 35670904   10% /
devtmpfs        devtmpfs  500772     0   500772  0% /dev
tmpfs         tmpfs     507508     0   507508  0% /dev/shm
tmpfs         tmpfs     507508  2604   504904  1% /run
tmpfs         tmpfs     507508     0   507508  0% /sys/fs/cgroup
/dev/sda1       xfs     494940   95444   399496   20% /boot发现rhel7的开发软件版本不低。 python 是2.7.5的了,和ubuntu一样。  java默认也给你装上了。perl在centos6应该是5.10的 ,现在更新到了5.16.3 。 至于为什么更新到perl6,估计和python3一样吧。 [root@localhost ~]# 
[root@localhost ~]# 
[root@localhost ~]# python -V
Python 2.7.5
[root@localhost ~]# java -version
java version "1.7.0_45"
OpenJDK Runtime Environment (rhel-2.4.3.4.el7-x86_64 u45-b15)
OpenJDK 64-Bit Server VM (build 24.45-b08, mixed mode)
[root@localhost ~]# 
[root@localhost ~]# 
[root@localhost ~]# perl -v    
This is perl 5, version 16, subversion 3 (v5.16.3) built for x86_64-linux-thread-multi
(with 24 registered patches, see perl -V for more detail)想安装pip但是iso没有python-pip这个包。rhel7的官方源又打不开,郁闷。本来打算用epel6试试,用不了,到epel官网一瞅。epel居然已经有对于rhel7的源了。 
 
 原文:http://rfyiamcool.blog.51cto.com/1030776/1426550  [root@localhost ~]# lmi -h 10.10.10.71
lmi> hwinfo
username: pegasus
password: 
error   : Failed to make a connection to "10.10.10.71": (0, 'Socket error: [Errno 113] No route to host')
error   : No successful connection made.
lmi> 
lmi> 
lmi>lmi -h ${hostname}
lmi> help
...
lmi> sw search django
...
lmi> sw install python-django
...
lmi> exit# CentOS 6.4
service httpd (start|stop)
# rhel7
systemctl (start|stop) httpd.service
# CentOS 6.4
chkconfig httpd (on|off)
# rhel7
systemctl (enable|disable) httpd.service
$ cat /usr/lib/systemd/system/httpd.service
[Unit]
Description=The Apache HTTP Server
After=network.target remote-fs.target nss-lookup.target
[Service]
Type=notify
EnvironmentFile=/etc/sysconfig/httpd
ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND
ExecReload=/usr/sbin/httpd $OPTIONS -k graceful
ExecStop=/usr/sbin/httpd $OPTIONS -k graceful-stop
# We want systemd to give httpd some time to finish gracefully, but still want
# it to kill httpd after TimeoutStopSec if something went wrong during the
# graceful stop. Normally, Systemd sends SIGTERM signal right after the
# ExecStop, which would kill httpd. We are sending useless SIGCONT here to give
# httpd time to finish.
KillSignal=SIGCONT
PrivateTmp=true
[Install]
WantedBy=multi-user.target[root@localhost ~]# chkconfig --list|grep samba    
注意:该输出结果只显示 SysV 服务,并不包含原生 systemd 服务。SysV 配置数据可能被原生 systemd 配置覆盖。 
    如果您想列出 systemd 服务,请执行 'systemctl list-unit-files'。
    欲查看对特定 target 启用的服务请执行
    'systemctl list-dependencies [target]'。
[root@localhost ~]# 
[root@localhost ~]# 
[root@localhost ~]# systemctl list-dependencies samba 
samba.service
[root@localhost ~]#[root@localhost ~]# 原文:http://rfyiamcool.blog.51cto.com/1030776/1426550 
[root@localhost ~]# yum -y install mysql
已加载插件:langpacks, product-id, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
file:///mnt/repodata/repomd.xml: [Errno 14] curl#37 - "Couldn't open file /mnt/repodata/repomd.xml"
正在尝试其它镜像。
软件包 1:mariadb-5.5.33a-3.el7.x86_64 已安装并且是最新版本
无须任何处理
[root@localhost ~]# 
[root@localhost ~]# 
[root@localhost ~]# yum -y install mysql-server
已加载插件:langpacks, product-id, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
file:///mnt/repodata/repomd.xml: [Errno 14] curl#37 - "Couldn't open file /mnt/repodata/repomd.xml"
正在尝试其它镜像。
正在解决依赖关系
--> 正在检查事务
---> 软件包 mariadb-galera-server.x86_64.1.5.5.37-2.el7 将被 安装
--> 正在处理依赖关系 mariadb-galera-common(x86-64) = 1:5.5.37-2.el7,它被软件包 1:mariadb-galera-server-5.5.37-2.el7.x86_64 需要
--> 正在处理依赖关系 galera >= 25.3.3,它被软件包 1:mariadb-galera-server-5.5.37-2.el7.x86_64 需要
--> 正在处理依赖关系 perl-DBI,它被软件包 1:mariadb-galera-server-5.5.37-2.el7.x86_64 需要
--> 正在处理依赖关系 perl-DBD-MySQL,它被软件包 1:mariadb-galera-server-5.5.37-2.el7.x86_64 需要
--> 正在处理依赖关系 perl(DBI),它被软件包 1:mariadb-galera-server-5.5.37-2.el7.x86_64 需要
--> 正在检查事务
---> 软件包 galera.x86_64.0.25.3.5-5.el7 将被 安装
--> 正在处理依赖关系 nmap-ncat,它被软件包 galera-25.3.5-5.el7.x86_64 需要
---> 软件包 mariadb-galera-common.x86_64.1.5.5.37-2.el7 将被 安装
---> 软件包 perl-DBD-MySQL.x86_64.0.4.023-2.el7 将被 安装
---> 软件包 perl-DBI.x86_64.0.1.627-1.el7 将被 安装
--> 正在处理依赖关系 perl(RPC::PlClient) >= 0.2000,它被软件包 perl-DBI-1.627-1.el7.x86_64 需要
--> 正在处理依赖关系 perl(RPC::PlServer) >= 0.2001,它被软件包 perl-DBI-1.627-1.el7.x86_64 需要
--> 正在检查事务
---> 软件包 nmap-ncat.x86_64.2.6.40-2.el7 将被 安装
---> 软件包 perl-PlRPC.noarch.0.0.2020-12.el7 将被 安装
--> 正在处理依赖关系 perl(Net::Daemon) >= 0.13,它被软件包 perl-PlRPC-0.2020-12.el7.noarch 需要
--> 正在处理依赖关系 perl(Net::Daemon::Log),它被软件包 perl-PlRPC-0.2020-12.el7.noarch 需要
--> 正在处理依赖关系 perl(Net::Daemon::Test),它被软件包 perl-PlRPC-0.2020-12.el7.noarch 需要
--> 正在检查事务
---> 软件包 perl-Net-Daemon.noarch.0.0.48-4.el7 将被 安装
--> 解决依赖关系完成
依赖关系解决
======================================================================================================================================
 Package                 架构           版本                 源              大小
======================================================================================================================================
正在安装:
 mariadb-galera-server           x86_64           1:5.5.37-2.el7           epel            11 M
为依赖而安装:
 galera                  x86_64           25.3.5-5.el7             epel             1.1 M
 mariadb-galera-common           x86_64           1:5.5.37-2.el7           epel             212 k
 nmap-ncat                 x86_64           2:6.40-2.el7             rhel-iso           198 k
 perl-DBD-MySQL              x86_64           4.023-2.el7            rhel-iso           140 k
 perl-DBI                x86_64           1.627-1.el7            rhel-iso           801 k
 perl-Net-Daemon             noarch           0.48-4.el7             rhel-iso          51 k
 perl-PlRPC                noarch           0.2020-12.el7