Linux随笔-1

1、vmware下的共享文件夹目录(Linux系统下):计算机->mnt->hgfs->共享文件夹名

2、CentOS7:解决Packagekit占用yum问题

vim /etc/yum/pluginconf.d/langpacks.conf

将第一行:enable=1改为enable=0

重启linux

3、关机和重启命令

1)shutdown

命令格式:

[root@localhost ~]# shutdown [选项] 时间 [警告信息]

选项:

  • -c:取消已经执行的 shutdown 命令;
  • -h:关机;
  • -r:重启;

举例:

[root@localhost ~]# shutdown -r now
#重启, now是现在重启的意思
[root@localhost ~]# shutdown -r 05:30
#指定时间重启,但会占用前台终端
[root@localhost ~]# shutdown -r 05:30 &
#把定义重启命令放入后台,&是后台的意思
[root@localhost ~]# shutdown -c
//取消定时重启
[root@localhost ~]# shutdown -r +10
#10分钟之后重启
[root@localhost ~]# shutdown -h now
#现在关机
[root@localhost ~]# shutdown -h 05:30
#指定时间关机

2)reboot命令

[root@localhost ~]# reboot
#重启

3)halt和poweroff命令

[root@localhost ~】# halt
#关机
[root@localhost ~】# poweroff
#关机

4、yum提示Another app is currently holding the yum lock; waiting for it to exit...解决方法:

通过强制关掉yum进程:

#rm -f /var/run/yum.pid

5、mdsplus安装步骤

1)安装java、xinetd和openmotif,通过命令yum -y install xinetd,其他类似

2)安装EPEL:

    RHEL/CentOS 7:# yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
3)安装部分必须文件:

yum install libxml2  

yum install libxml2-devel

yum install libtermcap-devel ncurses-devel libevent-devel readline-devel

yum install xterm

6、linux修改用户密码

1)普通用户运行passwd只能修改它自己的密码

2)用root用户运行passwdpasswd user_name可以设置或修改任何用户的密码

原文地址:https://www.cnblogs.com/GjqDream/p/11604673.html