![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
linux
洛樱冰飞
这个作者很懒,什么都没留下…
展开
-
普通使用root 权限
普通用户使用root 权限:su 需要输入root 密码,登陆后可以执行root 权限,环境变量依然是当前用户的su - ,需要输入root 密码, 登陆后具有root权限,环境变量为/rootsudo, 当用户在/etc/sudoers 中配置好,无需输入root 密码就可执行root 权限如 :[student@localhost Desktop]$ sudo l...原创 2019-08-24 11:28:08 · 187 阅读 · 0 评论 -
SMTP 配置邮件
[root@server30 postfix]# mail -s "hello world" 12345@qq.com --- 标题 “hello world” 发送到 12345@qq.comtesting mailEOT ----- 内容 testing mail[root@server30 postfix]# tailf /var/log/maillog -...原创 2019-10-06 11:39:40 · 8031 阅读 · 0 评论 -
防火墙
iptables.service 和firewalld.service 都可以配置防火墙,但是最好只用其中一个以防冲突优先级:soucece > interface > default zonesource : 源ipinterface :网卡default zone:默认值[root@server30 yum.repos.d]# firewall-cmd...原创 2019-09-17 19:49:04 · 93 阅读 · 0 评论 -
运维经典面试题之网络篇(一)
1、写出12.23.34.0/29的掩码11111111.11111111.11111111.11111000255.255.255.2482、简述冲突域与广播域的区别冲突域:基于osi的第一层物理层。一个站点向另一个站点发出信号。除目的站点外,有多少站点能收到这个信号。这些站点就构成一个冲突域。交换机可以隔离冲突域。广播域:基于osi中的第二层数据链路层 就是说如果站点发...转载 2019-09-02 19:02:01 · 245 阅读 · 0 评论 -
autofs 自动挂载
将 172.16.30.254://mnt/public 挂载到 /aaa/auto, 一开始不用创建/aaa/auto, 等访问时自动创建[root@station ~]# yum install -y autofs.x86_64[root@station ~]# vim /etc/auto.master添加 /aaa /etc/auto.misc -...原创 2019-09-01 21:15:30 · 220 阅读 · 0 评论 -
SMB 共享
1)不需要挂载,通过samba client 查看[root@station ~]# yum install samba-client.x86_64[root@station ~]# smbclient -L 172.16.30.254 ------- 查看windows共享资源Enter root's password:Anonymous login succes...原创 2019-09-01 20:19:19 · 374 阅读 · 0 评论 -
NFS 配置 -- 客户端
查看服务端共享目录/文件:[root@station bin]# showmount -e 172.16.30.254Export list for 172.16.30.254:/mnt/private */mnt/public */rhome/guest2006 */rhome/guest2005 */rhome/guest2004 */rhome/gu...原创 2019-09-01 19:29:04 · 148 阅读 · 0 评论 -
linux find 命令查找文件和文件夹
查找目录:find /(查找范围) -name '查找关键字' -type d查找文件:find /(查找范围) -name 查找关键字 -print详解:find命令用来在指定目录下查找文件。任何位于参数之前的字符串都将被视为欲查找的目录名。如果使用该命令时,不设置任何参数,则find命令将在当前目录下查找子目录与文件。并且将查找到的子目录和文件全部进行显示。语法...转载 2019-08-29 07:46:36 · 221 阅读 · 0 评论 -
创建swap分区
[root@localhost mnt]# free total used free shared buffers cachedMem: 2043052 1890960 152092 368 1131280 192736-/+ buffers/cache: 56...原创 2019-08-25 21:56:31 · 220 阅读 · 0 评论 -
进程管理
student@localhost ~]$ ps -aux | moreUSER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMANDroot 1 0.0 0.3 52896 6832 ? Ss 16:39 0:03 /usr/lib/systemd/systemd...原创 2019-08-25 19:34:44 · 85 阅读 · 0 评论 -
管理文件/目录权限
管理文件/目录权限chmod whowhatwhich file|directorywho: u,g,o,a (用户,组,其他,全部)what: + - = (添加,删除,精准设置)which:r,w,x (读取,写入,执行)[student@localhost ~]$ ll test-rw-rw-r--. 1 student student 0 Aug 24 12:...原创 2019-08-24 12:28:10 · 81 阅读 · 0 评论 -
管理本地用户
查看用户基本信息[student@localhost Desktop]$ iduid=1000(student) gid=1000(student) groups=1000(student) context=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023添加用户:useradd username , 没有其他参数时所有字段均...原创 2019-08-24 11:47:08 · 136 阅读 · 0 评论 -
iscsi 配置
配置服务器端:[root@server30 Desktop]# yum install targetcli.noarch[root@server30 Desktop]# systemctl enable target.servicecreate /dev/sda3[root@server30 Desktop]# targetcli/> lso- / ...........原创 2019-10-06 17:45:01 · 385 阅读 · 0 评论