ubuntu 18.04安装hdp 3.1.0最新完整版(含安装包)

节点准备

hostname ip 角色
ubuntu-1804-1 172.21.73.53 从节点
ubuntu-1804-2 172.21.73.54 主节点
ubuntu-1804-3 172.21.73.55 从节点

关闭防火墙

sudo ufw disable

配置时钟同步NTP

所有节点安装ntp

sudo apt install ntp

以ubuntu-1804-2为server,在ubuntu-1804-2进行如下修改

修改配置文件vim /etc/ntp.conf,将下述配置注释

#pool 0.ubuntu.pool.ntp.org iburst
#pool 1.ubuntu.pool.ntp.org iburst
#pool 2.ubuntu.pool.ntp.org iburst
#pool 3.ubuntu.pool.ntp.org iburst

#pool ntp.ubuntu.com

进行如下配置,将“restrict default nomodify notrap noquery”这行修改成

restrict default nomodify notrap
restrict 172.21.73.0 mask 255.255.255.0

ubuntu-1804-1和ubuntu-1804-3同样注释下述配置,

#pool 0.ubuntu.pool.ntp.org iburst
#pool 1.ubuntu.pool.ntp.org iburst
#pool 2.ubuntu.pool.ntp.org iburst
#pool 3.ubuntu.pool.ntp.org iburst

#pool ntp.ubuntu.com

新增

server ubuntu-1804-2 prefer

启动ntp服务

systemctl enable ntp
systemctl start ntp

开启使用root登陆

使用普通用户进入root用户

sudo su

设置root密码

passwd root

修改配置

vim /etc/ssh/sshd_config

新增如下配置:

PermitRootLogin yes

重启ssh

systemctl restart sshd

配置免密登录

ubuntu-1804-2可以免密登陆ubuntu-1804-1、ubuntu-1804-2、ubuntu-1804-3

三台机器均执行如下操作:

root@ubuntu-1804-2:~# ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa): 
Enter passphrase (empty for no passphrase): 
Enter same passphrase again: 
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256:2MRn3ranRz0AFjMqx1t3Qk5QibTnPrw+zR9MY9ftu6s root@ubuntu-1804-3
The key's randomart image is:
+---[RSA 2048]----+
|          .*=+.  |
|       .. .+B.   |
|       .o++o.= . |
|       +o+o.+.o o|
|      . S.. o..=+|
|           .o.=o+|
|            .=+oo|
|             ++oo|
|            oEo+=|
+----[SHA256]-----+

在ubuntu-1804-2中进入root用户,执行如下命令,提示输入root密码,请输入root密码:

ssh-copy-id ubuntu-1804-1
ssh-copy-id ubuntu-1804-2
ssh-copy-id ubuntu-1804-3

至此,ubuntu-1804-2可以用root用户成功免密登陆ubuntu-1804-1、ubuntu-1804-2、ubuntu-1804-3

mysql安装

sudo apt install mysql-server mysql-client
sudo systemctl enable mysql
sudo systemctl start mysql

默认账号密码在文件/etc/mysql/debian.cnf 中

ubuntu@ubuntu-1804-2:/etc/apt/sources.list.d$ sudo cat /etc/mysql/debian.cnf 
# Automatically generated for Debian scripts. DO NOT TOUCH!
[client]
host     = localhost
user     = debian-sys-maint
password = 0cBYq68fUGyFCpPw
socket   = /var/run/mysqld/mysqld.sock
[mysql_upgrade]
host     = localhost
user     =
  • 0
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 3
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

BigDataToAI

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值