1、RPM软件管理
1> 通过rpm安装vsftpd软件。
2> 查询vsftpd软件包的信息。
3> 卸载软件包vsftpd。
2、YUM软件管理
1> 挂载本地光盘,配置yum源为rhel.repo。
2> 通过yum来安装traceroute。
3> 使用yum查询ifconfig命令是由那个软件包提供的。
4> 卸载软件包httpd。
3、通过pgrep和pidof命令查看sshd服务的进程号
4、配置网络:为网卡添加一个本网段IPV4地址,x.x.x.123,并启用,然后在阿里镜像站GNU里,下载wget2的包
5、1、基本存储配置
1) 添加一块10G大小的磁盘,将该磁盘分为两个主分区,大小为1G、2G。将剩余的空间全部划分为扩展分区。划分一个逻辑分区,大小为3G。(主分区文件系统类型为ext4,逻辑分区文件系统类型为xfs)
2) 将三个分区分别挂载到/dir1、/dir2、/dir3。
3) 在第一个主分区中创建一个文件为file1,内容为this is partition1。在第二个分区中创建一个文件为file2,内容为this is partition2。在第三个分区中创建一个文件为file3,内容为this is partition3
1、RPM软件管理
1> 通过rpm安装vsftpd软件。
[root@redhat Packages]# rpm -ivh vsftpd-3.0.3-49.el9.x86_64.rpm
2>查询vsftpd软件包的信息。
[root@redhat Packages]# rpm -l vsftpd-3.0.3-49.el9.x86_64.rpm
3> 卸载软件包vsftpd。
[root@redhat Packages]# rpm -evh vsftpd
2、YUM软件管理
1> 挂载本地光盘,配置yum源为rhel.repo。
[root@redhat Packages]# cd /etc/yum.repos.d/
[root@redhat yum.repos.d]# vim rhel.repo
2>通过yum来安装traceroute。
[root@redhat yum.repos.d]# yum install traceroute
-y
3>使用yum查询ifconfig命令是由那个软件包提供的。
[root@redhat yum.repos.d]# yum provides ifconfig
4>卸载软件包httpd。
[root@redhat yum.repos.d]# yum remove httpd
3.通过pgrep和pidof命令查看sshd服务的进程号
[root@redhat ~]# pgrep sshd
[root@redhat ~]# pidof sshd
4.配置网络:为网卡添加一个本网段IPV4地址,x.x.x.123,并启用,然后在阿里镜像站GNU里,下载wget2的包
(1).添加网址
[root@redhat ~]# nmcli c add type ethernet con-name ethx-test ifname ethx ipv4.addresses '192.168.224.123' ipv4.gateway 192.168.224.2 ipv4.dns '114.114.114.114' ipv4.method manual autoconnect yes
(2).下载wget2
[root@redhat ~]# wget
https://mirrors.aliyun.com/gnu/wget/wget2-latest.tar.lz?spm=a2c6h.25603864.0.0.7ccf37cdKw1zGA5、1、基本存储配置
1) 添加一块10G大小的磁盘,将该磁盘分为两个主分区,大小为1G、2G。将剩余的空间全部划分为扩展分区。划分一个逻辑分区,大小为3G。(主分区文件系统类型为ext4,逻辑分区文件系统类型为xfs)
1.添加一块硬盘(10G)
2.使用fdisk管理分区
[root@redhat ~]# fdisk /dev/sda
(1)磁盘分为两个主分区,大小为1G、2G
(2)将剩余的空间全部划分为扩展分区
(3)划分一个逻辑分区,大小为3G
(4)查看结果
3.主分区文件系统类型为ext4
[root@redhat ~]# mkfs.ext4 /dev/sda1
[root@redhat ~]# mkfs.ext4 /dev/sda2
4.逻辑分区文件系统类型为xfs
[root@redhat ~]# mkfs.xfs /dev/sda5
2).将三个分区分别挂载到。
1. 创建dir1、dir2、dir3
[root@redhat ~]# mkdir /dir{1..3}
2.挂载
[root@redhat ~]# mount /dev/sda1 /dir1
[root@redhat ~]# mount /dev/sda2 /dir2
[root@redhat ~]# mount /dev/sda5 /dir3
3.查看
3).在第一个主分区中创建一个文件为file1,内容为this is partition1。在第二个分区中创建一个文件为file2,内容为this is partition2。在第三个分区中创建一个文件为file3,内容为this is partition3
[root@redhat ~]# echo "this is partition1"> /dir1/file1
[root@redhat ~]# echo "this is partition2"> /dir2/file2
[root@redhat ~]# echo "this is partition3"> /dir3/file3