1.安装ssh-server
sudo apt-get install openssh-server
启动:
sudo /etc/init.d/ssh start
检查:
ps -e|grep ssh
配置文件路径:/etc/ssh/sshd_config
<转载>
无与伦比的Ubuntu已经走到了12.04 LTS版本,现在情况是默认给这个系统安装的是Java 7,同时sun的字样从java旁边消失并且换成了Oracle了,Ailisen看到肯定很开心了!
就为了这个他也觉得值得从java6走到java7值得,别当真,调侃一下,java6和java7 还是变化真有不少。
但是我们现在如日中天的Android 4.0的编译和CTS测试还是用 java6
下面我就把在Ubuntu12.04安装java6的方法公布一下:
1. 在/etc/apt/sources.list 末尾加上如下行:
###for install Java6
deb http://ppa.launchpad.net/ferramroberto/java/ubuntu natty main
2. sudo apt-get update
更新索引时候提示:
W: GPG 错误:http://ppa.launchpad.net natty Release: 由于没有公钥,无法验证下列签名: NO_PUBKEY B725097B3ACC3965
3. 下载安装这个key
sudo apt-key adv --recv-key --keyserver keyserver.ubuntu.com B725097B3ACC3965
4. sudo apt-get update
5. sudo apt-get install sun-java6-jdk sun-java6-jre
(2)配置环境变量
输入命令:
- sudo gedit /etc/profile
输入密码,打开profile文件。
在文件的最下面输入如下内容:
- #set Java Environment
- export JAVA_HOME= (你的JDK安装位置,一般为/usr/lib/jvm/java-6-sun)
- export CLASSPATH=".:$JAVA_HOME/lib:$CLASSPATH"
- export PATH="$JAVA_HOME/:$PATH"
这一步的意义是配置环境变量,使你的系统可以找到JDK。
(3)验证JDK是否安装成功
输入命令:
- java -version
查看信息:
- java version "1.6.0_14"
- Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
- Java HotSpot(TM) Server VM (build 14.0-b16, mixed mode)
下载hadoop:
http://mirror.esocc.com/apache/hadoop/common/hadoop-2.2.0/hadoop-2.2.0.tar.gz
用官方的Hadoop 2.1.0-beta安装后,每次hadoop命令进去都会抛出这样一个Warning
WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
设置logger级别,看下具体原因
- 13/08/29 13:59:38 DEBUG util.NativeCodeLoader: Trying to load the custom-built native-hadoop library...
- 13/08/29 13:59:38 DEBUG util.NativeCodeLoader: Failed to load native-hadoop with error: java.lang.UnsatisfiedLinkError: /usr/local/hadoop/hadoop-2.1.0-beta/lib/native/libhadoop.so.1.0.0: /usr/local/hadoop/hadoop-2.1.0-beta/lib/native/libhadoop.so.1.0.0: wrong ELF class: ELFCLASS32 (Possible cause: architecture word width mismatch)
- 13/08/29 13:59:38 DEBUG util.NativeCodeLoader: java.library.path=/usr/local/hadoop/hadoop-2.1.0-beta/lib/native/Linux-amd64-64:/usr/local/hadoop/hadoop-2.1.0-beta/lib/native
- 13/08/29 13:59:38 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
- file *
- libhadoop.a: current ar archive
- libhadooppipes.a: current ar archive
- libhadoop.so: symbolic link to `libhadoop.so.1.0.0'
- libhadoop.so.1.0.0: ELF 64-bit LSB shared object, x86-64, version 1 (GNU/Linux), dynamically linked, not stripped
- libhadooputils.a: current ar archive
- libhdfs.a: current ar archive
- libhdfs.so: symbolic link to `libhdfs.so.0.0.0'
- libhdfs.so.0.0.0: ELF 64-bit LSB shared object, x86-64, version 1 (GNU/Linux), dynamically linked, not stripped
本文链接http://blog.csdn.net/lalaguozhe/article/details/10361367 ,转载请注明
ubuntu 下 maven安装
手动安装maven2
1,手动安装maven包从http://maven.apache.org/download.html 官网下载apache-maven-2.2.1-bin.tar.gz 包;
2,解压 tar -zvxf apache-maven-2.2.1-bin.tar.gz 到/opt/cody下
3,建立软链接,方便以后maven升级ln -s /opt/cody/apache-maven-2.2.1/ /opt/cody/maven
4,配置环境变量
export M2_HOME=/opt/cody/maven
export PATH=$PATH:$M2_HOME/bin
或者修改vi /etc/profile 上面两句
5,检验是否安装成功mvn -version
命令安装
1,apt-get install maven2
2,确认是否安装成功
mvn -version
3,查看安装目录
find / -name maven2
Maven主目錄:/usr/share/maven2
Maven 配置文件:/etc/maven2