Linux系统之网络客户端工具

简介: Linux系统之网络客户端工具

一、Links工具

1.Links工具介绍

Linux有一款自带的文本互联网浏览器:links,可以浏览简单网页,及测试网络端口连通性。

2.安装Links软件

通过yum安装links软件包。

[root@jeven ~]# yum -y install links
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
epel/x86_64/metalink                                                                                                                           | 6.6 kB  00:00:00     
 * base: mirrors.163.com
 * epel: mirrors.tuna.tsinghua.edu.cn
 * extras: mirrors.163.com
 * updates: mirrors.163.com
base                                                                                                                                           | 3.6 kB  00:00:00     
docker-ce-stable                                                                                                                               | 3.5 kB  00:00:00     
epel                                                                                                                                           | 4.7 kB  00:00:00     
extras                                                                                                                                         | 2.9 kB  00:00:00     
updates                                                                                                                                        | 2.9 kB  00:00:00     
(1/4): docker-ce-stable/7/x86_64/primary_db                                                                                                    |  93 kB  00:00:00     
(2/4): epel/x86_64/group_gz                                                                                                                    |  99 kB  00:00:01     
(3/4): epel/x86_64/updateinfo                                                                                                                  | 1.0 MB  00:00:00     
(4/4): epel/x86_64/primary_db                                                                                                                  | 7.0 MB  00:00:01     
Resolving Dependencies
--> Running transaction check
---> Package links.x86_64 1:2.20.2-1.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

======================================================================================================================================================================
 Package                              Arch                                  Version                                         Repository                           Size
======================================================================================================================================================================
Installing:
 links                                x86_64                                1:2.20.2-1.el7                                  epel                                2.9 M

Transaction Summary
======================================================================================================================================================================
Install  1 Package

Total download size: 2.9 M
Installed size: 4.4 M
Downloading packages:
links-2.20.2-1.el7.x86_64.rpm                                                                                                                  | 2.9 MB  00:00:01     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : 1:links-2.20.2-1.el7.x86_64                                                                                                                        1/1 
  Verifying  : 1:links-2.20.2-1.el7.x86_64                                                                                                                        1/1 

Installed:
  links.x86_64 1:2.20.2-1.el7                                                                                                                                         

Complete!

3.Links工具的使用

直接使用links+网址浏览网页。

links https://mirrors.aliyun.com/centos/

在这里插入图片描述

  • 退出links,按“q”,选择“yes”退出。

在这里插入图片描述

4.打印网页源码输出

links -source打印网页源码输出

[root@jeven tmp]# links -source  https://www.baidu.com/
<html>
<head>
    <script>
        location.replace(location.href.replace("https://","http://"));
    </script>
</head>
<body>
    <noscript><meta http-equiv="refresh" content="0;url=http://www.baidu.com/"></noscript>
</body>

5.打印url版本到标准格式输出

links -dump 打印url版本到标准格式输出

[root@jeven tmp]# links -dump  https://www.baidu.com/
   Refresh: http://www.baidu.com/
