Linux心得
wall 发消息(挺好玩的,呵!)
lspci -v 查看硬件芯片
修改分辨率vi /etc/X11/FX86config,找到Monitor修改
时钟分为系统时钏和硬件时钟,在启动时,硬件时钟会去读取系统时钟的设置,然后系统时钟就会独立于硬件运作.
查看时钟:
date
设置系统时钟:
date 091713272004.30
格式:
date 月日时分年.秒
查看硬件时钟:
hwclock或clock,命令差不多.
设置硬件时钟:
hwclock --set --date="04/11/2004 23:16:25"
或clock --set --date="04/11/2004 23:16:25"
硬件时钟与系统时钟同步:
hwclock --hctosys或clock --hctosys
系统时钟与硬件时钟同步:
hwclock --systohc或clock --systohc
arp 查看本地的MAC地址
ifconfig eth0 210.75.32.28 netmask 255.255.255.128 broadcast 210.75.32.127
给eth0接口加入IP地址及掩码
ifconfig eth0 down 关闭接口
ifconfig eth0 up 打开接口
FTP命令:
ls:列出远程机上改变工作目录
cd:在远程机上改变工作目录
lcd:在本地机改变工作目录
close:终止当前的ftp对话
get(mget):从远程服务器指定文件到本机
put(mput):从本机上传到远程服务器
bye:离开
more /root/.bash_history 查看历史命令
在一张网卡上绑定多个IP地址:
ifconfig eth0:0 192.168.0.253 netmask 255.255.255.0
ifconfig eth0:1 192.168.0.252 netmask 255.255.255.0
把iso制作成虚拟光驱 dd if=/dev/cdrom of=jin.iso bs=2048
env命令用来查看环境变量
du -h 显示本目录的文件及各文件的大小
du -sh 显示目录占硬盘总的大小
Linux下如何查找文件?
& 在当前目录下查找文件明为*.sql的文件: $find . -name "*.sql"
& 查找大于100M的文件: find . -size +100000
& 查找含有"china" 的文件: find . -name "*" -exec grep -l "china" {}/
& 查找并删除tmp*的文件: find . -name "tmp* -exec rm {}/
& 查找7天没有被修改过的文件: find . -mtime +7
/boot/grub/grub.conf
GRUB 配置
/boot/module-info-*
内核驱动信息
Module information for the Linux kernel
/boot/System.map-*
系统例表
Map of the Linux kernel
/boot/vmlinuz-*
内核
Linux kernel
/etc/aliases
邮件别名
Mail aliases
/etc/at.deny
被禁止的用户
User IDs of users forbidden to use the at command
/etc/auto.master
自动mount
Configuration file for the autofs daemon, which automatically mounts filesystems
/etc/auto.misc
Automounter map file
/etc/crontab
系统日志
System cron file
/etc/cron.daily/*
安全日志
Daily cron jobs
/etc/cron.hourly/*
时志
Hourly cron jobs
/etc/cron.monthly/*
月志
Monthly cron jobs
/etc/cron.weekly/*
周志
Weekly cron jobs
/etc/filesystems
支持的文件系统格式
Supported filesystem types
/etc/fstab
文件系统mount
Filesystems mounted or available for mounting
/etc/group
系统组定义
System group definitions
/etc/host.conf
Resolver configuration file
/etc/hosts
域名IP
Map of IP numbers to hostnames
/etc/hosts.allow
允许的IP
ALL : 1.1.1.1
ALL : 2.2.2.* : deny
sendmail : 3.3.3.3 : deny
ipop3d : *
sendmail : ALL : allow
in.ftpd : *
Hosts allowed to access Internet services
/etc/hosts.deny
禁止的IP
ALL:*
Hosts forbidden to access Internet services
/etc/httpd/conf/*
Apache配置文件
Apache configuration files
/etc/httpd/httpd.conf
Web服务器配置文件
Web server configuration file
/etc/initlog.conf
登陆配置文件
Logging configuration file
/etc/inittab
Configuration for the init daemon, which controls executing processes
/etc/issue
Linux kernel and distribution version
Linux心得
最新推荐文章于 2023-05-30 23:15:30 发布