tac ~/.bashrc

more ~/.bashrc

head -n 20 ~/.bashrc

head -n 50 ~/.bashrc | tail -n 20

tail -n 20 ~/.bashrc

tail -n +50 ~/.bashrc

touch /tmp/hello
ls -l /tmp/hello

touch -d "5 days ago" /tmp/hello
ls -l /tmp/hello

chown root /tmp/hello
ls -l /tmp/hello

find / -name ".bashrc" 2>/dev/null

mkdir /test
tar -czvf /test.tar.gz /

tar -xzvf /test.tar.gz -C /tmp

echo 'export JAVA_HOME=/export/server/jdk1.8.0_241' >> ~/.bashrc //修改为自己安装的路径

source ~/.bashrc

echo $JAVA_HOME

su - hadoop
cd /usr/local/hadoop
start-dfs.sh
start-yarn.sh

hdfs dfs -mkdir -p /user/hadoop

hdfs dfs -mkdir /user/hadoop/test

hdfs dfs -ls /user/hadoop

hdfs dfs -put ~/.bashrc /user/hadoop/test/

hdfs dfs -ls /user/hadoop/test/

 

hdfs dfs -get /user/hadoop/test /usr/local/hadoop/

 

 

posted on 2023-11-07 09:25  夜的第七章i  阅读(2)  评论(0编辑  收藏  举报