type
status
date
slug
summary
tags
category
icon
password
https://cloud.google.com/vertex-ai?hl=zh_cnhttps://console.cloud.google.com/compute/https://console.cloud.google.com/welcome
1、先选择从浏览器打开ssh连接服务器
2、切换到root账号,输入代码:sudo -i
3、设置root密码,输入代码:passwd
然后会要求输入新密码,然后再重复一次密码,输入密码的时候不会显示出来,所以直接输入密码,然后回车,再然后重复输入密码回车
开启SSH权限
1、CentOS和Debian通用,输入以下两条命令
sed -i 's/PermitRootLogin no/PermitRootLogin yes/g' /etc/ssh/sshd_config
sed -i 's/PasswordAuthentication no/PasswordAuthentication yes/g' /etc/ssh/sshd_config
2、Ubuntu系统,输入以下两条命令
sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/g' /etc/ssh/sshd_config
sed -i 's/PasswordAuthentication no/PasswordAuthentication yes/g' /etc/ssh/sshd_config
3、重启服务器,输入命令:reboot
地区 子网
africa-south1 10.218.0.0/20
asia-east1 10.140.0.0/20
asia-east2 10.170.0.0/20
asia-northeast1 10.146.0.0/20
asia-northeast2 10.174.0.0/20
asia-northeast3 10.178.0.0/20
asia-south1 10.160.0.0/20
asia-south2 10.190.0.0/20
asia-southeast1 10.148.0.0/20
asia-southeast2 10.184.0.0/20
australia-southeast1 10.152.0.0/20
australia-southeast2 10.192.0.0/20
europe-central2 10.186.0.0/20
europe-north1 10.166.0.0/20
europe-southwest1 10.204.0.0/20
europe-west1 10.132.0.0/20
europe-west10 10.214.0.0/20
europe-west12 10.210.0.0/20
europe-west2 10.154.0.0/20
europe-west3 10.156.0.0/20
europe-west4 10.164.0.0/20
europe-west6 10.172.0.0/20
europe-west8 10.198.0.0/20
europe-west9 10.200.0.0/20
me-central1 10.212.0.0/20
me-central2 10.216.0.0/20
me-west1 10.208.0.0/20
northamerica-northeast1 10.162.0.0/20
northamerica-northeast2 10.188.0.0/20
southamerica-east1 10.158.0.0/20
southamerica-west1 10.194.0.0/20
us-central1 10.128.0.0/20
us-east1 10.142.0.0/20
us-east4 10.150.0.0/20
us-east5 10.202.0.0/20
us-south1 10.206.0.0/20
us-west1 10.138.0.0/20
us-west2 10.168.0.0/20
us-west3 10.180.0.0/20
us-west4 10.182.0.0/20
下面这个是GCP网卡IPV4和IPV6的设置代码
gcloud compute networks create gcp --project=education-440804 --subnet-mode=custom --mtu=1460 --enable-ula-internal-ipv6 --bgp-routing-mode=regional --bgp-best-path-selection-mode=legacy && gcloud compute networks subnets create gcp-us-central1 --project=education-440804 --range=10.128.0.0/20 --stack-type=IPV4_IPV6 --ipv6-access-type=EXTERNAL --network=gcp --region=us-central1 && gcloud compute networks subnets create gcp-asia-east1 --project=education-440804 --range=10.140.0.0/20 --stack-type=IPV4_IPV6 --ipv6-access-type=EXTERNAL --network=gcp --region=asia-east1 && gcloud compute networks subnets create gcp-africa-south1 --project=education-440804 --range=10.218.0.0/20 --stack-type=IPV4_IPV6 --ipv6-access-type=EXTERNAL --network=gcp --region=africa-south1 && gcloud compute networks subnets create gcp-asia-east2 --project=education-440804 --range=10.170.0.0/20 --stack-type=IPV4_IPV6 --ipv6-access-type=EXTERNAL --network=gcp --region=asia-east2 && gcloud compute networks subnets create gcp-australia-southeast1 --project=education-440804 --range=10.152.0.0/20 --stack-type=IPV4_IPV6 --ipv6-access-type=EXTERNAL --network=gcp --region=australia-southeast1
- 作者:Luck
- 链接:https://enblog.top/article/1d9fd5c7-85f7-4d5c-85dd-084f7cd71588
- 声明:本文采用 CC BY-NC-SA 4.0 许可协议,转载请注明出处。