[root@jeven tmp]# links -dump  https://mirrors.aliyun.com/centos/
   Link: canonical
   [IMG]
   开源镜像站
   免费体验Linux沙箱实验室 全部镜像 域名解析DNS 网站授时NTP 反馈与建议
   阿里云镜像站> centos镜像配置页> centos镜像下载页> 详细内容

                               Index of /centos/

   File Name                     File Size Date             
   Parent directory/             -         -                
   2/                            -         2010-05-07 01:48 
   2.1/                          -         2009-09-09 13:18 
   3/                            -         2010-05-07 01:48 
   3.1/                          -         2010-05-07 01:48 
   3.3/                          -         2010-05-07 01:48 
   3.4/                          -         2010-05-07 01:48 
   3.5/                          -         2010-05-07 01:48 
   3.6/                          -         2010-05-07 01:48 
   3.7/                          -         2010-05-07 01:48 
   3.8/                          -         2010-05-07 01:48 
   3.9/                          -         2011-03-03 07:44 
   4/                            -         2012-03-13 08:24 
   4.0/                          -         2005-07-19 05:11 
   4.1/                          -         2005-10-22 01:54 
   4.2/                          -         2006-11-04 20:43 
   4.3/                          -         2006-11-11 06:15 
   4.4/                          -         2007-07-08 02:21 
   4.5/                          -         2008-01-11 00:12 
   4.6/                          -         2009-03-31 19:55 
   4.7/                          -         2010-03-08 18:56 
   4.8/                          -         2012-03-13 08:14 
   4.9/                          -         2017-04-03 19:34 
   5/                            -         2017-04-03 19:35 
   5.0/                          -         2014-10-16 21:37 
   5.1/                          -         2014-10-16 21:37 
   5.10/                         -         2017-04-03 19:30 
   5.11/                         -         2017-04-03 19:34 
   5.2/                          -         2014-10-16 21:37 
   5.3/                          -         2014-10-16 21:37 
   5.4/                          -         2014-10-16 21:37 
   5.5/                          -         2014-10-16 21:37 
   5.6/                          -         2014-10-16 21:37 
   5.7/                          -         2014-10-16 21:37 
   5.8/                          -         2014-10-16 21:37 
   5.9/                          -         2014-10-16 21:38 
   6/                            -         2018-07-04 01:21 
   6.0/                          -         2014-10-16 21:42 
   6.1/                          -         2014-10-16 21:42 
   6.10/                         -         2020-12-02 17:00 
   6.2/                          -         2014-10-16 21:42 
   6.3/                          -         2014-10-16 21:42 
   6.4/                          -         2014-10-16 21:42 
   6.5/                          -         2015-01-05 22:33 
   6.6/                          -         2015-08-12 20:23 
   6.7/                          -         2016-06-02 00:09 
   6.8/                          -         2017-06-12 20:38 
   6.9/                          -         2018-07-25 23:42 
   7/                            -         2020-11-12 20:29 
   7.0.1406/                     -         2015-04-07 22:24 
   7.1.1503/                     -         2016-01-08 23:25 
   7.2.1511/                     -         2017-01-28 22:29 
   7.3.1611/                     -         2017-10-25 22:57 
   7.4.1708/                     -         2018-05-24 21:25 
   7.5.1804/                     -         2019-01-05 00:00 
   7.6.1810/                     -         2019-09-25 17:47 
   7.7.1908/                     -         2020-05-05 00:25 
   7.8.2003/                     -         2020-11-17 15:28 
   7.9.2009/                     -         2021-01-18 22:12 
   8/                            -         2021-11-16 20:47 
   8-stream/                     -         2023-01-19 19:49 
   8.0.1905/                     -         2020-10-21 15:52 
   8.1.1911/                     -         2020-10-21 15:53 
   8.2.2004/                     -         2020-12-22 23:27 
   8.3.2011/                     -         2021-09-08 14:57 
   8.4.2105/                     -         2021-11-17 15:29 
   8.5.2111/                     -         2021-12-22 08:53 
   HEADER.html                   1.2 KB    2014-09-30 03:27 
   HEADER.images/                -         2013-11-07 23:21 
   RPM-GPG-KEY-CentOS-3          1.8 KB    2004-03-16 07:16 
   RPM-GPG-KEY-CentOS-4          1.8 KB    2010-05-07 01:48 
   RPM-GPG-KEY-CentOS-5          1.5 KB    2007-02-20 01:57 
   RPM-GPG-KEY-CentOS-6          1.7 KB    2011-07-10 22:28 
   RPM-GPG-KEY-CentOS-7          1.7 KB    2014-07-05 00:01 
   RPM-GPG-KEY-CentOS-Debug-6    1.7 KB    2011-07-10 22:28 
   RPM-GPG-KEY-CentOS-Debug-7    1004.0 B  2015-12-09 17:59 
   RPM-GPG-KEY-CentOS-Official   1.6 KB    2019-09-12 15:39 
   RPM-GPG-KEY-CentOS-Security-6 1.7 KB    2011-07-10 22:28 
   RPM-GPG-KEY-CentOS-Testing-6  1.7 KB    2011-07-10 22:28 
   RPM-GPG-KEY-CentOS-Testing-7  1.7 KB    2015-12-09 17:59 
   RPM-GPG-KEY-beta              1.5 KB    2007-02-20 01:56 
   RPM-GPG-KEY-centos4           1.8 KB    2005-02-27 01:51 
   TIME                          11.0 B    2023-01-25 20:55 
   build/                        -         2005-06-12 20:56 
   dir_sizes                     1.1 KB    2023-01-25 20:10 
   dostools/                     -         2007-04-04 17:45 
   filelist.gz                   7.2 MB    2023-01-25 20:10 
   graphics/                     -         2014-06-12 19:59 
   timestamp.txt                 29.0 B    2023-01-25 20:55 

   镜像源配置帮助 立即查看
   下载排行榜
   最热
   最新
   1 centos镜像源
   2 ubuntu镜像源
   3 pypi镜像源
   4 alinux镜像源
   5 epel镜像源
   6 debian镜像源
   7 fedora镜像源
   8 opensuse镜像源
   9 kali镜像源
   10 rockylinux镜像源
   1 almalinux镜像源
   2 calculate-linux镜像源
   3 blender镜像源
   4 grafana镜像源
   5 centos-debuginfo镜像源
   6 oceanbase镜像源
   7 circlelinux镜像源
   8 termux镜像源
   9 centos-stream镜像源
   10 libreoffice镜像源
   大家都在搜
   postmarketOS镜像源
   neurodebian镜像源
   centos-debuginfo镜像源
   macports镜像源
   openwrt镜像源
   jenkins镜像源
   clearos镜像源
   remi镜像源
   grml镜像源
   msys2镜像源
   新镜像源需求
   没有找到所需镜像?点击申请增加!
   立即申请
   特别声明
   本镜像站内容来自第三方网站,阿里云会尽力审核镜像内容安全,但无法保证其完全合规,请您在下载前慎重考虑。具体请查看《阿里云镜像站特别条款》。
   如您发现镜像站有任何问题,可以填写镜像站投诉表单举报,我们将按照法律规定尽快进行处理。

