首页 > 系统相关 >Linux change archive mirror All In One

Linux change archive mirror All In One

时间:2023-04-10 12:23:46浏览次数:50  
标签:http apt archive raspberrypi mirror org main debian change

Linux change archive mirror All In One

Linux / Debian / Ubuntu / Raspberry Pi OS

image

$ sudo apt-get update
Hit:1 http://deb.debian.org/debian bullseye InRelease
Get:2 http://security.debian.org/debian-security bullseye-security InRelease [48.4 kB]
Get:3 http://deb.debian.org/debian bullseye-updates InRelease [44.1 kB]
Get:4 http://archive.raspberrypi.org/debian bullseye InRelease [23.6 kB]
Get:5 http://security.debian.org/debian-security bullseye-security/main armhf Packages [232 kB]
Get:6 http://deb.debian.org/debian bullseye-updates/main armhf Packages [12.0 kB]
Get:7 http://deb.debian.org/debian bullseye-updates/main arm64 Packages [12.0 kB]
Get:8 http://archive.raspberrypi.org/debian bullseye/main armhf Packages [316 kB]
Get:9 http://archive.raspberrypi.org/debian bullseye/main arm64 Packages [308 kB]
Get:10 http://security.debian.org/debian-security bullseye-security/main arm64 Packages [232 kB]
Get:11 http://security.debian.org/debian-security bullseye-security/main Translation-en [155 kB]
Fetched 1383 kB in 19s (72.9 kB/s)
Reading package lists... Done

install

# 安装 vim
$ sudo apt-get install vim

# 安装中文输入法 chinese input
$ sudo apt-get install scim-pinyin

# 重启系统
$ sudo reboot
# 或者
$ sudo shutdown -r now

test

# static ip
$ vim dhcpcd.conf

# disk free
$ df
$ df -h
$ df -Th

image

https://www.raspberrypi.com/documentation/computers/configuration.html#configuring-networking-2

https://www.raspberrypi.com/documentation/computers/configuration.html#static-ip-addresses

demos

切换 Linux 镜像源 / 切换 Raspberry Pi 镜像源

$ sudo apt-get update

获取:1 http://archive.raspberrypi.org/debian buster InRelease [32.6 kB]
获取:2 http://raspbian.raspberrypi.org/raspbian buster InRelease [15.0 kB]             
正在读取软件包列表... 完成          
E: 仓库'http://archive.raspberrypi.org/debian buster InRelease'将其'Suite'值从'testing'修改到了'oldstable'
N: 为了让这个仓库能够应用,这必须在更新之前显式接受。更多细节请参阅 apt-secure(8) 手册。
E: 仓库'http://raspbian.raspberrypi.org/raspbian buster InRelease'将其'Suite'值从'stable'修改到了'oldstable'
N: 为了让这个仓库能够应用,这必须在更新之前显式接受。更多细节请参阅 apt-secure(8) 手册。
$ sudo vim /etc/apt/sources.list 

$ sudo cat /etc/apt/sources.list
# new ✅
deb http://mirrors.ustc.edu.cn/raspbian/raspbian/ buster main contrib non-free rpi

# tsinghua 不好使 ❌
# deb http://mirror.tuna.tsinghua.edu.cn/raspberrypi/ stretch main ui
# deb-src http://mirror.tuna.tsinghua.edu.cn/raspberrypi/ stretch main ui

# old ❌
# deb http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi

# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi

$ sudo vim /etc/apt/sources.list.d/raspi.list

$ sudo cat /etc/apt/sources.list.d/raspi.list
# new ✅
deb http://mirrors.ustc.edu.cn/archive.raspberrypi.org/debian/ buster main

# old ❌
#deb http://archive.raspberrypi.org/debian/ buster main

# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://archive.raspberrypi.org/debian/ buster main

USTC Open Source Software Mirror

http://mirrors.ustc.edu.cn/

https://mirrors.ustc.edu.cn/

中国科学技术大学

https://ustc.edu.cn/

获取 IP 通过 SSH 访问 Raspberry Pi

# 获取 IP
$ ping raspberrypi

# SSH, host ✅
$ ssh [email protected]

# SSH, ip ❓
$ ssh [email protected]


image

➜  ~ ping raspberrypi
ping: cannot resolve raspberrypi: Unknown host
➜  ~ ping raspberrypi.local
PING raspberrypi.local (192.168.18.135): 56 data bytes
64 bytes from 192.168.18.135: icmp_seq=0 ttl=64 time=207.268 ms
64 bytes from 192.168.18.135: icmp_seq=1 ttl=64 time=13.262 ms
^C
--- raspberrypi.local ping statistics ---
2 packets transmitted, 2 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 13.262/110.265/207.268/97.003 ms
➜  ~ ssh [email protected]
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the ED25519 key sent by the remote host is
SHA256:RDtJTesQX/nQU+4pRcsqtQFV5kXbdM05U5gppFpG2dU.
Please contact your system administrator.
Add correct host key in /Users/xgqfrms-mm/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /Users/xgqfrms-mm/.ssh/known_hosts:4
Host key for 192.168.18.135 has changed and you have requested strict checking.
Host key verification failed.
➜  ~ ssh [email protected]
[email protected]'s password: 
Permission denied, please try again.
[email protected]'s password: 
Permission denied, please try again.
[email protected]'s password: 
Linux raspberrypi 5.15.84-v8+ #1613 SMP PREEMPT Thu Jan 5 12:03:08 GMT 2023 aarch64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Mon Apr 10 01:38:46 2023

