1.can not use ifconfig

http://blog.csdn.net/zjt289198457/article/details/6918644

add this : export PATH=$PATH:/sbinc

at the end of file /etc/profile

and then execute : source /etc/profile to make the change effect

2.change to static ip
http://wkm.iteye.com/blog/1308528
2.1 change hostname to hadoop

NETWORKING=yes
NETWORKING_IPV6=no
HOSTNAME=hadoop

2.2  Change ip address and Gateway

path:/etc/sysconfig/network-scripts/ifcfg-eth0

old file:

# Intel Corporation 82545EM Gigabit Ethernet Controller (Copper)

DEVICE=eth0
BOOTPROTO=none
HWADDR=00:0c:29:d3:48:0e
ONBOOT=yes
NETMASK=255.255.0.0
IPADDR=172.27.35.222
GATEWAY=172.27.35.1
TYPE=Ethernet

new file

# Intel Corporation 82545EM Gigabit Ethernet Controller (Copper)
DEVICE=eth0
BOOTPROTO=none
HWADDR=00:0c:29:d3:48:0e
ONBOOT=yes
NETMASK=255.255.0.0
IPADDR=192.168.1.10
GATEWAY=192.168.1.100
TYPE=Ethernet

restart server :

ifdown ech0

ifup ech0  [same function : service network restart]

4.change hostname

hostname show host name

hostname hadoop --change one time

permenet change :

change file /etc/sysconfig/network

[root@localhost sysconfig]# cat network
NETWORKING=yes
NETWORKING_IPV6=no
HOSTNAME=hadoop

5.ip bind with hostname

vi /etc/hosts

add a line :192.168.1.10  hadoop

6.close firewall

6.1.server iptable status

  [root@hadoop etc]# service iptables status Table: filter Chain INPUT (policy ACCEPT) num  target     prot opt source               destination         1    RH-              Firewall-1-INPUT  all  --  0.0.0.0/0            0.0.0.0/0

  Chain FORWARD (policy ACCEPT) num  target     prot opt source               destination         1    RH-Firewall-1-INPUT  all  --  0.0.0.0/0

0.0.0.0/0

Chain OUTPUT (policy ACCEPT) num  target     prot opt source               destination

6.2 service iptables start/stop

iptables {start|stop|restart|condrestart|status|panic|save}

7.check firewall server is run or not

7.1  grep iptables server's status

[root@hadoop etc]# chkconfig --list |grep iptables
      iptables        0:off   1:off   2:on    3:on    4:on    5:on    6:off

7.2 close all firewall's service  and check status

[root@hadoop etc]# chkconfig iptables off
[root@hadoop etc]# chkconfig --list |grep iptables
iptables        0:off   1:off   2:off   3:off   4:off   5:off   6:off
[root@hadoop etc]#

Linux questions的更多相关文章

  1. 系统学习Linux建议

    国内的专业Linux网站(GB) ChinaUnix Linux中国 实验楼: 免费提供了Linux在线实验环境,不用在自己机子上装系统也可以学习Linux,超方便实用!. 国内的专业Linux网站( ...

  2. Linux 驱动开发

    linux驱动开发总结(一) 基础性总结 1, linux驱动一般分为3大类: * 字符设备 * 块设备 * 网络设备 2, 开发环境构建: * 交叉工具链构建 * NFS和tftp服务器安装 3, ...

  3. [C++] Pen questions & linux cmd

    1.宏替换,完全展开替换,注意带来副作用 #include <stdio.h>#define 打印语句 printf(“hello”); Void main(void) { If (1) ...

  4. Linux监控工具介绍系列——OSWatcher Black Box

      OSWatcher Balck Box简介 OSWatcher Black Box (oswbb)是Oracle开发.提供的一个小巧,但是实用.强大的系统工具,它可以用来抓取操作系统的性能指标,用 ...

  5. Linux Distribution / ROM

    Linux发行版 http://unix.stackexchange.com/questions/87011/how-to-easily-build-your-own-linux-distro 这个文 ...

  6. Linux下的几个好用的命令与参数

    将所有文件的编码,转换为UTF-8 find . ! -type d -exec enca -L zh_CN -x UTF-8 {} \; 将指定目录下所有文件权限设定为644 find . ! -t ...

  7. Linux中SysRq的使用(魔术键)

    转:http://www.chinaunix.net/old_jh/4/902287.html 魔术键:Linux Magic System Request Key Hacks 当Linux 系统不能 ...

  8. [转载] 构造linux 系统下免密码ssh登陆  _How to establish password-less login with SSH

    In present (post production) IT infrastructure many different workstations, servers etc. have to be ...

  9. LInux MySQL 端口验证

    linux suse11在terminal可以正常登录进行各种操作,在tomcat运行jdbc web程序异常: com.mysql.jdbc.exceptions.jdbc4.Communicati ...

随机推荐

  1. Android中的Intent详解

    前言: 每个应用程序都有若干个Activity组成,每一个Activity都是一个应用程序与用户进行交互的窗口,呈现不同的交互界面.因为每一个Acticity的任务不一样,所以经常互在各个Activi ...

  2. Swift 玩转 3D Touch 之 Peek & Pop

    什么是3D Touch 3D Touch 是iOS9之后专为 iPhone6s 机型加入的新特性,这一新技术移植于 Mac Book 上的 ForceTouch 更准确地说应该是 ForceTouch ...

  3. SQL替换语句之批量修改、增加、删除字段内容

    语法 REPLACE ( original-string, search-string, replace-string ) 用法 update 表的名称 set 替换字段=REPLACE(替换字段,原 ...

  4. 温故知新---重读C#InDepth(二)

    一本好书,或是一本比较有深度的书,就是每次研读的时候都会有新的发现. 好吧,我承认每次读的时候都有泛泛而过的嫌疑~~ 这几年一直专注于C#客户端的开发,逐步从迷迷糊糊,到一知半解,再到自以为是,最后沉 ...

  5. HOW TO REMOTELY DEBUG APPLICATION RUNNING ON TOMCAT FROM WITHIN INTELLIJ IDEA

    This post would look into how to tackle and debug issues in scenarios where they only occur in produ ...

  6. 小心as"陷阱"(c#)

    有一种情况,使用as编译时没错,运行时也没错,但是结果错了. object a=1; string b=a as String; 由于a是objecy类型,是引用类型,所以可以用as转换,但是实际上b ...

  7. 用form表单实现Ajax---post提交

    实例讲解:新闻发布实现无刷新上传,显示 html代码: 注意:文本框中并没有id  ,,只有name.jquery获取每个文本框的值还要在拼写提交格式(id=value&name=value& ...

  8. xcode7 __weak 导致报错 is unavailable

    Build Settings Apple LLVM7.1 Laguage-Object-c Weak References in Manual Retain Release 选 Yes;

  9. Java基础-String、StringBuffer、StringBuilder

    看下面这段代码: public class Main { public static void main(String[] args) { String string = ""; ...

  10. jquery操作滚动条滚动到指定位置

    <html><head><script type="text/javascript" src="/jquery/jquery.js" ...