二、wget工具

1.wget工具介绍

wget 是一个从网络上自动下载文件的自由工具,支持通过 HTTP、HTTPS、FTP 三个最常见的 TCP/IP协议 下载,并可以使用 HTTP 代理。

2.安装wget软件

通过yum安装wget工具

[root@jeven ~]# yum -y install wget 
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * base: mirrors.163.com
 * epel: mirrors.tuna.tsinghua.edu.cn
 * extras: mirrors.163.com
 * updates: mirrors.163.com
Package wget-1.14-18.el7_6.1.x86_64 already installed and latest version
Nothing to do

3.wget工具的使用

-p # 指定下载目录,不指定默认下载到当前目录;
-O # 指定修改目录并指定文件名。
[root@jeven ~]# wget -O runc.amd64 "https://obs-nas.obs.cn-south-1.myhuaweicloud.com:443/containerd/runc.amd64?AccessKeyId=8QZQXILP1SCWCCLMSGIH&Expires=1674746766&Signature=JcEuGg5I/PxdXi7hVT/6sHnvvek%3D"
--2023-01-25 23:26:43--  https://obs-nas.obs.cn-south-1.myhuaweicloud.com/containerd/runc.amd64?AccessKeyId=8QZQXILP1SCWCCLMSGIH&Expires=1674746766&Signature=JcEuGg5I/PxdXi7hVT/6sHnvvek%3D
Resolving obs-nas.obs.cn-south-1.myhuaweicloud.com (obs-nas.obs.cn-south-1.myhuaweicloud.com)... 121.37.63.16, 121.37.63.15, 121.37.63.14, ...
Connecting to obs-nas.obs.cn-south-1.myhuaweicloud.com (obs-nas.obs.cn-south-1.myhuaweicloud.com)|121.37.63.16|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 9415040 (9.0M) [binary/octet-stream]
Saving to: ‘runc.amd64’

