• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
hhdllhflower
博客园    首页    新随笔    联系   管理    订阅  订阅

Fedora15命令速查手册

Fedora15命令速查手册

 

源文档 <http://www.nenew.net/archivers/p2062.html>

 

 

 

 

 

Privileges 

sudo command – run command as root 

sudo -s – open a root shell 

sudo -s -u user – open a shell as user 

sudo -k – forget sudo passwords 

gksudo command – visual sudo dialog (GNOME) 

kdesudo command – visual sudo dialog (KDE) 

sudo visudo – edit /etc/sudoers 

sudo nautilus – root file manager (GNOME) 

sudo konqueror – root file manager (KDE) 

passwd – change your password 

Application Names 

nautilus – file manager (GNOME) 

dolphin – file manager (KDE) 

kate – text editor (KDE) 

gedit – text editor (GNOME) 

System Services 

sudo service service status – check if 

service is running 

sudo service service start – start service 

sudo service service stop – stop service 

sudo service service restart – restart ser- 

vice 

runlevel – get current runlevel 

sudo chkconfig --level 35 service on/off – 

set service to run/not run in runlevels 3,5 

uname -r – get kernel version 

uname -a – get all kernel information 

Setup YUM and SUDO 

Setting up SUDO: su -c 'echo "$USER 

ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers' 

Setting up YUM: sudo rpm -ivh 

http://download1.rpmfusion.org/free/fedora/rpmfus 

ion-free-release-stable.noarch.rpm \ 

http://download1.rpmfusion.org/nonfree/fedora/rpm 

fusion-nonfree-release-stable.noarch.rpm && sudo 

rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY- 

rpmfusion-* && sudo rpm --import /etc/pki/rpm- 

gpg/* 

Firewall 

sudo service iptables on – start firewall 

sudo service iptables off – stop firewall 

sudo iptables -L – show current config 

sudo iptables -a INPUT -j ACCEPT – allow all 

connections 

sudo iptables -a INPUT -j REJECT – deny all 

connections 

sudo iptables -a INPUT --dport port -j 

ACCEPT – allow connection to port 

sudo iptables -a INPUT --dport port -j 

REJECT – deny connection to port 

sudo iptables -F – Reset firewall config

Network 

ifconfig – show network information 

iwconfig – show wireless information 

sudo iwlist scan – scan for wireless network 

sudo service network restart – reset network 

for manual configuration 

(file)/etc/sysconfig/network-scripts/ifcfg- 

interface – edit your gateway here 

sudo service NetworkManager restart – reset 

network to use NetworkManager 

sudo chkconfig --level 35 network on \ sudo 

chkconfig --level 35 NetworkManager off – 

in case you have network problems with the 

NetworkManager applet. 

ifup interface – bring interface online 

ifdown interface – disable interface 

Display 

Ctrl+Alt+Bksp – restart X display if frozen 

(file)/etc/X11/xorg.conf – display config 

Xorg -configure – create new config file 

Ctrl+Alt+FN – switch to ttyN 

Ctrl+Alt+F1 – switch back to X display 

Package Management 

sudo yum update – same as update 

sudo yum check-update – check for availabi- 

lity of updates for installed packages 

sudo yum install pkg – install pkg 

sudo yum remove pkg – remove pkg 

sudo yum clean – clean the cache 

(file) /etc/yum.conf – configuration for the 

repos. Set keepcache=1 in this file for 

retaining all packages downloaded by yum 

Fixing the YUM/RPM Database: 

sudo yum clean all 

sudo yum clean metadata 

sudo yum clean dbcache 

sudo rpm -vv --initdb 

sudo rm -f /var/lib/rpm/__db* 

sudo rpmdb -vv --rebuilddb > /dev/null 

Setup MP3 and Video 

Audio(MP3): sudo yum install rhythmbox 

gstreamer-plugins-ugly gstreamer-plugins-bad 

gstreamer-ffmpeg 

Video: sudo yum install xine xine-lib-extras 

xine-lib-extras-freeworld 

Flash Plugin 

Flash Support: sudo rpm -ivh 

http://fpdownload.macromedia.com/pub/flashplayer/ 

current/flash-plugin-10.3.181.14-release.i386.rpm 

&& su -c 'yum install flash-plugin alsa-plugins- 

pulseaudio libcurl'

 

源文档 <http://www.nenew.net/archivers/p2062.html> 

posted @ 2012-10-04 20:45  hhdllhflower  阅读(287)  评论(0)    收藏  举报
刷新页面返回顶部
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3