SSH is enabled and the default password for the 'pi' user has not been changed.
This is a security risk - please login as the 'pi' user and type 'passwd' to set a new password.

pi@raspberrypi:~ $ 

(

标签:http,apt,archive,raspberrypi,mirror,org,main,debian,change
From: https://www.cnblogs.com/xgqfrms/p/17301579.html

相关文章

  • git commit 不生成 changeId 解决方案
    1).检查仓储.git/hook下面是否有commit-msg文件,如果没有可以到下面的地址下载,或者把其他同事的commit-msg文件拷贝到你的.git/hook重新commit即可。http://review.cyanogenmod.org/tools/hooks/commit-msghttps://gerrit-review.googlesource.com/tools/hooks/commit-m......
  • UVA - 674 Coin Change 经典问题
    题目大意:给出5中硬币,分别是1,5,10,25,50,然后给你一个数字,能由这五种硬币组成的方式有多少种解题思路:解法一:硬币按小到大排,用j表示还有能用几种硬币表示,则当j==0时,则表示所剩下的值可以用n个1来表示,具体看代码#include<cstdio>constintmaxn=7500;intcoin[5]={1,5,10,25,50};in......
  • 建模copy时报错[lsFrozen Field is not found in the CDO xxxxChanges] 的解决方法
    报错如图  日志报错如下  根据日志内容查找问题原因:由于SetIsFrozen逻辑导致异常。解决办法:重写Maint的SaveAs方法,去掉SetIsFrozen逻辑。  ......
  • HOOPS Exchange助力Shapr3D产品实现了“无障碍的用户体验”
    HOOPSSDK是用于3D工业软件开发的工具包,其中包括4款工具,分别是用于读取和写入30多种CAD文件格式的HOOPSExchange、专注于Web端工程图形渲染的HOOPSCommunicator、用于移动端和PC端工程图形渲染的HOOPSVisualize、支持将3D数据以原生3DPDF、HTML和标准CAD格式进行发布的HOOPS......
  • [FAQ] Pytorch PytorchStreamReader failed reading zip archive
     比如:rm-rf~/.cache/huggingface  Link:https://www.cnblogs.com/farwish/p/17290240.html......
  • 使用PowerShell 连接Exchange及Lync/Skype服务器
    需求背景在运维Exchange/Lync/Skype时,我们经常会遇到需要创建很多自动化任务来代替我们完成重复的工作,就需要能够使用脚本连接至对应应用服务器进行自动化处理。此时我们可以使用PowerShell的方式来完成。那么我们应该如何连接到对应服务器呢?操作步骤创建PowerShell.ps1脚本:$UserC......
  • Your local changes to the following files would be overwritten by merge问题的解
    问题描述在终端页面输入gitpull,会出现这样一个报错:Yourlocalchangestothefollowingfileswouldbeoverwrittenbymerge;然后一开始没有注意到这个错误跟之前的错误不太一样,就还是按照之前的套路来的,没有解决问题解决发现这样就可以解决啦:gitstashgitpull这样就......
  • CodeMirror 基础配置指南
    CodeMirror基础配置指南需求背景在线编辑项目引入列表页面加载页面内容在线编辑页面在线编辑内容保存需求背景这里为什么会用到在线编辑功能呢?有这样的一个文件管理系统,实时上传js、css、html、shtml、txt等格式文件及文件夹,但是有时候发现上传的文件内容上有不对的地方,如果按传统......
  • git pull遇到错误:error: Your local changes to the following files would be overwr
    error:Yourlocalchangestothefollowingfileswouldbeoverwrittenbymerge:意思是我台式机上新修改的代码的文件,将会被git服务器上的代码覆盖;我当然不想刚刚写的代码被覆盖掉,看了git的手册,发现可以这样解决:方法1:如果你想保留刚才本地修改的代码,并把git服务器上的代码pu......
  • Cannot download Packages/expat-devel-2.2.5-4.el8.x86_64.rpm: All mirrors were tr
    错误原因从错误可以看出无法下载此包,因为所有镜像都已经尝试过了。可能是因为该软件包不再可用或镜像服务器当前不可用。解决方法因为CENTOS8自带rpm,所以就不需要下载rpm了。检查依赖包是否安装:(这步可忽略)rpm-qmakeautoconfautomakecmakeperl-CPANlibcurl-develli......