100%[============================================================================================================================>] 9,415,040   6.58MB/s   in 1.4s   

2023-01-25 23:26:44 (6.58 MB/s) - ‘runc.amd64’ saved [9415040/9415040]

[root@jeven ~]# ll
total 9224
-rw-------.  1 root root    1753 Feb  2  2022 anaconda-ks.cfg
drwxr-xr-x.  2 root root       6 Feb  2  2022 Desktop
drwx--x---. 14 root root     185 Jul 27 08:51 dockerdata
drwxr-xr-x.  2 root root       6 Feb  2  2022 Documents
drwxr-xr-x.  2 root root       6 Feb  2  2022 Downloads
-rw-r--r--.  1 root root   20009 Jul 26  2022 get-docker.sh
-rw-r--r--.  1 root root    1784 Feb  2  2022 initial-setup-ks.cfg
drwxr-xr-x.  2 root root       6 Feb  2  2022 Music
drwxr-xr-x.  4 root root      29 Jan  9 14:05 mysql
drwxr-xr-x.  2 root root       6 Feb  2  2022 Pictures
drwxr-xr-x.  2 root root       6 Feb  2  2022 Public
drwxr-xr-x.  4 root root      76 Jul 27 09:14 rainbonddata
-rw-r--r--.  1 root root 9415040 Dec 13 23:59 runc.amd64
drwxr-xr-x.  2 root root       6 Feb  2  2022 Templates
drwxr-xr-x.  2 root root       6 Feb  2  2022 Videos
drwxr-xr-x.  4 root root      29 Jan  9 14:07 wiki
[root@jeven ~]#

三、curl工具

1.curl工具的介绍

一个用URL语法传输数据的命令行工具和库,支持DICT, FILE, FTP, FTPS, GOPHER, GOPHERS, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, MQTT, POP3, POP3S, RTMP, RTMPS, RTSP, SCP、SFTP、SMB、SMBS、SMTP、SMTPS、TELNET、TFTP、WS 和 WSS。libcurl 提供了无数强大的功能。

2.curl的常用参数

-o    指定新的本地文件名
-O    保留远程文件的原始名
-u    通过服务端配置的用户名和密码授权访问
-I    打印HTTP响应头信息
-u    指定登录账户密码信息
-A    设置用户代理标头信息
-b    设置用户cookie信息
-C    支持断点续传
-s    静默模式,不输出任何信息
-T    上传文件

3.curl的基本使用

下载文件的基本使用。

[root@jeven tmp]# curl  -o runc.amd64 "https://obs-nas.obs.cn-south-1.myhuaweicloud.com:443/containerd/runc.amd64?AccessKeyId=8QZQXILP1SCWCCLMSGIH&Expires=1674746766&Signature=JcEuGg5I/PxdXi7hVT/6sHnvvek%3D"
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 9194k  100 9194k    0     0  4604k      0  0:00:01  0:00:01 --:--:-- 4604k
[root@jeven tmp]# ll
total 9196
-rw-r--r--. 1 root root 9415040 Jan 25 23:39 runc.amd64

四、scp工具

1.scp工具介绍

安全拷贝(secure copy,简称scp),一种传送命令,是用来进行远程文件拷贝的。数据传输使用 ssh,并且和ssh 使用相同的认证方式,提供相同的安全保证

2.scp工具的基本使用

  • 将本地目录远程拷贝到远程服务器
[root@jeven tmp]# scp -r /tmp  root@192.168.3.158:/test/
root@192.168.3.158's password: 
runc.amd64                                                                                                                          100% 9194KB   4.5MB/s   00:01    
[root@jeven tmp]#
  • 将远程服务器目录拷贝到本地
scp -r root@192.168.3.158:/etc/ /tmp
相关文章
|
1天前
|
运维 监控 Linux
提升系统稳定性:Linux内核参数调优实战
【5月更文挑战第1天】 在运维领域,保障服务器的高效稳定运行是核心任务之一。Linux操作系统因其开源、可靠和灵活的特点被广泛应用于服务器中。本文将深入探讨通过调整Linux内核参数来优化系统性能,提升服务器的稳定性和响应能力。文章首先介绍了内核参数调优的必要性和基本原则,然后详细阐述了调优过程中的关键步骤,包括如何监控当前系统状态,确定性能瓶颈,选择合适的参数进行调优,以及调优后的测试与验证。最后,文中提供了一些常见问题的解决策略和调优的最佳实践。
16 5
|
2天前
|
Linux
Linux系统ps命令
这些是一些常见的 `ps`命令选项和用法,用于查看系统中运行的进程及其相关信息。您可以根据需要选择合适的选项以满足您的任务要求。
8 0
|
2天前
|
机器学习/深度学习 自动驾驶 安全
基于深度学习的图像识别技术在自动驾驶系统中的应用网络安全与信息安全:防御前线的关键技术与意识
【4月更文挑战第30天】随着人工智能技术的飞速发展,深度学习已成为推动多个技术领域革新的核心力量。特别是在图像识别领域,深度学习模型已展现出超越传统算法的性能。在自动驾驶系统中,准确的图像识别是确保行车安全和高效导航的基础。本文将探讨深度学习在自动驾驶中图像识别的应用,分析关键技术挑战,并提出未来的发展方向。
|
2天前
|
存储 负载均衡 网络协议
在Linux中优化系统性能的实用指南
【4月更文挑战第30天】本文是关于Linux系统性能优化的指南,涵盖硬件选择、系统及软件更新、调整Swap分区、内核参数优化、使用性能分析工具、文件系统优化、网络服务优化和定期维护等方面。通过这些方法,可提升系统响应速度,降低资源消耗,延长硬件寿命。注意,优化需根据具体系统和应用需求进行。
|
2天前
|
弹性计算 Shell Linux
|
2天前
|
弹性计算 运维 Shell
自动化网络扫描工具发现活跃主机
【4月更文挑战第30天】
5 0
|
2天前
|
机器学习/深度学习 数据采集 安全
基于机器学习的网络安全威胁检测系统
【4月更文挑战第30天】 随着网络技术的迅猛发展,网络安全问题日益凸显。传统的安全防御机制在应对复杂多变的网络攻击时显得力不从心。为了提高威胁检测的准确性和效率,本文提出了一种基于机器学习的网络安全威胁检测系统。该系统通过集成多种数据预处理技术和特征选择方法,结合先进的机器学习算法,能够实时识别并响应各类网络威胁。实验结果表明,与传统方法相比,本系统在检测率、误报率以及处理速度上均有显著提升,为网络安全管理提供了一种新的技术手段。
|
3天前
|
存储 缓存 Linux
linux几种典型应用对系统资源使用的特点
【4月更文挑战第22天】几种典型应用对系统资源使用的特点
9 0
|
3天前
|
机器学习/深度学习 算法 计算机视觉
m基于Yolov2深度学习网络的智能零售柜商品识别系统matlab仿真,带GUI界面
MATLAB 2022a中展示了YOLOv2目标检测算法的仿真结果,包括多张检测图像。YOLOv2是实时检测算法,由卷积层和全连接层构成,输出张量包含边界框坐标和类别概率。损失函数由三部分组成。程序使用75%的数据进行训练,剩余25%作为测试集。通过ResNet-50预训练模型构建YOLOv2网络,并用SGDM优化器进行训练。训练完成后,保存模型为`model.mat`。
16 2

热门文章

最新文章