DapperGuide
[[HTML(<a name="General_Notes"></a>)]]
基本备注
- 新手指南是一份非官方发行的文件。这份文件和Ubuntu 与 Canonical Ltd 都没有任何直接关系。
- 这份指南的内容都已经在一台使用Ubuntu 6.06 x86 安装光盘 (Dapper Drake) 完整安装的系统上测试过。
- 如果您看到青蓝色的方块,表示您需要在终端(应用程序 -> 附件 -> 终端)内执行上述的指令,或者使用其它方式执行上述的指令。
- 为了避免打字错误引起的问题,请在终端机善加使用复制与粘贴这两个指令(用鼠标右键点选 "复制" 或者 "粘贴"。您也可以利用 Ctrl+C 进行 "复制" 以及使用 Shift+Insert 进行粘贴。)
- "sudo" 代表 superuser do (超级使用者执行)。执行 "sudo" 后将会出现提示字符串 "Password:",请输入使用者密码。
- 如果您需要了解任何一个命令的更多信息,您只须使用"man"命令来查阅它的帮助页面.譬如,"man sudo"会显示"sudo"命令的帮助页面。
- 如果您厌倦每次打 "apt-get" 指令,请参阅 DapperGuide#How_to_apt-get_the_easy_way_.28Synaptic.29 #如何简单的使用 apt-get(新立得).
- 使用 "apt-get" 和 "wget" 这两个指令来 安装 / 更新 / 下载程序时,请先确定您的系统已经连接上网络。
- 下载文档时, 用鼠标右键点击链接 -> 选择 "链接另存为..." -> 请确认文件名称和扩展名都正确无误。
- 如果您想要帮忙翻译 Ubuntu 或者其它方式帮助 Ubuntu 可以拜访 [[1]]
- 愿 "humanity to others" 的精神长伴您左右...
如果你使用 Kubuntu 你不需要安装 gedit , 因为现在已经建立了动态链接由 gedit 到 kate, 应此您可以在下面使用所有的命令并不会有问题. 顺便提一下, 如果你希望使用 gedit 作为你的编辑器, 这样:
sudo apt-get install gedit
如果 "gedit" 命令 (动态链接) 无法工作, 您可以建立它:
sudo ln -s /usr/bin/kate /usr/bin/gedit
如果您在使用 64位版本请把 "i386" 换成 "amd64"
[[HTML(<a name="Getting_Started"></a>)]]
开始的第一步
[[HTML(<a name="What_is_Ubuntu"></a>)]]
什么是 Ubuntu
[[HTML(<a name="What_is_new_in_Ubuntu_6.06_Dapper_Drake"></a>)]]
在 Ubuntu 6.06 Dapper Drake 有哪些新特性
[[HTML(<a name="Where_to_view_Ubuntu_screenshots_.2F_screencast"></a>)]]
何处可以看到 Ubuntu 屏幕抓图
视频
[[HTML(<a name="Where_to_view_Kubuntu_screenshots_.2F_screencast"></a>)]]
何处可以看到 KUbuntu 屏幕抓图
视频
[[HTML(<a name="Where_to_find_a_list_of_all_the_programs_and_libraries_that_come_with_Ubuntu"></a>)]]
何处可以找到 Ubuntu 所有的程序/函数库的清单
- dpkg -l命令的输出: Here
- http://packages.ubuntu.com/dapper
- http://distrowatch.com/table.php?distribution=ubuntu
[[HTML(<a name="Where_to_download_Ubuntu"></a>)]]
何处可以下载Ubuntu
[[HTML(<a name="Where_to_order_Ubuntu_CDs_absolutely_FREE"></a>)]]
何处可以免费索取 Ubuntu 光盘片?
请注意光盘需要花费四到六周才能收到. 如果有可能鼓励您复制、修改和重新分发这些光盘。
[[HTML(<a name="Where_to_find_help_for_Ubuntu"></a>)]]
何处可以找到关于 Ubuntu 的说明与帮助
- 查看: '系统 -> 帮助 -> 系统文档
[[HTML(<a name="Where_to_look_for_new_programs"></a>)]]
何处可以找到新的程序
[[HTML(<a name="Where_to_look_for_style_elements_for_your_desktop"></a>)]]
何处可以找到关于桌面美化的数据
[[HTML(<a name="Repositories"></a>)]]
软件库
[[HTML(<a name="How_to_add_extra_repositories"></a>)]]
如何新增其他的软件库
- 您也可以 DapperGuide#How_to_apt-get_the_easy_way_.28Synaptic.29 使用新立得(Synaptic)添加其它软件库。. 新用户可能会觉得通过新立得添加其他软件库会更顺手。 如果您依照以上的链接做了,就不需要查看以下部分了。
sudo cp -p /etc/apt/sources.list /etc/apt/sources.list_backup gksudo gedit /etc/apt/sources.list
- 用以下内容替换文件中的所有内容
使用您的本地镜像,您可以增加 "cc." 在 archive.ubuntu.com (cc = 你的国家代码)
e.g. deb http://lv.archive.ubuntu.com/ubuntu dapper main restricted universe multiverse
## Add comments (##) in front of any line to remove it from being checked. deb http://archive.ubuntu.com/ubuntu dapper main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu dapper main restricted universe multiverse deb http://archive.ubuntu.com/ubuntu dapper-updates main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu dapper-updates main restricted universe multiverse deb http://security.ubuntu.com/ubuntu dapper-security main restricted universe multiverse deb-src http://security.ubuntu.com/ubuntu dapper-security main restricted universe multiverse deb http://archive.ubuntu.com/ubuntu dapper-backports main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu dapper-backports main restricted universe multiverse deb http://packages.freecontrib.org/plf dapper free non-free deb-src http://packages.freecontrib.org/plf dapper free non-free deb http://archive.canonical.com/ubuntu dapper-commercial main
- 保存编辑好的文件
sudo apt-get update
- 您也可以产生您自己的 sources.list 发现其它的软件仓库: [15]
- 您也可以使用下面非常完整的列表来覆盖您的 sources.list : sources.list (be sure to replace "it" from "it.archive.ubuntu.com" with your country code. Use at own risk.
- Modify the default Ubuntu sources.list only if you understand what you're doing. Mixing repos can cause breakage.
[[HTML(<a name="Ubuntu_Updates"></a>)]]
Ubuntu 升级
[[HTML(<a name="How_to_manually_update_Ubuntu"></a>)]]
如何手工升级 Ubuntu
sudo apt-get update sudo apt-get upgrade
OR
Use Update Manager: 系统 -> 系统管理 -> Update Manager
[[HTML(<a name="Add-On_Applications"></a>)]]
新增其他应用程序
[[HTML(<a name="How_to_use_Easy_Ubuntu"></a>)]]
如何使用 Easy Ubuntu
- Easy Ubuntu is a small straight-forward utility that allows novice users to easily install a wide variety of content for Ubuntu such as media codecs, fonts, Macromedia Flash and Sun Java.
wget http://easyubuntu.freecontrib.org/files/easyubuntu-3.021.tar.gz tar -zxf easyubuntu-3.021.tar.gz cd easyubuntu sudo python easyubuntu.in
- From the Easy Ubuntu window, check the appropriate boxes to download and install content to Ubuntu.
- Note: Users of the previous EasyUbuntu 3.0 version may experience issues with installing Flash and Java.
[[HTML(<a name="How_to_install_Automatix_on_Ubuntu.2C_Kubuntu.2C_and_Xubuntu"></a>)]]
如何安装 Automatix 在 Ubuntu, Kubuntu, 和 Xubuntu
- Automatix is a graphical interface for automating the installation of the most commonly requested applications in Ubuntu/Kubuntu/Xubuntu linux.
- Note: Before installing, please note that certain codecs it provides may be prohibited in certain countries. You are responsible for ensuring those laws are not broken.
- using your favorite text editor (kwrite, gedit)
gksudo kwrite /etc/apt/sources.list
- Uncomment the following lines
#deb http://archive.ubuntu.com/ubuntu dapper main #deb-src http://archive.ubuntu.com/ubuntu dapper main
- If you use Ubuntu or Xubuntu Dapper, add the following line to the end of the file.
deb http://www.getautomatix.com/apt dapper main
- If you use Kubuntu, add the following line to the end of the file.
deb http://www.getautomatix.com/apt kubuntu main
- Save the file and close it
- Acquire GPG key
wget http://www.getautomatix.com/apt/key.gpg.asc gpg --import key.gpg.asc gpg --export --armor 521A9C7C | sudo apt-key add -
- Run the following commands to install Automatix
sudo apt-get update sudo apt-get install zenity sudo apt-get install automatix
- Automatix can be started from the command line
automatix
- It will be added to the Menu, as well
菜单 -> 系统 -> Automatix-Kubuntu
[[HTML(<a name="How_to_install_Clipboard_Daemon_for_GNOME"></a>)]]
如何安装 Clipboard Daemon for GNOME
wget -c http://easylinux.info/uploads/gnome-clipboard-daemon-1.0.bin.tar.bz2 sudo tar jxvf gnome-clipboard-daemon-1.0.bin.tar.bz2 -C /usr/bin/ sudo chown root:root /usr/bin/gnome-clipboard-daemon sudo chmod 755 /usr/bin/gnome-clipboard-daemon sudo gnome-clipboard-daemon & export EDITOR=gedit && crontab -e
- Add the following line at the end of file
@reboot gnome-clipboard-daemon
- 保存编辑好的文件
[[HTML(<a name="How_to_install_J2SE_Runtime_Environment_.28JRE.29_with_Plug-in_for_Mozilla_Firefox"></a>)]]
如何安装 J2SE Runtime Environment (JRE) with Plug-in for Mozilla Firefox
sudo apt-get install sun-java5-jre sun-java5-plugin
- When asked, agree with DLJ license terms.
- To configure J2SE as the default JVM (necessary for programs such as Frostwire, RSSOwl and as a plugin for Mozilla Firefox):
sudo update-alternatives --config java
Then choose the option that corresponds to J2SE.
[[HTML(<a name="How_to_install_JRE_v5.0_Update_8"></a>)]]
如何安装 JRE v5.0 Update 8
- Download the "Linux (self-extracting file)" from [16]
- Copy it to /usr/java/
sudo chmod a+x jre-1_5_0_08-linux-i586.bin sudo ./jre-1_5_0_08-linux-i586.bin cd /usr/lib/firefox/plugins ln -s /usr/java/jre1.5.0_08/plugin/i386/ns7/libjavaplugin_oji.so cd /usr/lib/mozilla/plugins ln -s /usr/java/jre1.5.0_08/plugin/i386/ns7/libjavaplugin_oji.so
- 重启 Mozilla Firefox
[[HTML(<a name="How_to_install_Flash_Player_.28Macromedia_Flash.29_Plug-in_for_Mozilla_Firefox"></a>)]]
如何安装 Flash Player (Macromedia Flash) Plug-in for Mozilla Firefox
sudo apt-get install flashplugin-nonfree sudo update-flashplugin
- 重启 Mozilla Firefox
Note: if sound doesn't work in Flash Player (for example on YouTube):
sudo apt-get install alsa-oss gksudo gedit /etc/firefox/firefoxrc
Change:
FIREFOX_DSP=""
To:
FIREFOX_DSP="aoss"
- 重启 Mozilla Firefox. Now sound should work in Flash Player.
[[HTML(<a name="How_to_install_PDF_Reader_.28Adobe_Acrobat_Reader.29_with_Plug-in_for_Mozilla_Firefox"></a>)]]
如何安装 PDF Reader (Adobe Acrobat Reader) with Plug-in for Mozilla Firefox
sudo apt-get install acroread mozilla-acroread acroread-plugins
- Read [DapperGuide#How_to_refresh_GNOME_panel #如何刷新 GNOME 面板]
- 应用程序 -> 办公 -> Adobe Reader
- 重启 Mozilla Firefox
Note: Acrobat Reader 7.0 will not run if SCIM is running. You are running SCIM if you have installed another language to Ubuntu via 系统 -> 系统管理 -> Language Support. To circumvent, do the following
gksudo gedit /usr/bin/acroread
Change:
#!/bin/sh #
to:
#!/bin/sh # GTK_IM_MODULE=xim
Save the file. Now Acrobat Reader 7.0 should work.
[[HTML(<a name="How_to_associate_Adobe_Acrobat_Reader_with_files_in_Nautilus"></a>)]]
如何 associate Adobe Acrobat Reader with files in Nautilus
- Open Nautilus (Places -> Desktop)
- Browse to a .pdf file
- Right-click the .pdf file, select Properties, go to the Open With tab, choose Adobe Reader.
Now when you double-click on a .pdf file, it will be opened with Adobe Acrobat Reader.
[[HTML(<a name="How_to_print_from_Adobe_Acrobat_Reader"></a>)]]
如何 print from Adobe Acrobat Reader
- Read [DapperGuide#How_to_add_a_printer #How to add a printer]
- 应用程序 -> 办公 -> Adobe Reader
- File -> Print
- In the Print Command box, append -d printername. For example, if your printer was named FS-1010, the Print Command would read:
/usr/bin/lp -d FS-1010
[[HTML(<a name="How_to_install_Download_Manager_.28Downloader_for_X.29"></a>)]]
如何安装 Download Manager (Downloader for X)
sudo apt-get install d4x
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> Downloader for X
[[HTML(<a name="How_to_install_FTP_Client_.28gFTP.29"></a>)]]
如何安装 FTP Client (gFTP)
sudo apt-get install gftp
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> gFTP
[[HTML(<a name="How_to_install_File_share_utility_.28DC.2B.2B.29"></a>)]]
wget -c http://easylinux.info/uploads/linuxdcpp.tar.gz sudo tar zxvf linuxdcpp.tar.gz -C /opt gksudo gedit /usr/share/applications/dcpp.desktop
- 插入下面的行到新文件
[Desktop Entry] Encoding=UTF-8 Name=DC++ Exec=/opt/linuxdcpp/ldcpp Terminal=false Type=Application StartupNotify=true Icon=/opt/linuxdcpp/pixmaps/linuxdcpp.svg Categories=Application;Network;
- 保存编辑好的文件
- 应用程序 -> Internet -> DC++
[[HTML(<a name="How_to_install_P2P_BitTorrent_Client_.28Azureus.29"></a>)]]
如何安装 P2P BitTorrent Client (Azureus)
sudo apt-get install azureus
- 应用程序 -> Internet -> Azureus
- (Alternative Method) The above method installs a version of Azureus compiled with gcj, the free alternative to Sun's Java.
- Read [DapperGuide#How_to_install_J2SE_Runtime_Environment_.28JRE.29_with_Plug-in_for_Mozilla_Firefox" #How to install J2SE Runtime Environment (JRE) with Plug-in for Mozilla Firefox]
wget [http://kent.dl.sourceforge.net/sourceforge/azureus/Azureus_2.5.0.0_linux.tar.bz2" title="http://kent.dl.sourceforge.net/sourceforge/azureus/Azureus 2.5.0.0 linux.tar.bz2" rel="nofollow">http://kent.dl.sourceforge.net/sourceforge/azureus/Azureus_2.5.0.0_linux.tar.bz2] sudo tar jxvf Azurues_2.5.0.0_linux.tar.bz2 -C /opt/ sudo gedit /usr/share/applications/azureus.desktop
- Add the following to the new file
[Desktop Entry] Name=Azureus Comment=A Bittorrent client Exec=/opt/azureus/azureus Icon=/opt/azureus/Azureus.png Terminal=false Type=Application Categories=Application;Network;
- 保存编辑好的文件
- 应用程序 -> Internet -> Azureus
[[HTML(<a name="How_to_install_P2P_BitTorrent_Client_.28Bittornado.29"></a>)]]
如何安装 P2P BitTorrent Client (Bittornado)
sudo apt-get install bittornado sudo apt-get install bittornado-gui
- 应用程序 -> Internet -> Bittornado Client
[[HTML(<a name="How_to_install_P2P_eMule_Client_.28aMule.29"></a>)]]
如何安装 P2P eMule Client (aMule)
sudo apt-get install amule
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> aMule
[[HTML(<a name="How_to_install_P2P_Gnutella_Client_.28FrostWire.29"></a>)]]
如何安装 P2P Gnutella Client (FrostWire)
wget -c http://www.users.on.net/%7Estubby/FrostWire-4.10.9-2.i586.deb sudo dpkg -i FrostWire-4.10.9-2.i586.deb
- 应用程序 -> Internet -> FrostWire
[[HTML(<a name="How_to_install_Messenger_.28Skype.29"></a>)]]
如何安装 Messenger (Skype)
gksudo gedit /etc/apt/sources.list
- Add the following lines at the end of file
## Repository for Skype deb http://download.skype.com/linux/repos/debian/ stable non-free
- 保存编辑好的文件
sudo apt-get update sudo apt-get install skype
- 应用程序 -> Internet -> Skype
- For the Skype 1.3 Beta dowload the debian package here
- In the terminal
sudo dpkg -i skype-beta-1.3.0.37-1_i386.deb
- 应用程序 -> Internet -> Skype
[[HTML(<a name="How_to_install_WinPopup_.28LinPopUp.29"></a>)]]
如何安装 WinPopup (LinPopUp)
sudo apt-get install linpopup gksudo gedit /usr/share/applications/linpopup.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=LinPopUp Comment=LinPopUp Exec=linpopup Icon=/usr/share/pixmaps/linpopup.xpm Terminal=false Type=Application Categories=Application;Utility;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> Accessories -> LinPopUp
[[HTML(<a name="How_to_install_Multimedia_Codecs"></a>)]]
如何安装 Multimedia Codecs
Stubby: All known codecs work except for wmv
sudo apt-get install gstreamer0.10-ffmpeg gstreamer0.10-gl gstreamer0.10-plugins-base \ gstreamer0.10-plugins-good gstreamer0.10-plugins-bad gstreamer0.10-plugins-bad-multiverse \ gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly-multiverse w32codecs
[[HTML(<a name="How_to_install_DVD_playback_capability"></a>)]]
如何安装 DVD playback capability
ironss: gstreamer dvd plugin is available as part of plugins-bad (or ugly?) and does not work reliably. However, Totem works with the xine backend to play back DVDs. This will keep you going until gstreamer gets dvd playback. Note that you do not have to install xine-ui or mplayer as suggested in
sudo apt-get install libdvdread3 sudo /usr/share/doc/libdvdread3/examples/install-css.sh sudo apt-get install totem-xine
Stubby: gstreamer dvd plugin not ported to dapper yet. following instructions will not work properly
sudo apt-get install libdvdcss2
[[HTML(<a name="How_to_install_Multimedia_Player_.28xine-ui.29"></a>)]]
如何安装 Multimedia Player (xine-ui)
sudo apt-get install xine-ui libxine-extracodecs
- Associate xine-ui to play multimedia files
gconftool-2 --type string --set /desktop/gnome/volume_manager/autoplay_dvd_command "xine dvd://" sudo rm -f /usr/share/applnk/Multimedia/xine.desktop sudo ln -fs /usr/share/xine/desktop/xine.desktop /usr/share/applications/ sudo cp /usr/share/applications/defaults.list /usr/share/applications/defaults.list_backup sudo sed -e 's/totem.desktop/xine.desktop/g' /usr/share/applications/defaults.list_backup > /tmp/defaults.list sudo mv /tmp/defaults.list /usr/share/applications/defaults.list
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> xine
[[HTML(<a name="How_to_install_Multimedia_Player_.28VLC.29_with_plug-in_for_Mozilla_Firefox"></a>)]]
如何安装 Multimedia Player (VLC) with plug-in for Mozilla Firefox
sudo apt-get install vlc vlc-plugin-* mozilla-plugin-vlc
- Inorder to stream video via vlc, you also need to install the following packages.
apt-get install avahi-daemon apt-get install avahi-utils
应用程序 -> 影音 -> VLC Media Player
[[HTML(<a name="How_to_install_Multimedia_Player_.28Mplayer.29_with_plug-in_for_Mozilla_Firefox"></a>)]]
如何安装 Multimedia Player (Mplayer) with plug-in for Mozilla Firefox=
sudo apt-get install mozilla-mplayer
应用程序 -> 影音 -> MPlayer Movie Player
[[HTML(<a name="How_to_install_Multimedia_Player_.28Totem.29_with_plug-in_for_Mozilla_Firefox"></a>)]]
如何安装 Multimedia Player (Totem) with plug-in for Mozilla Firefox
sudo apt-get install totem-gstreamer-firefox-plugin
- 重启 Mozilla Firefox
[[HTML(<a name="How_to_install_Multimedia_Player_.28XMMS.29"></a>)]]
如何安装 Multimedia Player (XMMS)
sudo apt-get install xmms sudo apt-get install xmms-skins wget -c [http://easylinux.info/uploads/xmms-wma_1.0.4-2_i386.deb sudo dpkg -i xmms-wma_1.0.4-2_i386.deb
- Associate XMMS to play MP3/M3U/WAV files
sudo cp /usr/share/applications/defaults.list /usr/share/applications/defaults.list_backup sudo cp /usr/share/applications/defaults.list /tmp/defaults.list_tmp sudo sed -e 's/audio\/mpeg=.*/audio\/mpeg=XMMS.desktop/g' /tmp/defaults.list_tmp > /tmp/defaults.mp3 sudo sed -e 's/audio\/x-mpegurl=.*/audio\/x-mpegurl=XMMS.desktop/g' /tmp/defaults.mp3 > /tmp/defaults.m3u sudo sed -e 's/audio\/x-wav=.*/audio\/x-wav=XMMS.desktop/g' /tmp/defaults.m3u > /tmp/defaults.list sudo mv /tmp/defaults.list /usr/share/applications/defaults.list sudo rm -f /tmp/defaults.*
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> XMMS
[[HTML(<a name="How_to_install_Multimedia_Player_.28amaroK.29"></a>)]]
如何安装 Multimedia Player (amaroK)
sudo apt-get install amarok
- 应用程序 -> 影音 ->
amaroK
[[HTML(<a name="How_to_install_Multimedia_Player_.28RealPlayer_10.29"></a>)]]
如何安装 Multimedia Player (RealPlayer 10)
sudo apt-get install realplay
Note: 'realplay' installs RealPlayer 10 from PLF repository, which you should be enabled if you followed this guide. 'realplayer' installs RealPlayer 8 from multiverse.
- 应用程序 -> 影音 -> RealPlayer 10
- It will also install all the necessary plugins automagically for it to view embedded real videos in Firefox
- To avoid issues of flickering or screen going blank when switching windows, goto
- RealPlayer 10 -> Tools -> Preferences -> Hardware -> Uncheck XVideo
[[HTML(<a name="How_to_install_Stream_Directory_Browser_.28streamtuner.29"></a>)]]
如何安装 Stream Directory Browser (streamtuner)
sudo apt-get install streamtuner sudo apt-get install streamripper
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> streamtuner
[[HTML(<a name="How_to_install_Music_Organizer_.28Cowbell.29"></a>)]]
如何安装 Music Organizer (Cowbell)
sudo apt-get install cowbell
- 应用程序 -> 影音 -> Cowbell Music Organizer
[[HTML(<a name="How_to_install_ID3_Tag_Editor_.28EasyTAG.29"></a>)]]
如何安装 ID3 Tag Editor (EasyTAG)
sudo apt-get install easytag
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> EasyTAG
[[HTML(<a name="How_to_install_Video_Editor_.28Kino.29"></a>)]]
如何安装 Video Editor (Kino)
sudo apt-get install kino sudo apt-get install kinoplus sudo apt-get install kino-timfx sudo apt-get install kino-dvtitler
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> Kino Video Editor
[[HTML(<a name="How_to_install_Audio_Editor_.28Audacity.29"></a>)]]
如何安装 Audio Editor (Audacity)
sudo apt-get install audacity
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> Audacity
[[HTML(<a name="How_to_install_Music_Manager_and_Player_.28Banshee.29"></a>)]]
如何安装 Music Manager and Player (Banshee)
sudo apt-get install banshee
[[HTML(<a name="How_to_install_DVD_Ripper_.28dvd::rip.29"></a>)]]
如何安装 DVD Ripper (dvd::rip)
sudo apt-get install dvdrip vcdimager cdrdao subtitleripper sudo ln -fs /usr/bin/rar /usr/bin/rar-2.80 gksudo gedit /usr/share/applications/dvdrip.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=dvd::rip Comment=dvd::rip Exec=dvdrip Icon=/usr/share/perl5/Video/DVDRip/icon.xpm Terminal=false Type=Application Categories=Application;AudioVideo;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> dvd::rip
[[HTML(<a name="How_to_install_DVD_Ripper_.28AcidRip.29"></a>)]]
如何安装 DVD Ripper (AcidRip)
sudo apt-get install acidrip
- Read #如何刷新 GNOME 面板
Note: AcidRip will not recognize dvd if dma is turned on. If so undo the process #How to speed up CD/DVD-ROM.
[[HTML(<a name="How_to_install_CD_Ripper_.28Goobox.29"></a>)]]
如何安装 CD Ripper (Goobox)
sudo apt-get install goobox sudo rm -f /usr/share/applications/goobox.desktop gksudo gedit /usr/share/applications/goobox.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=CD Player & Ripper Comment=Play and extract CDs Exec=goobox Icon=goobox.png Terminal=false Type=Application Categories=Application;AudioVideo;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 -> CD Player & Ripper
[[HTML(<a name="How_to_install_Image_Viewer_.28digiKam.29"></a>)]]
如何安装 Image Viewer (digiKam)
sudo apt-get install digikam digikamimageplugins kipi-plugins
- 应用程序 -> 图像 -> digikam
[[HTML(<a name="How_to_install_Picasa_image_organizer"></a>)]]
如何安装 Picasa image organizer
gksudo gedit /etc/apt/sources.list
- Add the following lines at the end of file
# Google Picasa for Linux repository deb http://dl.google.com/linux/deb/ stable non-free
- 保存编辑好的文件
sudo apt-get update sudo apt-get install picasa
- 应用程序 -> 图像 -> Picasa
[[HTML(<a name="How_to_install_Vector_Graphics_Editor_.28Inkscape.29"></a>)]]
如何安装 Vector Graphics Editor (Inkscape)
sudo apt-get install inkscape
Second installation method:
1. Download the [http://prdownloads.sourceforge.net/inkscape/inkscape-0.44.x86.package?download official Inkscape Linux installer]. 2. Choose a mirror and save it to your Desktop. 3. Right-click it, enable "Properties --> Permissions --> Owner:Execute" and close the dialogue box. (One-time procedure) 4. Double-click it and follow the instructions. 5. Install the support code system-wide, if you have the root password. (One-time procedure)
NOTE: You can and should install the program as a User, rather than Root. This is easily accomplished with the second method.
[[HTML(<a name="How_to_install_Opera_web_browser"></a>)]]
如何安装 Opera web browser
sudo apt-get install opera
- 应用程序 -> Internet -> Opera
- To get java working go to Tools->Preferences->Advanced->Content-> Check "Enable Java". Click the "Enable Java..." button enter "/usr/lib/jvm/java-1.5.0-sun/jre/lib/i386" (for sun java) in the new dialog and then click the "Validate Java Path" button.
[[HTML(<a name="How_to_install_Email_Client_.28Mozilla_Thunderbird.29"></a>)]]
如何安装 Email Client (Mozilla Thunderbird)
sudo apt-get install mozilla-thunderbird
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> Thunderbird Mail Client
[[HTML(<a name="How_to_install_Newsreader_.28Pan.29"></a>)]]
如何安装 Newsreader (Pan)
sudo apt-get install pan
- 应用程序 -> Internet -> Pan Newsreader
[[HTML(<a name="How_to_install_RSS.2FRDF.2FAtom_Newsreader_.28RSSOwl.29"></a>)]]
如何安装 RSS/RDF/Atom Newsreader (RSSOwl)
wget -c [http://easylinux.info/uploads/rssowl_linux_1_1_3_bin.tar.gz sudo tar zxvf rssowl_linux_1_1_3_bin.tar.gz -C /opt/ sudo chown -R root:root /opt/rssowl_linux_1_1_3_bin/ gksudo gedit /usr/bin/runRSSOwl.sh
- 插入下面的行到新文件
export MOZILLA_FIVE_HOME=/usr/lib/mozilla-firefox export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${MOZILLA_FIVE_HOME}:${LD_LIBRARY_PATH} cd /opt/rssowl_linux_1_1_3_bin/ ./run.sh
- 保存编辑好的文件
sudo chmod +x /usr/bin/runRSSOwl.sh gksudo gedit /usr/share/applications/RSSOwl.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=RSSOwl Comment=RSSOwl Exec=runRSSOwl.sh Icon=/opt/rssowl_linux_1_1_3_bin/rssowl.xpm Terminal=false Type=Application Categories=Application;Network;
- 保存编辑好的文件
- 应用程序 -> Internet -> RSSOwl
[[HTML(<a name="How_to_install_Web_Authoring_System_.28Nvu.29"></a>)]]
如何安装 Web Authoring System (Nvu)
sudo apt-get install nvu sudo rm -f /usr/share/applications/nvu.desktop gksudo gedit /usr/share/applications/nvu.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=Nvu Comment=Web Development Editor Exec=nvu Icon=nvu.xpm Terminal=false Type=Application Categories=Application;Development;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> Nvu
[[HTML(<a name="How_to_install_Web_Development_Environment_.28quanta_plus.29"></a>)]]
如何安装 Web Development Environment (quanta plus)
sudo apt-get install quanta
- 应用程序 -> 编程 -> Quanta Plus
[[HTML(<a name="How_to_install_Project_Management_Application_.28Planner.29"></a>)]]
如何安装 Project Management Application (Planner)
sudo apt-get install planner
- Read #如何刷新 GNOME 面板
- 应用程序 -> 办公 -> Project Management
[[HTML(<a name="How_to_install_Accounting_Application_.28GnuCash.29"></a>)]]
如何安装 Accounting Application (GnuCash)
sudo apt-get install gnucash sudo rm -fr /usr/share/gnome/apps/Applications/ gksudo gedit /usr/share/applications/GnuCash.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=GnuCash Comment=GnuCash Personal Finance Exec=gnucash Icon=/usr/share/pixmaps/gnucash/gnucash-icon.png Terminal=false Type=Application Categories=Application;Office;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> 办公 -> GnuCash
[[HTML(<a name="How_to_install_Desktop_Publishing_Application_.28Scribus.29"></a>)]]
如何安装 Desktop Publishing Application (Scribus)
sudo apt-get install scribus
- Read #如何刷新 GNOME 面板
- 应用程序 -> 办公 -> Scribus
[[HTML(<a name="How_to_install_Diagram_Editor_.28Dia.29"></a>)]]
如何安装 Diagram Editor (Dia)
sudo apt-get install dia-gnome
- Read #如何刷新 GNOME 面板
- 应用程序 -> 图像 -> Dia
[[HTML(<a name="How_to_install_Compiled_HTML_Help_.28CHM.29_Viewer_.28xCHM.29"></a>)]]
如何安装 Compiled HTML Help (CHM) Viewer (xCHM)
sudo apt-get install xchm
- Read #如何刷新 GNOME 面板
- 应用程序 -> 图像 -> xCHM
[[HTML(<a name="How_to_install_CD.2FDVD_Burning_Application_.28GnomeBaker.29"></a>)]]
如何安装 CD/DVD Burning Application (GnomeBaker)
sudo apt-get install gnomebaker
- Read #如何刷新 GNOME 面板
- 应用程序 -> 影音 ->
GnomeBaker
[[HTML(<a name="How_to_install_CD.2FDVD_Burning_Application_.28K3b.29"></a>)]]
如何安装 CD/DVD Burning Application (K3b)
sudo apt-get install k3b libk3b2-mp3
- 应用程序 -> 影音 -> K3b
[[HTML(<a name="How_to_install_Dialup_PPP_Client_.28GNOME_PPP.29"></a>)]]
如何安装 Dialup PPP Client (GNOME PPP)
sudo apt-get install gnome-ppp
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> GNOME PPP
[[HTML(<a name="How_to_install_Broadband_ADSL.2FPPPoE_Client_.28RP-PPPoE.29"></a>)]]
如何安装 Broadband ADSL/PPPoE Client (RP-PPPoE)
wget -c http://easylinux.info/uploads/rp-pppoe-3.6.tar.gz sudo tar zxvf rp-pppoe-3.6.tar.gz -C /opt/ sudo chown -R root:root /opt/rp-pppoe-3.6/ gksudo gedit /usr/share/applications/RP-PPPoE.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=RP-PPPoE Comment=RP-PPPoE Exec=gksudo /opt/rp-pppoe-3.6/go-gui Icon=pppoeconf.xpm Terminal=false Type=Application Categories=Application;Network;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> Internet -> RP-PPPoE
[[HTML(<a name="How_to_install_Boot-Up_Manager_.28BUM.29"></a>)]]
如何安装 Boot-Up Manager (BUM)
sudo apt-get install bum
- Read #如何刷新 GNOME 面板
- 系统 -> 系统管理 -> Boot-Up Manager
[[HTML(<a name="How_to_install_Partition_Editor_.28GParted.29"></a>)]]
如何安装 Partition Editor (GParted)
sudo apt-get install gparted
- Read #如何刷新 GNOME 面板
- 应用程序 -> 系统工具 -> GParted
[[HTML(<a name="How_to_install_Firewall_.28Firestarter.29"></a>)]]
如何安装 Firewall (Firestarter)
sudo apt-get install firestarter
- Read #如何刷新 GNOME 面板
- 应用程序 -> 系统工具 -> Firestarter
[[HTML(<a name="How_to_install_network_traffic_analyzer_.28Ethereal.29"></a>)]]
如何安装 network traffic analyzer (Ethereal)
sudo apt-get install ethereal
- 应用程序 -> Internet -> Ethereal
[[HTML(<a name="How_to_install_Vulnerability_Scanner_.28Nessus.29"></a>)]]
如何安装 Vulnerability Scanner (Nessus)
sudo apt-get install nessus sudo apt-get install nessusd sudo nessus-adduser sudo ln -fs /etc/init.d/nessusd /etc/rc2.d/S20nessusd sudo /etc/init.d/nessusd start gksudo gedit /usr/share/applications/Nessus.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=Nessus Comment=Nessus Exec=nessus Icon=/usr/share/pixmaps/nessus.xpm Terminal=false Type=Application Categories=Application;System;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> 系统工具 -> Nessus
[[HTML(<a name="How_to_install_RAR_Archiver_.28rar.29"></a>)]]
如何安装 RAR Archiver (rar)
sudo apt-get install rar sudo ln -fs /usr/bin/rar /usr/bin/unrar
- 应用程序 -> Accessories -> Archive
Manager
[[HTML(<a name="How_to_install_Extra_Fonts"></a>)]]
如何安装 Extra Fonts
sudo apt-get install xfonts-intl-arabic sudo apt-get install xfonts-intl-asian sudo apt-get install xfonts-intl-chinese sudo apt-get install xfonts-intl-chinese-big sudo apt-get install xfonts-intl-european sudo apt-get install xfonts-intl-japanese sudo apt-get install xfonts-intl-japanese-big sudo apt-get install xfonts-intl-phonetic sudo apt-get install gsfonts-x11 sudo apt-get install msttcorefonts sudo fc-cache -f -v
Note: Ubuntu Dapper comes with the DejaVu fonts (derived from Bitstream Vera) and provides adequate support for Latin, Greek and Cyrillic based languages.
[[HTML(<a name="How_to_install_Chinese_Input_Method_.28SCIM.29"></a>)]]
如何安装 Chinese Input Method (SCIM)
The following advices are outdated and it could be hard to revert to normal afterwards. Please follow instead the official Ubuntu 6.06 Dapper Drake guide HERE
Please note that scim is now installed by default in Dapper, and installing Chinese, Japanese or Korean Support is done using System>Administration>Language Support. The wiki details the method more thoroughly
sudo apt-get install scim sudo apt-get install scim-chinese sudo apt-get install scim-config-socket sudo apt-get install scim-gtk2-immodule sudo apt-get install scim-tables-zh wget -c http://easylinux.info/uploads/fireflysung-1.3.0.tar.gz sudo tar zxvf fireflysung-1.3.0.tar.gz -C /usr/share/fonts/truetype/ sudo chown -R root:root /usr/share/fonts/truetype/fireflysung-1.3.0/ sudo fc-cache -f -v
- 系统 -> Preferences -> SCIM Input Method
Setup
- To activate SCIM
Press 'Ctrl + Space'
[[HTML(<a name="How_to_install_Desktop_Applets_.28gDesklets.29"></a>)]]
如何安装 Desktop Applets (gDesklets)
sudo apt-get install gdesklets sudo apt-get install gdesklets-data
- Read #如何刷新 GNOME 面板
- 应用程序 -> Accessories -> gDesklets
- For more info see: [17]
[[HTML(<a name="How_to_install_Basic_Compilers_.28build-essential.29"></a>)]]
如何安装 Basic Compilers (build-essential)
sudo apt-get install build-essential
[[HTML(<a name="How_to_install_Integrated_Development_Environment_.28Anjuta.29"></a>)]]
如何安装 Integrated Development Environment (Anjuta)
sudo apt-get install anjuta
- 应用程序 -> 编程 -> Anjuta IDE
[[HTML(<a name="How_to_install_C.23_Integrated_Development_Environment_.28MonoDevelop.29"></a>)]]
如何安装 C# Integrated Development Environment (MonoDevelop)
sudo apt-get install mono mono-gmcs mono-gac mono-utils monodevelop
[[HTML(<a name="How_to_install_3D_modeling_tool_.28Blender_3d.29"></a>)]]
如何安装 3D modeling tool (Blender 3d)
sudo apt-get install blender
- 应用程序 -> 图像 -> Blender 3D modeller
[[HTML(<a name="How_to_install_game_Tuxracer"></a>)]]
如何安装 game Tuxracer
sudo apt-get install planetpenguin-racer planetpenguin-racer-data planetpenguin-racer-extras
- 应用程序 -> Games -> planetpenguin-racer
[[HTML(<a name="How_to_install_game_Frozen-Bubble"></a>)]]
如何安装 game Frozen-Bubble
sudo apt-get install frozen-bubble
- 应用程序 -> Games -> Frozen-Bubble
[[HTML(<a name="How_to_install_game_Scorched3D"></a>)]]
如何安装 game Scorched3D
sudo apt-get install scorched3d gksudo gedit /usr/share/applications/scorched3d.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=Scorched 3D Comment=A 3D Remake Of Scorched Earth Exec=scorched3d Icon= Terminal=false Type=Application Categories=Application;Game;ArcadeGame;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- 应用程序 -> Games -> Scorched 3D
[[HTML(<a name="How_to_install_virtual_planetarium_.28Stellarium.29"></a>)]]
如何安装 virtual planetarium (Stellarium)
sudo apt-get install stellarium gksudo gedit /usr/share/applications/stellarium.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=Stellarium Comment=Virtual planetarium Exec=stellarium Terminal=false Type=Application Categories=Application;Education;
- 应用程序 -> Education -> Stellarium
Second installation method: (version 0.6.2)
1. Download the [http://bylands.dur.ac.uk/%7Emh/stellarium-0.6.2.x86.package Stellarium Linux installer]. 2. Save it to your Desktop. 3. Right-click it, enable "Properties --> Permissions --> Owner:Execute" and close the dialogue box. (One-time procedure) 4. Double-click it and follow the instructions. 5. Install the support code system-wide, if you have the root password. (One-time procedure)
NOTE: You can and should install the program as a User, rather than Root. This is easily accomplished with the second method.
[[HTML(<a name="How_to_install_Google_Toolbar_for_Firefox"></a>)]]
如何安装 Google Toolbar for Firefox
The current version of Google Toolbar works fine with Firefox 1.5.0.5 in Ubuntu 6.06
In Firefox, click the link below [18]
then click on the big download button.
[[HTML(<a name="How_to_install_Google_Earth"></a>)]]
如何安装 Google Earth
wget -c http://dl.google.com/earth/GE4/GoogleEarthLinux.bin sudo sh GoogleEarthLinux.bin
- Leave /usr/local/google-earth as the
installation path
- After installation click Exit. If you
instead chose to run the application, read the Note below.
sudo cp /usr/local/google-earth/googleearth.desktop /usr/share/applications/
- 应用程序 -> Internet -> Google Earth
- Note: If you run Google Earth for the first time from the installer, it will require root privileges to run the next time. To fix that:
sudo chmod 777 -R ~/.googleearth
[[HTML(<a name="How_to_install_KDE_Edutainment_applications"></a>)]]
如何安装 KDE Edutainment applications
sudo apt-get install kdeedu
- 应用程序 -> Education -> ...
[[HTML(<a name="How_to_install_Internet_Explorer_.2B_Flash_9"></a>)]]
如何安装 Internet Explorer + Flash 9
This will install a wine'd version of Internet Explorer 6 with Flash 9, as well as IE 5.5/5.01 if you really want them.
- Note: Flash 9 will NOT
be available in browsers other than IE.
- Open a terminal and run this:
wget http://www.tatanka.com.br/ies4linux/downloads/ies4linux-2.0.tar.gz -O - | tar xvzf -
- Or, if that doesn't work, use this command:
wget http://modzer0.cs.uaf.edu/~hardwarehank/files/ies4linux-2.0.tar.gz -O - | tar xvzf -
- Then, just run it:
cd ies4linux-2.0 sh ies4linux
You don't have to run it as root (no sudo). If you do, it will make global symlinks, which is fine if you want that. Otherwise, it will use ~/bin. Read the README:
less README
[[HTML(<a name="How_to_install_Windows_Applications_in_Linux_.28Wine.29"></a>)]]
如何安装 Windows Applications in Linux (Wine)
Wine Is Not an Emulator. Wine is an Open Source implementation of the Windows API on top of X and Unix. Think of Wine as a compatibility layer for running Windows programs. Wine does not require Microsoft Windows, as it is a completely free alternative implementation of the Windows API consisting of 100% non-Microsoft code, however Wine can optionally use native Windows DLLs if they are available.
In other words, Wine will let you run Windows applications in Linux.
- First, add repository for Wine:
gksudo gedit /etc/apt/sources.list
- Add the following lines at the end of this file
# Repository for wine deb http://wine.budgetdedicated.com/apt dapper main deb-src http://wine.budgetdedicated.com/apt dapper main
- 保存编辑好的文件
sudo apt-get update sudo apt-get install wine
- For more info see [19]
[[HTML(<a name="How_to_install_a_Drop_Down_Terminal_like_in_First_Person_Shooters_.28tilda.29"></a>)]]
如何安装 a Drop Down Terminal like in First Person Shooters (tilda)
Do you want a console like in a first person shooter? Tilda should take care of you.
sudo apt-get install tilda
- The default keybinding is F1. To change the default keybinding, either enter tilda -C at the terminal, or right click on the tilda terminal then click Preferences. While in preferences, you can change other things such as transparency, font, size, and window size.
[[HTML(<a name="Other_Desktop_Environments"></a>)]]
Other Desktop Environments
[[HTML(<a name="How_to_install_KDE"></a>)]]
如何安装 KDE
- You may also look at some KDE Screenshots
sudo apt-get install kubuntu-desktop
Note: This installation will require ~400MB of disk space
- 系统 -> Log Out -> Log Out
- To log in to KDE click on Sessions and choose KDE
[[HTML(<a name="How_to_install_XFCE"></a>)]]
如何安装 XFCE
- You may also look at some XFCE Screenshots
sudo apt-get install xubuntu-desktop
- 系统 -> Log Out -> Log Out
- To log in to XFCE click on Sessions and choose XFCE
[[HTML(<a name="How_to_install_XFCE_4.4_preview_versions_.284.3.90.1.29"></a>)]]
如何安装 XFCE 4.4 preview versions (4.3.90.1)
- to install Xfce 4.4 beta 1 (4.3.90.1) on a fresh install of Dapper:
- download the Xfce 4.4 preview versions installer (see [20])
sudo apt-get install build-essential gcc pkg-config libglib2.0-0 \ libglib2.0-dev libgtk2.0-0 libgtk2.0-dev libxml++2.6c2a libxml++2.6-dev \ libvte-dev libvte4 a2ps libxpm-dev libxpm4 alsa-source alsa alsa-base \ alsa-oss alsa-utils libxml-parser-perl libpng12-0 libpng12-dev libdbh1.0-dev
chmod +x xfce4-4.3.90.1-installer.bin sudo ./xfce4-4.3.90.1-installer.bin
- on installer, use default setting, except:
Extensive Optimizations, can be truned on for 386
Use ALSA for the Xfce Mixer, can be turned off
(see [21])
- finally to enable Xfce, you may need to enable it on the desktop manager (mark allow Xfce manage desktop)
[[HTML(<a name="How_to_install_FluxBox"></a>)]]
如何安装 FluxBox
Here's some Screenshots. Fluxbox is a popular minimalist Window Manager.
sudo apt-get install fluxbox
[[HTML(<a name="Make_it_start_when_you_login_thru_GDM"></a>)]]
Make it start when you login thru GDM
echo "exec startfluxbox" > ~/.xinitrc
[[HTML(<a name="Make_it_make_the_pretty_sound_on_login"></a>)]]
Make it make the pretty sound on login
sudo apt-get install sox gedit ~/.fluxbox/startup
- 查找如下行:
exec /usr/local/bin/fluxbox
- Put this above it somewhere:
play /usr/share/sounds/login.wav > /dev/null 2>&1 &
- Listen happily.
[[HTML(<a name="Eye_Candy"></a>)]]
Eye Candy
[[HTML(<a name="How_to_install_Xgl.2FCompiz_.28Nvidia.29"></a>)]]
如何安装 Xgl/Compiz (Nvidia)
- For complete info on how to set up XGL on different cards and some tweaks see: [22]
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf_backup gksudo gedit /etc/X11/xorg.conf
- 查找下面的段
Section "Module" Load "i2c" Load "bitmap" ... Load "type1" Load "vbe" EndSection
- Comment out dri and GLcore (if present)
# Load "dri" # Load "GLcore"
- Make sure the glx module is loaded
Load "glx"
- 查找下面的段 (your values may vary)
Section "Device" Identifier "NVIDIA Corporation NV34M [GeForce FX Go5200]" Driver "nv" BusID "PCI:1:0:0" EndSection
- 使用下面的行替换, leaving the Identifier and BusID as it is
Section "Device" ... Driver "nvidia" ... Option "RenderAccel" "true" Option "AllowGLXWithComposite" "true" EndSection
- 查找下面的段
Section "Screen" Identifier "Default Screen" Device "NVIDIA Corporation NV34M [GeForce FX Go5200]" Monitor "Generic Monitor" DefaultDepth 16
- Make sure DefaultDepth is set to 24, if it isn't already
DefaultDepth 24
- 保存编辑好的文件
- Install Xgl/Compiz
sudo apt-get install compiz xserver-xgl libgl1-mesa xserver-xorg libglitz-glx1 compiz-gnome sudo cp /etc/gdm/gdm.conf-custom /etc/gdm/gdm.conf-custom-backup gksudo gedit /etc/gdm/gdm.conf-custom
- Replace everything with the following lines
# GDM Configuration Customization file. # # This file is the appropriate place for specifying your customizations to the # GDM configuration. If you run gdmsetup, it will automatically edit this # file for you and will cause the daemon and any running GDM GUI programs to # automatically update with the new configuration. Not all configuration # options are supported by gdmsetup, so to modify some values it may be # necessary to modify this file directly by hand. # # To hand-edit this file, simply add or modify the key=value combination in # the appropriate section in the template below. Refer to the comments in the # gdm.conf file for information about each option. Also refer to the reference # documentation. # # If you hand edit a GDM configuration file, you should run the following # command to get the GDM daemon to notice the change. Any running GDM GUI # programs will also be notified to update with the new configuration. # # gdmflexiserver --command="UPDATE_CONFIG <configuration key>" # # For example, the "Enable" key in the "[debug]" section would be specified by # "debug/Enable". # # You can also run gdm-restart or gdm-safe-restart to cause GDM to restart and # re-read the new configuration settings. You can also restart GDM by sending # a HUP or USR1 signal to the daemon. HUP behaves like gdm-restart and causes # any user session started by GDM to exit immediately while USR1 behaves like # gdm-safe-restart and will wait until all users log out before restarting GDM. # # For full reference documentation see the gnome help browser under # GNOME|System category. You can also find the docs in HTML form on # [http://www.gnome.org/projects/gdm/] # # NOTE: Lines that begin with "#" are considered comments. # # Have fun! [daemon] [security] [xdmcp] [gui] [greeter] [chooser] [debug] [servers]# Override display 1 to use Xgl 0=Xgl [server-Xgl] name=Xgl server command=/usr/bin/Xgl :0 -fullscreen -ac -accel glx:pbuffer -accel xv:fbo flexible=true
- Create a script that runs Xgl/Compiz on startup
gksudo gedit /usr/bin/thefuture
- 插入下面的行到新文件. Replace .us with appropriate keyboard binding for your region. Eg .gb for United Kingdom. For a full list of keyboard bindings, type ls /usr/share/xmodmap in a terminal. If unsure, leave as .us (United States)
#!/bin/bash gnome-window-decorator & compiz --replace gconf decoration wobbly fade minimize cube rotate zoom scale move resize place switcher & xmodmap /usr/share/xmodmap/xmodmap.us
- Save the file
sudo chmod 755 /usr/bin/thefuture
- To run compiz for this session
thefuture
- To have compiz load on startup
- 系统 -> Preferences -> Sessions
- Startup Programs -> Add
/usr/bin/thefuture
- Click Ok, then Close
- Troubleshooting
- If Xgl/Compiz doesn't seem to work, or you get errors, simply restart your machine after adding "thefuture" to Startup programs
- If moving windows slows down the system, run gconf-editor from the terminal. Find apps/compiz/general/screen0/options. Disable detect_refresh_rate and set refresh rate to 60. Everything should work fine now...
- If you are using a non default keyboard layout (other language), you might have to change it back to what you need if the keyboard acts funny at System/Settings/Keyboard.
- You can also set the Super-key to the windows button here.
- If you don't want "bottom expanded panel", type "killall gnome-panel" in terminal.
- Tips
- Switch windows = Alt + Tab
- Arrange and View All Windows = F12 turns on or off; clicking a window will zoom it to the front
- Switch desktops on cube = Ctrl + Alt + Left/Right Arrow
- Switch desktops on cube - with active window following = Ctrl + Shift + Alt + Left/Right Arrow
- Rotate cube manually = Ctrl + Alt + left-click
- Make window translucent/opaque = currently only possible with the "transset" utility
- Zoom-in once = Super-key right-click
- Zoom-in manually = Super-key + wheel mouse up
- Zoom-out manually = Super-key + wheel mouse down
- Move window = Alt + left-click
- Snap Move window (will stick to borders) = Ctrl + Alt +left-click
- Resize window = Alt + right-click
[[HTML(<a name="How_to_install_Xgl.2FCompiz_.28ATI.29"></a>)]]
如何安装 Xgl/Compiz (ATI)
- See [23]
[[HTML(<a name="How_to_install_alternate_boot_splash_screen"></a>)]]
如何安装 alternate boot splash screen
- This installs a minimalistic splash screen that appears when the computer is booting up and shutting down. It is devoid of any text messages.
wget -c http://www.users.on.net/%7Estubby/usplash-minimalistic_0.1.deb sudo dpkg -i usplash-minimalistic_0.1.deb sudo update-alternatives --config usplash-artwork.so
- Select the minimalistic alternative (/usr/local/lib/usplash/minimalastic.so) by entering the corresponding number. If you ever want to revert back to the original splash, select the default (/usr/lib/usplash/usplash-default.so)
- 重启 your computer to see the effects
- See the official USplash Customization HOWTO for more customization.
[[HTML(<a name="Commercial_Applications"></a>)]]
Commercial Applications
[[HTML(<a name="How_to_install_Windows_9X.2FME.2F2000.2FXP_.28Win4Lin.29"></a>)]]
如何安装 Windows 9X/ME/2000/XP (Win4Lin)
[[HTML(<a name="How_to_install_Windows_Applications_.28CrossOver_Office.29"></a>)]]
如何安装 Windows Applications (CrossOver Office)
[[HTML(<a name="How_to_install_Windows_Games_.28Cedega.29"></a>)]]
如何安装 Windows Games (Cedega)
[[HTML(<a name="User_Administration"></a>)]]
User Administration
[[HTML(<a name="How_to_set.2Fchange.2Fenable_root_user_password"></a>)]]
如何 set/change/enable root user password
sudo passwd root
[[HTML(<a name="How_to_disable_root_user_account"></a>)]]
如何 disable root user account
sudo passwd -l root
[[HTML(<a name="How_to_allow_root_user_to_login_into_GNOME"></a>)]]
如何 allow root user to login into GNOME
- 系统 -> 系统管理 -> Login Screen Setup
- Login Screen Setup
Security Tab -> Security -> Allow root to login with GDM ('''Checked''')
[[HTML(<a name="How_to_switch_to_root_user_in_Console_mode"></a>)]]
如何 switch to root user in Console mode
sudo -s -H Password: <specify user password>
[[HTML(<a name="How_to_add.2Fedit.2Fdelete_system_users"></a>)]]
如何 add/edit/delete system users
- 系统 -> 系统管理 -> Users and Groups
- Users and Groups
Users Tab -> Add User.../Properties/Delete
or
sudo useradd jim sudo userdel jim
- For more info read
man usermod
[[HTML(<a name="How_to_add.2Fedit.2Fdelete_system_groups"></a>)]]
如何 add/edit/delete system groups
- 系统 -> 系统管理 -> Users and Groups
- Users and Groups
Groups Tab -> Add Group.../Properties/Delete
[[HTML(<a name="How_to_automatic_login_into_GNOME_.28not_secure.29"></a>)]]
如何 automatic login into GNOME (not secure)
- 系统 -> 系统管理 -> Login Window
Security Tab -> Enable Automatic Login ('''Checked''') Now choose a user from the drop-down menu.
[[HTML(<a name="How_to_allow_more_sudoers"></a>)]]
如何 allow more sudoers
EDITOR=gedit sudo visudo
- Append the following line at the end of file
system_username ALL=(ALL) ALL
- 保存编辑好的文件
OR since everyone in the admin group can use sudo:
sudo adduser a_username admin
This appends the admin group to the user's supplementary group list. They will now have sudo access.
[[HTML(<a name="How_to_use_.22sudo.22_without_prompt_for_password_.28not_secure.29"></a>)]]
如何 use "sudo" without prompt for password (not secure)
EDITOR=gedit sudo visudo
- 查找如下行
... system_username ALL=(ALL) ALL ...
- 使用下面的行替换
system_username ALL=(ALL) NOPASSWD: ALL
- 保存编辑好的文件
[[HTML(<a name="How_to_explicitly_destroy_the_.22sudo.22_session"></a>)]]
如何 explicitly destroy the "sudo" session
sudo -K
[[HTML(<a name="How_to_change_files.2Ffolders_permissions"></a>)]]
如何 change files/folders permissions
Right click on files/folders -> '''Properties'''
Permissions Tab -> Read/Write/Execute (Checked the permissions for Owner/Group/Others)
[[HTML(<a name="How_to_change_files.2Ffolders_ownership"></a>)]]
如何 change files/folders ownership
sudo chown system_username /location_of_files_or_folders
[[HTML(<a name="How_to_change_files.2Ffolders_group_ownership"></a>)]]
如何 change files/folders group ownership
sudo chgrp system_groupname /location_of_files_or_folders
[[HTML(<a name="Hardware"></a>)]]
Hardware
[[HTML(<a name="Configure_Ubuntu_for_multi-button_Mouse"></a>)]]
Configure Ubuntu for multi-button Mouse
[[HTML(<a name="Activate_side-mouse-buttons_in_FireFox"></a>)]]
Activate side-mouse-buttons in FireFox
Just add two lines to xorg.conf will activate side-mouse-buttons in FireFox. This should work with most 5-button mouse. Here is a list of mice that worked with this instruction.
Logitech MX510 Logitech MX518
Backup Gnome configuration file
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.bak
Modify the Gnome configuration file
gksudo gedit /etc/X11/xorg.conf
Find the Input Device section for your mouse and add two lines as shown below. You may also increase the number of buttons if your mouse has more than 7, just fix the rest of the section based upon the number of buttons (remember back/forward, wheel click & tilt left/right all count as buttons)
Change:
Section "InputDevice" Identifier "Configured Mouse" Driver "mouse" Option "CorePointer" ... Option "Protocol" "ExplorerPS/2" ... Option "Emulate3Buttons" "true" EndSection
to:
Section "InputDevice" Identifier "Configured Mouse" Driver "mouse" Option "CorePointer" ... Option "Protocol" "ExplorerPS/2" ... Option "Emulate3Buttons" "true" Option "Buttons" "7" Option "ButtonMapping" "1 2 3 6 7" EndSection
At this point you can reboot your computer or reboot Gnome (Ctrl-Alt-BackSpace) to see if your forward/back buttons work in FireFox. They still won't work in Nautilus yet until you install the imwheel dameon.
[[HTML(<a name="Install_.26_Configure_IMWheel"></a>)]]
Install & Configure IMWheel
- Install IMWheel
sudo apt-get install imwheel
- Modify IMWheel configuration file
gksudo gedit /etc/X11/imwheel/imwheelrc
- Insert the following at the bottom of this existing file
".*" None, Up, Alt_L|Left None, Down, Alt_L|Right "(null)" None, Up, Alt_L|Left None, Down, Alt_L|Right
- Create IMWheel start-up script
sudo mkdir /home/login gksudo gedit /home/login/mouse
- Insert the following into this new file
#!/bin/sh exec xmodmap -e "pointer = 1 2 3 6 7 4 5" & exec imwheel -k -b "67" & exec $REALSTARTUP
- Grant execution for everyone to this new script
sudo chmod +x /home/login/mouse
- Configure this script to be executed at start-up
- Select 'System' > 'Preferences' > 'Sessions'
- Click the StartUp tab
- Click Add, then input: /home/login/mouse
- Click OK, then Close
- Reboot your computer or your Gnome environment and then test your back/forward mouse buttons in Nautilus
[[HTML(<a name="How_to_install_Graphics_Driver_.28NVIDIA.29"></a>)]]
如何安装 Graphics Driver (NVIDIA)
sudo apt-get install nvidia-glx nvidia-kernel-common sudo nvidia-glx-config enable
[[HTML(<a name="How_to_disable_NVIDIA_graphics_logo_on_GNOME_startup"></a>)]]
如何 disable NVIDIA graphics logo on GNOME startup
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf_backup gksudo gedit /etc/X11/xorg.conf
- 查找下面的段
... Section "Device" Identifier "NVIDIA Corporation NV11 [GeForce2 MX/MX 400]" Driver "nvidia" BusID "PCI:1:0:0" ...
- Add the following line below it
Option "NoLogo"
- 保存编辑好的文件
- Read #How to restart GNOME without rebooting computer
[[HTML(<a name="How_to_install_Graphics_Driver_.28ATI.29"></a>)]]
如何安装 Graphics Driver (ATI)
[[HTML(<a name="How_to_monitor_CPU.2C_GPU_temperatures.2C_fan_speeds_and_voltages_.28GKrellM.29"></a>)]]
如何 monitor CPU, GPU temperatures, fan speeds and voltages (GKrellM)
GKrellM is a hardware monitor that can display CPU and GPU temperatures, fan speeds, voltages, CPU load, network load, disk activity, memory usage, and swap usage. The installation is very easy, and configuration is just a few mouse-clicks. You can set alerts to warn you if the CPU is too hot or there is a fan failure..
sudo apt-get install gkrellm
To run the program
Click 应用程序 -> 系统工具 -> GKrellM
To configure the settings,
Right click on GKrellM -> Configuration
I was struggling with lm_sensors before, but it doesn't detect all of the sensors on my computer, and the installation/configuration is a bit tedious. Later I found "GKrellM", which works much better. It displays the GPU temperature on my nVidia 6600 GT out of the box. GKrellM also has plugins that show weather info, set reminders, etc.
Add an audio alert (optional Step): Here is how to play an audio message when the CPU is too hot or a fan fails. First you need to find or record your own audio alert files. (I use Audacity to record my own.) Then go to:
Configuration -> Builtins folder (Left side)-> Sensors -> Temperatures folder (Right side)-> CPU -> Alerts Button
Paste ONE of the following lines into a Terminal window first to test the sound. If you have two sound cards, you can use "-ao oss:/dev/dsp1" option to route the sound to the second sound card. Modify the file path and name so it points to the correct file. If you can hear the sound, then copy that line to a command line text field on the GKrellM's Alerts window.
mplayer /home/myfolder/alert_messages/heat_alert.mp3 mplayer -ao oss:/dev/dsp1 /home/myfolder/alert_messages/heat_alert.mp3
[[HTML(<a name="How_to_identify_Modem_chipset"></a>)]]
如何 identify Modem chipset
- To install Modem chipset identifier
wget -c http://easylinux.info/uploads/scanModem.gz gunzip -c scanModem.gz > scanModem chmod +x scanModem sudo cp scanModem /usr/bin/
- To identify Modem chipset
sudo scanModem gedit Modem/ModemData.txt
[[HTML(<a name="How_to_install_Windows_Wireless_Drivers_.28Ndiswrapper.29"></a>)]]
如何安装 Windows Wireless Drivers (Ndiswrapper)
- In order to install ndiswrapper you need a copy the windows drivers for your Wireless ethernet device.
- This is only ment to be installed if your card isn't supported.
- Please visit Official supported cards list
sudo apt-get install ndiswrapper-utils sudo ndiswrapper -i /location_of_your_wireless_driver/your_driver.inf sudo ndiswrapper -l
- Unload ACX module and load ndiswrapper
lsmod | grep acx sudo rmmod acx (only if the module was found. It could also be acx_pci or similar) modprobe ndiswrapper
- Set ndiswrapper to load on startup
sudo ndiswrapper -m gksudo gedit /etc/modules
- Add the following module to the list
ndiswrapper
- Now you can configure your wireless card with ifconfig and
iwconfig.
e.g. Supposing wlan0 is your wireless device.
sudo iwconfig wlan0 essid "AP" key ababababababababab mode Managed iwconfig
- You sould now be able to see the MAC address of the access point and signal rate.
[[HTML(<a name="How_to_install_Modem_Driver_.28SmartLink.29"></a>)]]
如何安装 Modem Driver (SmartLink)
uname -r (must be 2.6.10-5-386) wget -c http://easylinux.info/uploads/sl-modem-modules-2.6.10-5-386_2.9.9a-1ubuntu2+2.6.10-34_i386.deb sudo dpkg -i sl-modem-modules-*.deb sudo apt-get install sl-modem-daemon
[[HTML(<a name="How_to_configure_PalmOS_Devices"></a>)]]
如何配置 PalmOS Devices
gksudo gedit /etc/udev/rules.d/10-custom.rules
- Insert the following line into the new file
BUS="usb", SYSFS{product}="Palm Handheld*", KERNEL="ttyUSB*", NAME{ignore_remove}="pilot", MODE="666"
- 保存编辑好的文件
- Add the pilot-applet to the Taskbar by Right-Clicking on an empty spot
- Follow the instructions on screen
[[HTML(<a name="How_to_list_partition_tables"></a>)]]
如何 list partition tables
sudo fdisk -l
- You can also use 系统 -> 系统管理 -> Disks
[[HTML(<a name="How_to_list_filesystem_disk_space_usage"></a>)]]
如何 list filesystem disk space usage
df -Th
- You can also use 系统 -> 系统管理 -> Disks
[[HTML(<a name="How_to_list_mounted_devices"></a>)]]
如何 list mounted devices
mount
[[HTML(<a name="How_to_list_PCI_devices"></a>)]]
如何 list PCI devices
lspci
[[HTML(<a name="How_to_list_USB_devices"></a>)]]
如何 list USB devices
lsusb
[[HTML(<a name="How_to_speed_up_CD.2FDVD-ROM"></a>)]]
如何 speed up CD/DVD-ROM
e.g. Assumed that /dev/cdrom is the location of CD/DVD-ROM
sudo hdparm -d1 /dev/cdrom sudo cp /etc/hdparm.conf /etc/hdparm.conf_backup gksudo gedit /etc/hdparm.conf
- 在文件的结束增加下面的行
/dev/cdrom { dma = on }
- 保存编辑好的文件
[[HTML(<a name="How_to_mount.2Funmount_CD.2FDVD-ROM_manually.2C_and_show_all_hidden_and_associated_files.2Ffolders"></a>)]]
e.g. Assumed that /media/cdrom0/ is the location of CD/DVD-ROM
- To mount CD/DVD-ROM
sudo mount /media/cdrom0/ -o unhide
- To unmount CD/DVD-ROM
sudo umount /media/cdrom0/
[[HTML(<a name="How_to_forcefully_unmount_CD.2FDVD-ROM_manually"></a>)]]
如何 forcefully unmount CD/DVD-ROM manually
e.g. Assumed that /media/cdrom0/ is the location of CD/DVD-ROM
sudo umount /media/cdrom0/ -l
[[HTML(<a name="How_to_remount_.2Fetc.2Ffstab_without_rebooting"></a>)]]
如何 remount /etc/fstab without rebooting
sudo mount -a
[[HTML(<a name="How_to_install_a_Wacom_tablet"></a>)]]
如何安装 a Wacom tablet
For a detailed guide with screenshots about how to configure the "Extended input devices" in your graphic applications, please follow the official Dapper guide at [27]
With the version of the Linux Wacom driver (0.7.2) in Ubuntu 6.06 Dapper Drake, if you unplug you tablet, it won't function when you plug it back in and you will have to restart X. For this reason, it is best to leave the tablet plugged in. This limitation will be removed when the 0.7.4 version of the driver is included in Ubuntu.
- 1. Using Synaptic package manager1, check if the packages xserver-xorg-input-wacom and wacom-tools are already installed - if not, install them. If you prefer using the command line, you can also execute :
sudo apt-get install xserver-xorg-input-wacom wacom-tools
- 2. Save a copy of your /etc/X11/xorg.conf :
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
- then edit it with the command line :
gksudo gedit /etc/X11/xorg.conf
- and change all /dev/wacom occurences into /dev/input/wacom (created by wacom-tools udev scripts), then save the file.
- You should be ready to go after you have restarted X. Remember to configure the "Extended input devices" in your graphic applications (Gimp, Inkscape), however you can already check if it's working by moving your stylus on the tablet : the mouse cursor should go through the whole screen.
[[HTML(<a name="CD.2FDVD_Burning"></a>)]]
CD/DVD Burning
[[HTML(<a name="How_to_blank_CD-RW.2FDVD-RW"></a>)]]
如何 blank CD-RW/DVD-RW
e.g. Assumed that /dev/cdrom is the location of CD/DVD-ROM
sudo umount /dev/cdrom cdrecord dev=/dev/cdrom blank=fast
[[HTML(<a name="How_to_burn_files.2Ffolders_into_CD.2FDVD"></a>)]]
如何 burn files/folders into CD/DVD
nautilus burn:///
- File Browser: CD/DVD Creator
- Drag files/folders into window
File 菜单 -> Write to Disc... -> Write
[[HTML(<a name="How_to_burn_Image_.28ISO.29_files_into_CD.2FDVD"></a>)]]
如何 burn Image (ISO) files into CD/DVD
Right click on Image (ISO) file -> Write to Disc... -> Write
[[HTML(<a name="How_to_duplicate_CD.2FDVD"></a>)]]
如何 duplicate CD/DVD
[[HTML(<a name="How_to_create_Image_.28ISO.29_files_from_CD.2FDVD"></a>)]]
如何 create Image (ISO) files from CD/DVD
e.g. Assumed that /dev/cdrom is the location of CD/DVD-ROM
sudo umount /dev/cdrom dd if=/dev/cdrom of=file.iso bs=1024
[[HTML(<a name="How_to_create_Image_.28ISO.29_files_from_folders"></a>)]]
如何 create Image (ISO) files from folders
mkisofs -o file.iso /location_of_folder/
[[HTML(<a name="How_to_generate_MD5_checksum_files"></a>)]]
如何 generate MD5 checksum files
md5sum file.iso > file.iso.md5
[[HTML(<a name="How_to_check_MD5_checksum_of_files"></a>)]]
如何 check MD5 checksum of files
e.g. Assumed that file.iso and file.iso.md5 are in the same folder
md5sum -c file.iso.md5
[[HTML(<a name="How_to_mount.2Funmount_Image_.28ISO.29_files_without_burning"></a>)]]
如何 mount/unmount Image (ISO) files without burning
- To mount Image (ISO) file
sudo mkdir /media/iso sudo modprobe loop sudo mount file.iso /media/iso/ -t iso9660 -o loop
- To unmount Image (ISO) file
sudo umount /media/iso/
[[HTML(<a name="How_to_set.2Fchange_the_burn_speed_for_CD.2FDVD_Burner"></a>)]]
如何 set/change the burn speed for CD/DVD Burner
- 应用程序 -> 系统工具 -> Configuration Editor
- Configuration Editor
/ -> apps -> nautilus-cd-burner -> default_speed (set/change the burn speed)
[[HTML(<a name="How_to_enable_burnproof_for_CD.2FDVD_Burner"></a>)]]
如何 enable burnproof for CD/DVD Burner
- 应用程序 -> 系统工具 -> Configuration Editor
- Configuration Editor
/ -> apps -> nautilus-cd-burner -> burnproof ('''Checked''')
[[HTML(<a name="How_to_enable_overburn_for_CD.2FDVD_Burner"></a>)]]
如何 enable overburn for CD/DVD Burner
- 应用程序 -> 系统工具 -> Configuration Editor
- Configuration Editor
/ -> apps -> nautilus-cd-burner -> overburn ('''Checked''')
[[HTML(<a name="Networking"></a>)]]
Networking
[[HTML(<a name="How_to_configure_Google_Talk"></a>)]]
如何配置 Google Talk
- See the answer at Google Talk Help Center
[[HTML(<a name="How_to_activate.2Fdeactivate_network_connections"></a>)]]
如何 activate/deactivate network connections
- 系统 -> 系统管理 -> Networking
- Network settings
Connections Tab -> Select "Ethernet connection" -> Activate/Deactivate
[[HTML(<a name="How_to_configure_network_connections"></a>)]]
如何配置 network connections
- 系统 -> 系统管理 -> Networking
- Network settings
Connections Tab -> Select "Ethernet connection" -> '''Properties''' Connection -> Enable this connection ('''Checked''') Connection Settings -> Configuration: Select "DHCP/Static IP address"
DNS Tab -> DNS Servers -> Add/Delete
[[HTML(<a name="How_to_configure_dialup_connections"></a>)]]
如何配置 dialup connections
- To configure dialup
sudo pppconfig
- To connect dialup
sudo pon provider_name
- To disconnect dialup
sudo poff
[[HTML(<a name="How_to_configure_broadband_connections"></a>)]]
如何配置 broadband connections
sudo pppoeconf
[[HTML(<a name="How_to_change_computer_name"></a>)]]
如何 change computer name
- 系统 -> 系统管理 -> Networking
- Network settings
General Tab -> Host Settings -> Hostname: Specify the computer name
- Save and close all opened applications, Reboot computer
[[HTML(<a name="How_to_change_computer_descriptions"></a>)]]
如何 change computer descriptions
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... server string = %h server (Samba, Ubuntu) ...
- 使用下面的行替换
server string = new_computer_descriptions
- 保存编辑好的文件
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_change_computer_Domain.2FWorkgroup"></a>)]]
如何 change computer Domain/Workgroup
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... workgroup = MSHOME ...
- 使用下面的行替换
workgroup = new_domain_or_workgroup
- 保存编辑好的文件
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_assign_Hostname_to_local_machine_with_dynamic_IP_using_free_DynDNS_service"></a>)]]
如何 assign Hostname to local machine with dynamic IP using free DynDNS service
- Register free Dynamic DNS at [28]
sudo apt-get install ipcheck gksudo gedit /etc/ppp/ip-up.d/dyndns_update.sh
- 插入下面的行到新文件
#!/bin/sh USERNAME=myusername PASSWORD=mypassword HOSTNAME=myhostname.dyndns.org cd /root/ if [ -f /root/ipcheck.dat ]; then ipcheck -r checkip.dyndns.org:8245 $USERNAME $PASSWORD $HOSTNAME else ipcheck --makedat -r checkip.dyndns.org:8245 $USERNAME $PASSWORD $HOSTNAME fi
- 保存编辑好的文件
sudo chmod 700 /etc/ppp/ip-up.d/dyndns_update.sh sudo sh /etc/ppp/ip-up.d/dyndns_update.sh
[[HTML(<a name="How_to_share_folders_the_easy_way"></a>)]]
Right click on folder -> Share folder
Shared folder -> Share with: Select "SMB" Share properties -> Name: Specify the share name
[[HTML(<a name="How_to_browse_network_computers"></a>)]]
如何 browse network computers
e.g. Assumed that network connections have been configured properly
If computers or network folders could not be found, try access them directly
Read #How to access network folders without mounting
- Places -> Network Servers
[[HTML(<a name="How_to_access_network_folders_without_mounting"></a>)]]
如何 access network folders without mounting
e.g. Assumed that network connections have been configured properly
Network computer's IP: 192.168.0.1
Shared folder's name: linux
- Press 'Alt+F2' (Run Application...) and enter:
smb://192.168.0.1/linux
[[HTML(<a name="How_to_mount.2Funmount_network_folders_manually.2C_and_allow_all_users_to_read"></a>)]]
如何 mount/unmount network folders manually, and allow all users to read
e.g. Assumed that network connections have been configured properly
Network computer's IP: 192.168.0.1
Network computer's Username: myusername
Network computer's Password: mypassword
Shared folder's name: linux
Local mount folder: /media/sharename
- To mount network folder
sudo mkdir /media/sharename sudo mount //192.168.0.1/linux /media/sharename/ -o username=myusername,password=mypassword
- To unmount network folder
sudo umount /media/sharename/
[[HTML(<a name="How_to_mount.2Funmount_network_folders_manually.2C_and_allow_all_users_to_read.2Fwrite"></a>)]]
如何 mount/unmount network folders manually, and allow all users to read/write
e.g. Assumed that network connections have been configured properly
Network computer's IP: 192.168.0.1
Network computer's Username: myusername
Network computer's Password: mypassword
Shared folder's name: linux
Local mount folder: /media/sharename
- To mount network folder
sudo mkdir /media/sharename sudo mount //192.168.0.1/linux /media/sharename/ -o username=myusername,password=mypassword,dmask=777,fmask=777
- To unmount network folder
sudo umount /media/sharename/
[[HTML(<a name="How_to_mount_network_folders_on_boot-up.2C_and_allow_all_users_to_read"></a>)]]
如何 mount network folders on boot-up, and allow all users to read
e.g. Assumed that network connections have been configured properly
Network computer's IP: 192.168.0.1
Network computer's Username: myusername
Network computer's Password: mypassword
Shared folder's name: linux
Local mount folder: /media/sharename
sudo mkdir /media/sharename gksudo gedit /root/.smbcredentials
- 插入下面的行到新文件
username=myusername password=mypassword
- 保存编辑好的文件
sudo chmod 700 /root/.smbcredentials sudo cp /etc/fstab /etc/fstab_backup gksudo gedit /etc/fstab
- Append the following line at the end of file
//192.168.0.1/linux /media/sharename smbfs credentials=/root/.smbcredentials 0 0
- 保存编辑好的文件
- Read #How to remount /etc/fstab without rebooting
[[HTML(<a name="How_to_mount_network_folders_on_boot-up.2C_and_allow_all_users_to_read.2Fwrite"></a>)]]
如何 mount network folders on boot-up, and allow all users to read/write
e.g. Assumed that network connections have been configured properly
Network computer's IP: 192.168.0.1
Network computer's Username: myusername
Network computer's Password: mypassword
Shared folder's name: linux
Local mount folder: /media/sharename
sudo mkdir /media/sharename gksudo gedit /root/.smbcredentials
- 插入下面的行到新文件
username=myusername password=mypassword
- 保存编辑好的文件
sudo chmod 700 /root/.smbcredentials sudo cp /etc/fstab /etc/fstab_backup gksudo gedit /etc/fstab
- Append the following line at the end of file
//192.168.0.1/linux /media/sharename smbfs credentials=/root/.smbcredentials,dmask=777,fmask=777 0 0
- 保存编辑好的文件
- Read #How to remount /etc/fstab without rebooting
[[HTML(<a name="How_to_get_ipw2200_and_wpa_to_work"></a>)]]
如何 get ipw2200 and wpa to work
[[HTML(<a name="How_to_Configure_and_start_PPTP_tunnels_.28VPN.29"></a>)]]
如何配置 and start PPTP tunnels (VPN)
- Use these instructions to automatically install PPTP Client
OR
- Install manually
wget -c http://linux.edu.lv/uploads/content/pptp.tar.gz tar zxvf pptp.tar.gz sudo sh ./pptp/install
- To configure PPTP Client
gksudo gedit /usr/share/applications/pptpconfig.desktop
- Replace content of this file with the following lines
[Desktop Entry] Name=PPTP Client Comment=Configure and start PPTP tunnels (VPN) Categories=Application;Network Encoding=UTF-8 Exec=gksudo pptpconfig Icon=gnome-remote-desktop.png StartupNotify=true Terminal=false Type=Application
- The above lines change the default file in three ways: the application is placed in the Application/Internet category, gksudo will make the application run as superuser and we put a nice icon thatappears in the menu.
- Start the client with 应用程序 -> Internet -> PPTP Client
[[HTML(<a name="How_to_Configure_Ubuntu.2FKubuntu_with_WPA_using_Network-Manager"></a>)]]
如何配置 Ubuntu/Kubuntu with WPA using Network-Manager
Ubuntu Dapper in typical cases can configure WPA to work out of the box with minimal hassle. You'll need to install network-manager.
For Ubuntu:
sudo apt-get install network-manager-gnome
For Kubuntu (will install knetworkmanager):
sudo apt-get install network-manager-kde
Logout/Reboot.
Ubuntu users should now see the NetworkManager Applet in the Gnome notification area. Kubuntu users will probably have to run knetworkmanager before they see NetworkManager in the systray.
If instead, you get a "The NetworkManager applet could not find some required resources. It cannot continue." message, then:
sudo gtk-update-icon-cache -f /usr/share/icons/hicolor
Once Network-Manager is installed, click on the NM icon in the notification area (default is at the top right of Ubuntu/Gnome). Choose your network, then enter your passphrase. Type a password for the keyring, and you're set.
If you don't see your network, click "Create New Wireless Network...", type your essid/networkname, then choose "WPA Personal" for wireless security.
- Note: If you installed Kubuntu then installed ubuntu-desktop & network-manager-gnome, you may not be able to use network-manager in Gnome, if at all. In this case, you may have to use WPA Supplicant and do some manual editing of conf files to get WPA up and running.
- Note: When you first log into Gnome/KDE, the keyring application will ask for a password. Future revisions of Network-Manager should resolve this.
[[HTML(<a name="Remote_Desktop"></a>)]]
Remote Desktop
[[HTML(<a name="How_to_configure_remote_desktop_.28not_secure.29"></a>)]]
如何配置 remote desktop (not secure)
Warning! Remote Desktop will only work if there's a GNOME login session
Leaving computer with an unattended GNOME login session is not secure
Use (系统 -> Lock Screen) and switch off the monitor when computer is left unattended
- 系统 -> Preferences -> Remote Desktop
- Remote Desktop Preferences
Sharing -> Allow other users to view your desktop ('''Checked''') Allow other users to control your desktop ('''Checked''')
Security -> Ask you for confirmation (Un-Checked) Require the user to enter this password: ('''Checked''') Password: Specify the password
[[HTML(<a name="How_to_connect_into_remote_Ubuntu_desktop"></a>)]]
如何 connect into remote Ubuntu desktop
e.g. Assumed that remote Ubuntu machine have configured Remote Desktop
Read #How to configure remote desktop (not secure)
Remote Ubuntu machine: 192.168.0.1
vncviewer -fullscreen 192.168.0.1:0
- To quit vncviewer
Press 'F8' -> Quit viewer
[[HTML(<a name="How_to_connect_into_remote_Ubuntu_desktop_via_Windows_machine"></a>)]]
如何 connect into remote Ubuntu desktop via Windows machine
e.g. Assumed that remote Ubuntu machine have configured Remote Desktop
Read #How to configure remote desktop (not secure)
Remote Ubuntu machine: 192.168.0.1
- If you have a router remember to open the appropiate port. The default one is 5900
This process is called port forwarding port forwarding
- Download DotNetVNC: Here
this is a free DotNet version that require the DotNet framework available from microsoft here
Remember that this is only one VNC client i've found searching in internet, search the one is more suitable for your interest
- Open the VNC client you have chosen, and insert the connection string formatted like this <LINUX BOX IP><:DESKTOP NUMBER>|<::PORT>
In example use: 192.168.1.2:0 or 192.168.1.2::5900 to connect to desktop 0, to connect to desktop 1 use 192.168.1.2:1 or 192.168.1.2::5901 and so on
[[HTML(<a name="How_to_connect_into_remote_Ubuntu_desktop_via_OSX"></a>)]]
如何 connect into remote Ubuntu desktop via OSX
e.g. Assumed that remote Ubuntu machine have configured Remote Desktop
Read #How to configure remote desktop (not secure)
Remote Ubuntu machine: 192.168.0.1
- If you have a router remember to open the appropiate port the default one is 5900
This process is called port forwarding port forwarding
- Download ChickenOfTheVNC: Here
- Open ChickenOfTheVNC, and insert the host (IP adress of remote machine), the display number (0 is default and is port 5900) and the password.
In example use: Host: 192.168.0.1, Display 0, Password: password
[[HTML(<a name="Windows"></a>)]]
Windows
[[HTML(<a name="How_to_mount.2Funmount_Windows_partitions_.28NTFS.29_manually.2C_and_allow_all_users_to_read_only"></a>)]]
如何 mount/unmount Windows partitions (NTFS) manually, and allow all users to read only
e.g. Assumed that /dev/hda1 is the location of Windows partition (NTFS)
Local mount folder: /media/windows
- To mount Windows partition
sudo mkdir /media/windows sudo mount /dev/hda1 /media/windows/ -t ntfs -o nls=utf8,umask=0222
- To unmount Windows partition
sudo umount /media/windows/
[[HTML(<a name="How_to_mount.2Funmount_Windows_partitions_.28FAT.29_manually.2C_and_allow_all_users_to_read.2Fwrite"></a>)]]
如何 mount/unmount Windows partitions (FAT) manually, and allow all users to read/write
e.g. Assumed that /dev/hda1 is the location of Windows partition (FAT)
Local mount folder: /media/windows
- To mount Windows partition
sudo mkdir /media/windows sudo mount /dev/hda1 /media/windows/ -t vfat -o iocharset=utf8,umask=000
- To unmount Windows partition
sudo umount /media/windows/
[[HTML(<a name="How_to_mount_Windows_partitions_.28NTFS.29_on_boot-up.2C_and_allow_all_users_to_read_only"></a>)]]
如何 mount Windows partitions (NTFS) on boot-up, and allow all users to read only
e.g. Assumed that /dev/hda1 is the location of Windows partition (NTFS)
Local mount folder: /media/windows
sudo mkdir /media/windows sudo cp /etc/fstab /etc/fstab_backup gksudo gedit /etc/fstab
- Append the following line at the end of file
/dev/hda1 /media/windows ntfs nls=utf8,umask=0222 0 0
- 保存编辑好的文件
- Read #How to remount /etc/fstab without rebooting
[[HTML(<a name="How_to_mount_Windows_partitions_.28FAT.29_on_boot-up.2C_and_allow_all_users_to_read.2Fwrite"></a>)]]
如何 mount Windows partitions (FAT) on boot-up, and allow all users to read/write
e.g. Assumed that /dev/hda1 is the location of Windows partition (FAT)
Local mount folder: /media/windows
sudo mkdir /media/windows sudo cp /etc/fstab /etc/fstab_backup gksudo gedit /etc/fstab
- Append the following line at the end of file
/dev/hda1 /media/windows vfat iocharset=utf8,umask=000 0 0
- 保存编辑好的文件
- Read #How to remount /etc/fstab without rebooting
[[HTML(<a name="How_to_mount_Windows_partitions_.28NTFS.29_on_boot-up.2C_and_allow_users_read_and_write_access"></a>)]]
如何 mount Windows partitions (NTFS) on boot-up, and allow users read and write access
Warning: Ntfs writing support is still experimental. You should not enable it on production machines and/or volumes you don't have backups of. Proceed at your own risk!
sudo apt-get install libfuse2 fuse-utils
- Download the latest ntfsprogs package (these are from the Dapper repositories, so they are safe to install.)
libntfs8 ntfsprogs libfuse2 fuse-utils
- Install the downloaded packages
sudo dpkg -i libfuse2_*.deb fuse-utils_*.deb ntfsprogs_*.deb libntfs8_*.deb
- Add fuse to the list of modules to load
echo fuse | sudo tee -a /etc/modules
- Create a user group to access the ntfs disks
sudo addgroup ntfs
- The output should look something like this, remember the GID (the number printed after the group name) as it may differ and we will need it later:
Adding group `ntfs' (1002)...
Done.
- Create the local mount folder and edit the fstab file to mount the disks to this folder.
e.g. Assumed that /dev/hda1 is the location of Windows partition (NTFS)
Local mount folder: /media/windows
sudo mkdir /media/windows sudo cp /etc/fstab /etc/fstab.bak gksudo gedit /etc/fstab
- Append the following line at the end of file, using the GID number previously. The umask following this GID allows write access just to owner (root) and group (ntfs), and read access to everyone.
/dev/hda1 /media/windows ntfs-fuse auto,gid=1002,umask=0002 0 0
- 保存编辑好的文件.
- Add users to the ntfs group, where "username" is the name of the user you would like to have write access
sudo adduser username ntfs
- Fix Dapper bug #29865 of the linux-ntfs
package:
sudo rm /sbin/mount.ntfs-fuse && sudo ln /usr/bin/ntfsmount /sbin/mount.ntfs-fuse
- If you reboot now, the disk will be writable to the selected users when they logon. If you want the changes to take effect immediately without rebooting, execute the following command, ignoring the errors about "/" and others not being unmounted. You'll have to logout from all your user sessions for the new group to be acknowledged (usually a logout from your graphical session and login back again will do it).
sudo modprobe fuse && sudo umount -a && sudo mount -a
- Further troubleshooting is listed at this comprehensive howto thread.
[[HTML(<a name="Security"></a>)]]
Security
[[HTML(<a name="What_are_the_basic_things_I_need_to_know_about_securing_my_Ubuntu"></a>)]]
What are the basic things I need to know about securing my Ubuntu
- Ensure hard drive is first in BIOS boot-up sequence
- To prevent trespassers from using Linux Installation CD which allows them to gain root user access
- To prevent trespassers from using Linux Live CD (e.g. UBUNTU/KNOPPIX/MEPIS) which allows them to destroy/browse/share the entire hard drive
- To prevent trespassers from installing another Operating System
- Ensure a password is set for BIOS
- To prevent trespassers from changing the BIOS boot-up sequence
- Ensure computer is located at a secured place
- To prevent trespassers from removing computer's hard drive which allows them to destroy/browse/share the entire hard drive from a different computer
- To prevent trespassers from removing computer's on-board battery which resets the BIOS password
- Ensure passwords used on the system cannot be easily guessed
- To prevent trespassers from cracking password file using brute force attacks (e.g. John the Ripper)
- Create password with minimum length of 8 characters
- Create password with mixture of characters/numbers, and upper/lower case
- Ensure interactive editing control for GRUB menu is disabled
- To prevent trespassers from modifying kernel boot-up arguments which allows them to have root user access
- Ensure history listing is disabled in Console mode
- To prevent trespassers from seeing previously issued commands
- Ensure Ctrl+Alt+Del is disabled in Console mode
- To prevent trespassers from restarting the system without permission in Console mode
- Read [[[How to disable Ctrl+Alt+Del from restarting computer in Console mode]]]
- Ensure interactive option is set for remove, copy and move of files/folders in Console mode
- To prevent accidental removal/overwritten of files/folders
- For day to day usage, login as a normal user
- To prevent accidental deletion/modification of system files/folders
- Disable root user account, use "sudo" instead
- To reduce the amount of time spent with root privileges, and thus the risk of inadvertently executing a command as root
- "sudo" provides a more useful audit trail
(/var/log/auth.log)
- Install a Firewall
- A firewall does not guarantee security but it is in most environments the first line of defense against network based attacks
- Perform vulnerability test
- Nessus is a great tool designed to automate the testing and discovery of known security problems
[[HTML(<a name="How_to_disable_all_interactive_editing_control_for_GRUB_menu"></a>)]]
- Run This:
grub-md5-crypt
Password: Retype password: $1$tumnZ1$xB/shuXs7MlawZXkLiBDV/
- Backup your current configuration file
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 查找下面的段
... # If used in the first section of a menu file, disable all interactive editing # control (menu entry editor and command-line) and entries protected by the # command 'lock' # e.g. password topsecret # password --md5 $1$tumnZ1$xB/shuXs7MlawZXkLiBDV/ # password topsecret ...
- Add the following line below it
password --md5 $1$tumnZ1$xB/shuXs7MlawZXkLiBDV/ (encrypted password above)
- Find the section(s) that look like this (note the 'recovery
mode' and the word 'single'):
... title Ubuntu, kernel 2.6.10-5-386 (recovery mode) root (hd0,1) kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro single initrd /boot/initrd.img-2.6.10-5-386 savedefault boot ...
- Add lock between the title and root lines:
... title Ubuntu, kernel 2.6.10-5-386 (recovery mode) lock root (hd0,1) ...
- 保存编辑好的文件
This will make it so your grub console will require a password to edit the lines, and the recovery modes won't work unless the password is typed. To access the other grub options at the menu, follow the instructions at the bottom of the screen. It will be something like pressing p and typing your password.
[[HTML(<a name="How_to_disable_history_listing_in_Console_mode"></a>)]]
如何 disable history listing in Console mode
- 基本备注
- From Gentoo Wiki:
rm -f .bash_history gedit ~/.bash_profile
- Add the following:
export HISTFILESIZE=4 unset HISTFILE=5 # Change this to a reasonable number of lines to save, I like to save only 100. export HISTSIZE=1 # Ignores duplicate lines next to each other export HISTCONTROL=ignoredups
This will disable Bash history for the user, retaining keystroke history and recall to use while limiting recall history to 100 lines. This will also not record duplicate lines next to each other.
[[HTML(<a name="How_to_disable_Ctrl.2BAlt.2BDel_from_restarting_computer_in_Console_mode"></a>)]]
如何 disable Ctrl+Alt+Del from restarting computer in Console mode
sudo cp /etc/inittab /etc/inittab_backup gksudo gedit /etc/inittab
- 查找如下行
... ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now ...
- 使用下面的行替换
#ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
- 保存编辑好的文件
sudo telinit q
[[HTML(<a name="How_to_enable_prompt_before_removal.2Foverwritten_of_files.2Ffolders_in_Console_mode"></a>)]]
如何 enable prompt before removal/overwritten of files/folders in Console mode
sudo cp /etc/bash.bashrc /etc/bash.bashrc_backup gksudo gedit /etc/bash.bashrc
- 在文件的结束增加下面的行
alias rm='rm -i' alias cp='cp -i' alias mv='mv -i'
- 保存编辑好的文件
[[HTML(<a name="How_to_setup_a_LoJack_system_for_your_laptop"></a>)]]
如何 setup a LoJack system for your laptop
What: Quote from Wikipedia: "LoJack is an aftermarket vehicle tracking system that allows cars to be tracked by police after being stolen. The manufacturer claims a 90% recovery rate. The name "LoJack" is a play on the word "hijack," meaning the theft of a vehicle through force."
Why: If your laptop is ever stolen and connected to the Internet. You will be able to find out from what IP it connects to the Internet from and contact the authorities.
How:
- Get a free dynamic IP account from one of the many providers. Here we will use DynDNS.
- Install ddclient. In the section #How to assign Hostname to local machine with dynamic IP using free DynDNS service we installed the package ipcheck, here we prefer to use ddclient because it can get the IP from an external source on the Internet instead of getting it from a network adapter.
sudo apt-get install ddclient
- Edit the configuration file /etc/ddclient.conf
using you fevorite text editor (emacs, gedit, kedit or even vi)
sudo emacs /etc/ddclient.conf
- Make it look like this:
# Configuration file for ddclient generated by debconf # # /etc/ddclient.conf pid=/var/run/ddclient.pid protocol=dyndns2 use=web server=members.dyndns.org login=YourNameHere password='YourPasswordHere' YourHostNameHere.gotmyip.com
NOTE:
- Make sure that you use the web IP detection method.
- Specify your own user id instead of the place holder YourNameHere.
- Specify your own password instead of the place holder YourPasswordHere, make sure to surround it with single quotes.
- The last line should specify the hostname you registered with the dynamic IP service.
- You can now start the ddclient daemon, or wait until your
next reboot.
sudo /etc/init.d/ddclient start
- The hostname you registered with your dynamic IP service should be updated. You can test it with the ping command:
ping YourHostNameHere.gotmyip.com
Even if your laptop has a firewall that prevents pings the hostname should resolve to the IP of the network gateway that your laptop is connected to.
Now all that is left is for someone to steal your laptop.....
References:
[[HTML(<a name="Boot_menu"></a>)]]
[[HTML(<a name="How_to_gain_root_user_access_without_login"></a>)]]
如何 gain root user access without login
- Easiest method (will not work if GRUB menu password is set)
- Boot-up computer
- If GRUB menu is hidden, press 'Esc' to enter the GRUB menu
- Select
Ubuntu, kernel 2.6.10-5-386 (recovery mode)
- Press 'Enter' to boot
- Other methods
[[HTML(<a name="How_to_modify_kernel_boot-up_arguments.2C_to_gain_root_user_access"></a>)]]
如何 modify kernel boot-up arguments, to gain root user access
- Boot-up computer
- If GRUB menu is hidden, press 'Esc' to enter the GRUB menu
- If GRUB password is set, press 'p' to unlock the GRUB menu
- Select
Ubuntu, kernel 2.6.10-5-386
- Press 'e' to edit the commands before booting
- Select
kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro quiet splash
- Press 'e' to edit the selected command in the boot sequence
- Add "rw init=/bin/bash" to the end of the arguments
grub edit> kernel /boot/vmlinuz-2.6.10-5-386 root=/dev/hda2 ro quiet splash rw init=/bin/bash
- Press 'b' to boot
[[HTML(<a name="How_to_use_Ubuntu_Installation_CD.2C_to_gain_root_user_access"></a>)]]
如何 use Ubuntu Installation CD, to gain root user access
- Boot-up computer into Ubuntu Installation CD
- At "boot:" prompt, add "rescue" to the argument
boot: rescue
- Follow the instructions on screen
[[HTML(<a name="How_to_change_root_user.2Fmain_user_password_if_forgotten"></a>)]]
如何 change root user/main user password if forgotten
- To change root user password
# passwd root
- To change main user password
# passwd system_main_username
[[HTML(<a name="How_to_change_GRUB_menu_password_if_forgotten"></a>)]]
grub
grub> md5crypt Password: ****** (ubuntu) Encrypted: $1$ZWnke0$1fzDBVjUcT1Mpdd4u/T961 (encrypted password) grub> quit
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 查找如下行
... password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/ ...
- 使用下面的行替换
password --md5 $1$ZWnke0$1fzDBVjUcT1Mpdd4u/T961 (encrypted password above)
- 保存编辑好的文件
[[HTML(<a name="How_to_restore_GRUB_menu_after_Windows_installation"></a>)]]
- Use Super Grub Disk
- More info on how to use it here
[[HTML(<a name="How_to_identify_the_name_of_the_boot_drive_.28hd0.2C_hd1.2C_hd2.2C_etc.29"></a>)]]
如何 identify the name of the boot drive (hd0, hd1, hd2, etc)
Press "c" on boot menu. If you don't see a boot menu, press ESC key first when booting to show the boot menu. Type:
root (hd0,0)
Most likely you will get "(hd0,0) ext2fs", which should be your current Linux drive. Now change hd0 to hd1 to see what is there.
root (hd1,0)
If you get "(hd1,0) filesystem type unknown, partition type 0x7", then hd1 is a Windows drive.
Now change hd1 to hd2, keep going until you reach hd7.
[[HTML(<a name="How_to_add_Windows_entry_into_GRUB_menu"></a>)]]
e.g. Assumed that /dev/hda1 is the location of Windows partition
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 在文件的结束增加下面的行
title Microsoft Windows root (hd0,0) savedefault makeactive chainloader +1
- 保存编辑好的文件
[[HTML(<a name="How_to_boot_into_Windows_installed_on_a_seperate_SATA_drive"></a>)]]
如何 boot into Windows installed on a seperate SATA drive
This configuration applies to people who have Linux installed on a IDE drive, and Windows installed on a seperate SATA. The IDE drive boots first, so we need to add an entry to the boot menu on the Linux disk. Here we assume the name of your Windows drive is hd1. If you are not sure, click the link above to find out.
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 在文件的结束增加下面的行.
title Windows XP on SATA drive map (hd0) (hd1) map (hd1) (hd0) chainloader (hd1,0)+1
- 保存编辑好的文件
[[HTML(<a name="How_to_read_Linux_partitions_.28ext2.2C_ext3.29_in_Windows_machine"></a>)]]
如何 read Linux partitions (ext2, ext3) in Windows machine =
- Download Explore2fs: Here
OR
[[HTML(<a name="Tips_.26_Tricks"></a>)]]
Tips & Tricks
[[HTML(<a name="How_to_restart_GNOME_without_rebooting_computer"></a>)]]
如何 restart GNOME without rebooting computer
- Save and close all opened applications
Press 'Ctrl + Alt + Backspace'
or
sudo /etc/init.d/gdm restart
[[HTML(<a name="How_to_turn_on_Num_Lock_on_GNOME_startup"></a>)]]
如何 turn on Num Lock on GNOME startup
sudo apt-get install numlockx sudo cp /etc/X11/gdm/Init/Default /etc/X11/gdm/Init/Default_backup gksudo gedit /etc/X11/gdm/Init/Default
- 查找如下行
... exit 0
- Add the following lines above it
if [ -x /usr/bin/numlockx ]; then /usr/bin/numlockx on fi
- 保存编辑好的文件
- Read #How to restart GNOME without rebooting computer
[[HTML(<a name="How_to_remap_the_Caps_Lock_key_as_another_Control_key"></a>)]]
如何 remap the Caps Lock key as another Control key
gksudo gedit /etc/console-tools/remap
[[HTML(<a name="In_the_Console"></a>)]]
In the Console
- Change
#s/keycode 58 == Caps_Lock/keycode 58 == Control/;
to
s/keycode 58 == Caps_Lock/keycode 58 == Control/;
- Save your work
sudo /etc/init.d/console-screen.sh
- Try using it
[[HTML(<a name="In_X_Windows"></a>)]]
In X Windows
gksudo gedit ~/.Xmodmap
- Add this:
keycode 66 = Control_L clear Lock add Control = Control_L
- Now, apply the changes.
xmodmap ~/.Xmodmap
- To apply them on startup:
gedit ~/.xinitrc
- Make the first line this:
xmodmap ~/.Xmodmap
- 重启 X (Ctrl - Alt - Backspace)
- Log In, a dialog should pop up, add .Xmodmap to the left side with the add button, and Save.
[[HTML(<a name="How_to_run_programs_on_startup_when_login_into_GNOME"></a>)]]
如何 run programs on startup when login into GNOME
- 系统 -> Preferences -> Sessions
- Sessions
Startup Programs Tab -> Add/Edit/Delete
[[HTML(<a name="How_to_speed-up_your_Ubuntu_box"></a>)]]
如何 speed-up your Ubuntu box
- Read the following post: [29]
[[HTML(<a name="How_to_switch_to_Console_mode_in_GNOME"></a>)]]
如何 switch to Console mode in GNOME
- To switch to Console mode
Press 'Ctrl + Alt + F1' (F2 - F6)
- To switch between consles in Console mode
Press 'Alt + F1' (F2 - F6)
- To switch back to GNOME mode
Press 'Alt + F7'
[[HTML(<a name="How_to_disable_Ctrl.2BAlt.2BBackspace_from_restarting_X_in_GNOME"></a>)]]
如何 disable Ctrl+Alt+Backspace from restarting X in GNOME
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf_backup gksudo gedit /etc/X11/xorg.conf
- 在文件的结束增加下面的行
Section "ServerFlags" Option "DontZap" "yes" EndSection
- 保存编辑好的文件
- Read #How to restart GNOME without rebooting computer
[[HTML(<a name="How_to_enable_Ctrl.2BAlt.2BDel_to_open_System_Monitor_in_GNOME"></a>)]]
如何 enable Ctrl+Alt+Del to open System Monitor in GNOME
gconftool-2 -t str --set /apps/metacity/global_keybindings/run_command_9 "<Control><Alt>Delete" gconftool-2 -t str --set /apps/metacity/keybinding_commands/command_9 "gnome-system-monitor"
[[HTML(<a name="How_to_refresh_GNOME_desktop"></a>)]]
如何 refresh GNOME desktop
killall nautilus
[[HTML(<a name="How_to_refresh_GNOME_panel"></a>)]]
如何 refresh GNOME panel
killall gnome-panel
[[HTML(<a name="How_to_enable_autosave_in_Gedit_and_disable_creation_of_some_file.7E_files"></a>)]]
如何 enable autosave in Gedit and disable creation of some_file~ files
- 应用程序 -> 系统工具 -> Configuration Editor
- Configuration Editor
/ -> apps -> gedit-2 -> preferences -> editor -> save -> create_backup_copy ('''Unchecked''') / -> apps -> gedit-2 -> preferences -> editor -> save -> auto_save ('''Checked''')
[[HTML(<a name="How_to_show_all_hidden_files.2Ffolders_in_Nautilus"></a>)]]
- Places -> Home Folder
- To temporary show all hidden files/folders in Nautilus
Press 'Ctrl + H'
- To permanently show all hidden files/folders in Nautilus
Edit 菜单 -> Preferences
Views Tab -> Default View -> Show hidden and backup files ('''Checked''')
[[HTML(<a name="How_to_browse_files.2Ffolders_as_root_user_in_Nautilus"></a>)]]
如何 browse files/folders as root user in Nautilus
- To install File Browser (Root)
gksudo gedit /usr/share/applications/Nautilus-root.desktop
- 插入下面的行到新文件
[Desktop Entry] Name=File Browser (Root) Comment=Browse the filesystem with the file manager Exec=gksudo "nautilus --browser %U" Icon=file-manager Terminal=false Type=Application Categories=Application;System;
- 保存编辑好的文件
- Read #如何刷新 GNOME 面板
- To browse files/folders as root user in Nautilus
- 应用程序 -> 系统工具 -> File Browser (Root)
[[HTML(<a name="How_to_change_default_file_type_.22Open_with.22_program"></a>)]]
如何 change default file type "Open with" program
Right click on file -> '''Properties'''
Open With Tab -> Add Select "Open with" program
Select "Open with" program ('''Checked''')
[[HTML(<a name="How_to_change_preferred_email_client_to_Mozilla_Thunderbird"></a>)]]
如何 change preferred email client to Mozilla Thunderbird
- 系统 -> Preferences -> Preferred Applications
- Preferred Applications
Mail Reader Tab -> Default Mail Reader -> Command: mozilla-thunderbird %s
[[HTML(<a name="How_to_open_files_as_root_user_via_right_click"></a>)]]
如何 open files as root user via right click
gedit $HOME/.gnome2/nautilus-scripts/Open\ as\ root
- 插入下面的行到新文件
for uri in $NAUTILUS_SCRIPT_SELECTED_URIS; do gksudo "gnome-open $uri" & done
- 保存编辑好的文件
chmod +x $HOME/.gnome2/nautilus-scripts/Open\ as\ root
Right click on file -> Scripts -> Open as root
[[HTML(<a name="How_to_disable_beep_sound_in_Terminal_mode"></a>)]]
如何 disable beep sound in Terminal mode
Not for Dapper---- firingstone
- 应用程序 -> Accessories -> Terminal
- Terminal
Edit 菜单 -> Current Profile...
General Tab -> General -> Terminal bell (Un-Checked)
[[HTML(<a name="How_to_handle_mss_protocol_in_Mozilla_Firefox"></a>)]]
如何 handle mss protocol in Mozilla Firefox
- Open your firefox.
- Type as url: about:config
Now just right click somewhere into the main window. A little box with options to choose will appear. Choose "new", then "string". Then copy the following line into the appearing text field:
network.protocol-handler.app.mms
Into the next text field copy this:
/usr/bin/X11/vlc
Now you do the same thing again, but this time you do not choose "string" but "boolean", and the line to copy is:
network.protocol-handler.external.mms
Then set
true
[[HTML(<a name="How_to_handle_rtsp_.28realmedia.29_protocol_in_Mozilla_Firefox"></a>)]]
如何 handle rtsp (realmedia) protocol in Mozilla Firefox
- Open your firefox.
- Type as url: about:config
Now just right click somewhere into the main window. A little box with options to choose will appear. Choose "new", then "string". Then copy the following line into the appearing text field:
network.protocol-handler.app.rtsp
Into the next text field copy this:
/usr/bin/X11/realplay
Now you do the same thing again, but this time you do not choose "string" but "boolean", and the line to copy is:
network.protocol-handler.external.rtsp
Then set
true
[[HTML(<a name="How_to_load_Web_site_faster_in_Mozilla_Firefox"></a>)]]
如何 load Web site faster in Mozilla Firefox
- 应用程序 -> Internet -> Firefox Web Browser
- Mozilla Firefox
Address Bar -> about:config
Filter: -> network.dns.disableIPv6 -> true network.http.pipelining -> true network.http.pipelining.maxrequests -> 8 network.http.proxy.pipelining -> true
- 重启 Mozilla Firefox
[[HTML(<a name="How_to_disable_beep_sound_for_link_find_function_in_Mozilla_Firefox"></a>)]]
如何 disable beep sound for link find function in Mozilla Firefox
- 应用程序 -> Internet -> Firefox Web Browser
- Mozilla Firefox
Address Bar -> about:config
Filter: -> accessibility.typeaheadfind.enablesound -> false
- 重启 Mozilla Firefox
[[HTML(<a name="How_to_apt-get_the_easy_way_.28Synaptic.29"></a>)]]
如何 apt-get the easy way (Synaptic)
- 系统 -> 系统管理 -> Synaptic Package Manager
- To enable the extra Universe and Multiverse repositories
- Settings -> Repositories
- In the Installation Media tab, click Add. There are three separate repositories; Dapper Drake, Security Updates and Updates. Select each repository and check Officially supported, Restricted copyright, Community maintained (Universe) and Non-free (Multiverse). Ensure you click OK between each repository to save your changes
- You should now see those three repositories under Channels. Make sure Officially supported, Restricted copyright, Community maintained (Universe) and Non-free (Multiverse) appears under each repository
- To add backports and PLF (new versions of many applications. Unsupported. May contain illegal packages. Use at own risk.)
- Settings -> Repositories
- Click on Add and then Custom
- Paste the following four lines into the box and click Add Repository, one line at a time:
deb http://archive.ubuntu.com/ubuntu dapper-backports main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu dapper-backports main restricted universe multiverse
deb http://packages.freecontrib.org/ubuntu/plf dapper free non-free deb-src http://packages.freecontrib.org/ubuntu/plf dapper free non-free
deb http://archive.canonical.com/ubuntu dapper-commercial main
- To refresh the list of known packages (equivalent to apt-get update)
Edit 菜单 -> Reload Package Information
- To install all possible upgrades (equivalent to apt-get upgrade)
Edit 菜单 -> Mark All Upgrades... -> Default Upgrade Edit 菜单 -> Apply Marked Changes
- To search for a package (equivalent to apt-cache search package_name)
Edit 菜单 -> Search... Specify the package name
- To install the selected package (equivalent to apt-get install package_name)
Select "package_name" Package 菜单 -> Mark for Installation Edit 菜单 -> Apply Marked Changes
- To remove installed package (equivalent to apt-get remove package_name)
Select "package_name" Package 菜单 -> Mark for Removal Edit 菜单 -> Apply Marked Changes
[[HTML(<a name="What_packages_do_the_extra_repositories_provide"></a>)]]
What packages do the extra repositories provide
- The PLF repository provides
- DVD playback support (libdvdcss2)
- Skype
- Sun Java SDK (Software Development Kit) and JRE (Java Runtime Environment)
- Opera Web browser
- RealPlayer 10
- Win32 binary multimedia codecs
[[HTML(<a name="How_to_install.2Funinstall_.deb_files"></a>)]]
如何安装/uninstall .deb files
- To install .deb file
sudo dpkg -i package_file.deb
- To uninstall .deb file
sudo dpkg -r package_name
[[HTML(<a name="How_to_convert_.rpm_files_to_.deb_files"></a>)]]
如何 convert .rpm files to .deb files
sudo alien package_file.rpm
[[HTML(<a name="How_to_compile_.deb_files_from_source"></a>)]]
如何 compile .deb files from source
- Read [[[How to add extra repositories]]
sudo apt-get install checkinstall
- Now when you compile something from source after you have run ./configure and make you
can make a .deb file and install it with checkinstall. For more info go to CheclInstall home page
[[HTML(<a name="How_to_rename_all_files_in_directory_at_once"></a>)]]
如何 rename all files in directory at once
- To install "mvb" file name renamer
wget -c http://easylinux.info/uploads/mvb_1.6.tgz sudo tar zxvf mvb_1.6.tgz -C /usr/share/ sudo chown -R root:root /usr/share/mvb_1.6/ sudo ln -fs /usr/share/mvb_1.6/mvb /usr/bin/mvb
- To rename all files in directory at once
mvb NEW_NAME
[[HTML(<a name="How_to_manipulate_all_image_files_in_directory_at_once"></a>)]]
如何 manipulate all image files in directory at once
- To install bash batch image processing script
sudo apt-get install imagemagick wget -c http://easylinux.info/uploads/bbips.0.3.2.sh sudo cp bbips.0.3.2.sh /usr/bin/bbips sudo chmod 755 /usr/bin/bbips
- To manipulate all image files in directory at once
bbips
[[HTML(<a name="How_to_set_System-wide_Environment_Variables"></a>)]]
如何 set System-wide Environment Variables
sudo cp -p /etc/profile /etc/profile_backup gksudo gedit /etc/profile
- Append the System-wide Environment Variables at the end of file
- 保存编辑好的文件
[[HTML(<a name="How_to_save_.22man.22_outputs_into_files"></a>)]]
如何 save "man" outputs into files
man command | col -b > file.txt
[[HTML(<a name="How_to_hide_GRUB_menu_on_boot-up"></a>)]]
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 查找如下行
... #hiddenmenu ...
- 使用下面的行替换
hiddenmenu
- 保存编辑好的文件
[[HTML(<a name="How_to_change_the_timeout_seconds_for_GRUB_menu_on_boot-up"></a>)]]
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 查找如下行
... timeout 3 ...
- 使用下面的行替换
timeout X_seconds
- 保存编辑好的文件
[[HTML(<a name="How_to_change_default_Operating_System_boot-up_for_GRUB_menu"></a>)]]
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 查找如下行
... default 0 ...
- 使用下面的行替换
default X_sequence
- 保存编辑好的文件
[[HTML(<a name="How_to_display_Splash_Image_for_GRUB_menu_on_boot-up"></a>)]]
e.g. Assumed that hd0,1 is the location of Ubuntu boot partition
wget -c http://easylinux.info/uploads/ubuntu.xpm.gz chmod 644 ubuntu.xpm.gz sudo mkdir /boot/grub/images sudo cp ubuntu.xpm.gz /boot/grub/images/ sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup gksudo gedit /boot/grub/menu.lst
- 查找下面的段
# menu.lst - See: grub(8), info grub, update-grub(8) # grub-install(8), grub-floppy(8), # grub-md5-crypt, /usr/share/doc/grub # and /usr/share/doc/grub-doc/. ...
- Add the following line below it
splashimage (hd0,1)/boot/grub/images/ubuntu.xpm.gz
- 保存编辑好的文件
[[HTML(<a name="How_to_convert_Wallpaper_to_Splash_Image_for_GRUB_menu"></a>)]]
e.g. Assumed that wallpaper.png is the Wallpaper to be converted to Splash Image
splashimage.xpm.gz is the Splash Image for GRUB menu
convert -resize 640x480 -colors 14 wallpaper.png splashimage.xpm && gzip splashimage.xpm
- Read #How to display Splash Image for GRUB menu on boot-up (use splashimage.xpm.gz instead of ubuntu.xpm.gz)
[[HTML(<a name="How_to_display_only_one_kernel_on_GRUB_menu"></a>)]]
sudo cp /boot/grub/menu.lst /boot/grub/menu.lst_backup-`date +%F` gksudo gedit /boot/grub/menu.lst
- 查找如下行
... # howmany=all ...
- 使用下面的行替换
# howmany=1
Where 1 means to keep the last kernel, 2 to keep the last 2 kernels, etc. Do not delete the # symbol. The menu will be updated once a new kernel will be updated by the system, not before.
- 保存编辑好的文件
[[HTML(<a name="How_to_temporary_skip_boot-up_services"></a>)]]
如何 temporary skip boot-up services
Press 'Ctrl + C'
[[HTML(<a name="How_to_permanently_disable.2Fenable_boot-up_services"></a>)]]
如何 permanently disable/enable boot-up services
[[HTML(<a name="How_to_clean_.2Ftmp.2F_folder_contents_on_shutdown"></a>)]]
如何 clean /tmp/ folder contents on shutdown
sudo cp /etc/init.d/sysklogd /etc/init.d/sysklogd_backup gksudo gedit /etc/init.d/sysklogd
- 查找下面的段
... stop) log_begin_msg "Stopping system log daemon..." start-stop-daemon --stop --quiet --oknodo --exec $binpath --pidfile $pidfile log_end_msg $? ...
- Add the following line below it
rm -fr /tmp/* /tmp/.??*
- 保存编辑好的文件
[[HTML(<a name="How_to_scroll_up_and_down_to_view_previous_outputs_in_Console_mode"></a>)]]
如何 scroll up and down to view previous outputs in Console mode
- To scroll up to view previously outputs
Press 'Shift + Page Up'
- To scroll down to view previously outputs
Press 'Shift + Page Down'
[[HTML(<a name="How_to_find_out_which_version_of_Ubuntu_I_am_using"></a>)]]
如何 find out which version of Ubuntu I am using
cat /etc/issue
[[HTML(<a name="How_to_set_up_automatic_background_change_.28GNOME.29"></a>)]]
如何 set up automatic background change (GNOME)
mkdir ~/.backgrounds cd ~/.backgrounds wget -c http://easylinux.info/uploads/change_background.py chmod +x change_background.py
- To change desktop background every time you reboot your computer
export EDITOR=gedit && crontab -e
- Add the following line at the end of file
@reboot ~/.backgrounds/change_background.py
For more information about periodic processes see
man 5 crontab
- ~/.backgrounds is hidden directory, see #How to show all hidden files/folders in Nautilus
- Copy images you wish to see on your background to
~/.backgrounds directory
[[HTML(<a name="How_to_set_up_automatic_background_change_.28KDE.29"></a>)]]
如何 set up automatic background change (KDE)
- Go to K-菜单 -> System Settings -> Desktop -> Background
- Choose Slide Show
- Press Setup...
- Press Add... to add pictures you wish to see as desktop background
- Set 'Change picture after' to desired picture rotation interval.
- Press 'OK'
[[HTML(<a name="How_to_add_keyboard_layouts_for_other_languages"></a>)]]
如何 add keyboard layouts for other languages
- Go to 系统 -> Preferences -> Keyboard
- Choose Layouts
- Press Add... to add the secondary keyboard layout. It is simpler to have two layouts; the maximum is currently four for Xorg.
- Choose Layout Options
- Expand option Group Shift/Lock behaviour
- Choose the key combination that enables you to switch between keyboard layouts. The default is by pressing both Alt keys at the same time. A common alternative is to use Alt+Shift.
- Press Close.
See #How to add the Keyboard (Layout) Indicator applet to add the Keyboard Indicator applet.
[[HTML(<a name="How_to_add_keyboard_layouts_toggle_for_other_languages_.28Xfce.29"></a>)]]
如何 add keyboard layouts toggle for other languages (Xfce)
- use *.lst files on /etc/X11/xkb/rules to select 2nd_laguage_code
setxkbmap -option grp:switch,grp:alt_shift,grp_led:scroll us,''2nd_laguage_code''
- you can add it to a startup file, which will be set to be executed on startup, with the following lines (remember to 'chmod +x' the file):
#!/bin/tcsh setxkbmap -option grp:switch,grp:alt_shift,grp_led:scroll us,il
[[HTML(<a name="How_to_add_the_Keyboard_.28Layout.29_Indicator_applet"></a>)]]
如何 add the Keyboard (Layout) Indicator applet
- Right-click on empty space on the top panel so that you see the pop-up menu.
- Click Add to Panel...
- Choose Keyboard Indicator (it is under the Utilities section, at the end)
The Keyboard Indicator applet appears on the panel. The default language should be USA for U.S. English. You can either right-click on this applet for more options or see above on how to configure.
[[HTML(<a name="How_to_type_extended_characters"></a>)]]
如何 type extended characters
- Add the keyboard layout US English International (with dead keys)
- Make US English International (with dead keys) the default keyboard layout.
The key marked ['"] is now a dead key. When you press it, nothing happens. However if you press a consonant immediately afterwards, the consonant appears with an accent.
- ' + a = á
- ' + e = é
- and so on for i-í, o-ó, y-ý, c-ć, z-ź, n-ń, l-ĺ, u-ú, r-ŕ
- " + a = ä
- " + e = ë
- and so on for y-ÿ, u-ü, i-ï, o-ö
Similarly, ` and a consonant generates à, è, ù, ì, ò.
Similarly, ~ and a consonant generates ã, ũ, ĩ, õ, ñ.
To type ' and ", press RightAlt+' and RightAlt+" respectively. To type ' and ", you may also press '+<space> and "+<space> respectively.
There are more characters available by keeping RightAlt pressed and typing a character. Therefore,
- RightAlt+q = ä
- RightAlt+w = å
- RightAlt+e = é
- RightAlt+r = ®
- RightAlt+t = þ
- RightAlt+y = ü
- RightAlt+u = ú
- RightAlt+i = í
- RightAlt+o = ó
- RightAlt+p = ö
- RightAlt+[ and ] for « and » respectively.
- RightAlt+a = á
- RightAlt+s = ß
- RightAlt+d = ð
- RightAlt+l = ø
- RightAlt+; = ¶
- RightAlt+: = °
- RightAlt+z = æ
- RightAlt+c = ©
- RightAlt+n = ñ
- RightAlt+m = µ
- RightAlt+, = ç
- RightAlt+/ = ¿
- RightAlt+1 = ¡
- RightAlt+2 = ²
- RightAlt+3 = ³
- RightAlt+4 = ¤
- RightAlt+5 = €
- RightAlt+6 = ¼
- RightAlt+7 = ½
- RightAlt+8 = ¾
- RightAlt+9 = ‘
- RightAlt+0 = ’
- RightAlt+- = ¥
- RightAlt+= = ×
- RightAlt+! = ¹
- RightAlt+@, then o = ő (and Ő).
- RightAlt+#, then a = ā (and Ā). Similarly for ēĒ, ūŪ, īĪ, ōŌ.
- RightAlt+$ = £
- RightAlt+% =
- RightAlt+^ =
- RightAlt+& =
- RightAlt+*, then a = ą (and Ą). Similarly for ęĘ, įĮ.
- RightAlt+(, then a = ă (and Ă)
- RightAlt+(, then g = ğ (and Ğ)
- RightAlt+), then a = å (and Å)
- RightAlt+_ =
- RightAlt++ = ÷
[[HTML(<a name="How_to_set_the_Compose_key_to_type_special_characters"></a>)]]
如何 set the Compose key to type special characters
- Click System, Preferences, Keyboard.
- Under Layout Options, expand on Compose key position.
- Choose Right-Win key is compose, click Close.
Now you can type extended characters using the RightWin key (next to AltGr), according to this keyboard settings file. Specifically, the lines that start with GDK_Multi_key are those that we can use here. The Compose key is actually GDK_Multi_key.
Some examples,
- RightWin + C + = produces €
- RightWin + = + C produces €
- RightWin + C + O produces ©
- RightWin + O + C produces ©
- RightWin + a + ' produces á
- RightWin + a + " produces ä
- RightWin + a + ` produces à
- RightWin + a + ~ produces ã
- RightWin + a + * produces å
- RightWin + a + ^ produces â
- RightWin + a + > produces â
- RightWin + a + , produces ą
- RightWin + e + - produces ē
- RightWin + S + 1 produces ¹
- RightWin + S + 2 produces ²
- RightWin + S + 3 produces ³
[[HTML(<a name="How_to_install_ubuntu-title_font_used_in_Ubuntu_logo"></a>)]]
如何安装 ubuntu-title font used in Ubuntu logo
sudo apt-get install ttf-ubuntu-title
Now you can use this font in your favorite applications
[[HTML(<a name="Servers"></a>)]]
Servers
[[HTML(<a name="AntiVirus_Server"></a>)]]
AntiVirus Server
[[HTML(<a name="How_to_install_ClamAV_AntiVirus_Server"></a>)]]
如何安装 ClamAV AntiVirus Server
sudo apt-get install clamav
[[HTML(<a name="How_to_manually_update_virus_databases"></a>)]]
如何 manually update virus databases
sudo freshclam
[[HTML(<a name="How_to_manually_scan_files.2Ffolders_for_viruses"></a>)]]
如何 manually scan files/folders for viruses
sudo clamscan -r /location_of_files_or_folders
[[HTML(<a name="How_to_automatically_scan_files.2Ffolders_for_viruses"></a>)]]
如何 automatically scan files/folders for viruses
e.g. Automatically scan files/folders for viruses at midnight everyday
* * * * * means minute hour date month year
export EDITOR=gedit && sudo crontab -e
- Append the following line at the end of file
00 00 * * * sudo clamscan -r /location_of_files_or_folders
- 保存编辑好的文件
[[HTML(<a name="Print_Server_.28cupsd.29"></a>)]]
Print Server (cupsd)
[[HTML(<a name="How_to_install_cupsd"></a>)]]
如何安装 cupsd
Cupsd should be automatically installed during standard instaltion. Checkout if there is a file "/etc/init.d/cupsys". If you want to manually install it, do
sudo apt-get install cupsys*
[[HTML(<a name="How_to_add_a_printer"></a>)]]
如何 add a printer
- Go to 系统 -> 系统管理 -> Printing.
- Choose "Add printer".
- "Add printer wizard" should start and tell you what to do.
[[HTML(<a name="How_to_print_on_remote_Ubuntu_machine_from_another_Ubuntu_machine"></a>)]]
如何 print on remote Ubuntu machine from another Ubuntu machine
- Make sure your local printer is well configured.
- Server ip address: 192.168.0.1
- Client ip address: 192.168.0.23
- Server configuration
sudo cp /etc/cups/cupsd.conf /etc/cups/cupsd.conf.backup gksudo gedit /etc/cups/cupsd.conf
find the block
<Location /> ... Allow localhost ... </Location>
and add the following line into it.
Allow 192.168.0.23
Restart cups.
sudo /etc/init.d/cupsys restart
- Client configuration
sudo cp /etc/cups/client.conf /etc/cups/client.conf.backup gksudo gedit /etc/cups/client.conf
And add the following line into it.
ServerName 192.168.0.1
Restart cups.
sudo /etc/init.d/cupsys restart
Now try "lpq" and you should see something like
vitek@lightfox:~$ lpq HPLJ6P is ready no entries
[[HTML(<a name="How_to_print_on_remote_Ubuntu_machine_from_a_Windows_machine"></a>)]]
如何 print on remote Ubuntu machine from a Windows machine
[[HTML(<a name="Samba_Server"></a>)]]
Samba Server
[[HTML(<a name="How_to_install_Samba_Server_for_files.2Ffolders_sharing_service"></a>)]]
如何安装 Samba Server for files/folders sharing service
sudo apt-get install samba smbfs
[[HTML(<a name="How_to_add.2Fedit.2Fdelete_network_users"></a>)]]
如何 add/edit/delete network users
- To add network user
sudo smbpasswd -a system_username gksudo gedit /etc/samba/smbusers
- Insert the following line into the new file
system_username = "network username"
- 保存编辑好的文件
- To edit network user
sudo smbpasswd -a system_username
- To delete network user
sudo smbpasswd -x system_username
[[HTML(<a name="How_to_share_home_folders_with_read_only_permission_.28Authentication.3DYes.29"></a>)]]
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = user username map = /etc/samba/smbusers
- 保存编辑好的文件
- Read #How to add/edit/delete network users
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_home_folders_with_read.2Fwrite_permissions_.28Authentication.3DYes.29"></a>)]]
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = user username map = /etc/samba/smbusers
- 查找下面的段
... # By default, the home directories are exported read-only. Change next # parameter to 'yes' if you want to be able to write to them. writable = no ...
- 使用下面的行替换
# By default, the home directories are exported read-only. Change next # parameter to 'yes' if you want to be able to write to them. writable = yes
- 保存编辑好的文件
- Read #How to add/edit/delete network users
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_group_folders_with_read_only_permission_.28Authentication.3DYes.29"></a>)]]
sudo mkdir /home/group sudo chmod 777 /home/group/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = user username map = /etc/samba/smbusers
- 在文件的结束增加下面的行
[Group] comment = Group Folder path = /home/group public = yes writable = no valid users = system_username1 system_username2 create mask = 0700 directory mask = 0700 force user = nobody force group = nogroup
- 保存编辑好的文件
- Read #How to add/edit/delete network users
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_group_folders_with_read.2Fwrite_permissions_.28Authentication.3DYes.29"></a>)]]
sudo mkdir /home/group sudo chmod 777 /home/group/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = user username map = /etc/samba/smbusers
- 在文件的结束增加下面的行
[Group] comment = Group Folder path = /home/group public = yes writable = yes valid users = system_username1 system_username2 create mask = 0700 directory mask = 0700 force user = nobody force group = nogroup
- 保存编辑好的文件
- Read #How to add/edit/delete network users
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_public_folders_with_read_only_permission_.28Authentication.3DYes.29"></a>)]]
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = user username map = /etc/samba/smbusers
- 在文件的结束增加下面的行
[public] comment = Public Folder path = /home/public public = yes writable = no create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
- 保存编辑好的文件
- Read #How to add/edit/delete network users
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_public_folders_with_read.2Fwrite_permissions_.28Authentication.3DYes.29"></a>)]]
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = user username map = /etc/samba/smbusers
- 在文件的结束增加下面的行
[public] comment = Public Folder path = /home/public public = yes writable = yes create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
- 保存编辑好的文件
- Read #How to add/edit/delete network users
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_public_folders_with_read_only_permission_.28Authentication.3DNo.29"></a>)]]
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = share
- 在文件的结束增加下面的行
[public] comment = Public Folder path = /home/public public = yes writable = no create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
- 保存编辑好的文件
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_share_public_folders_with_read.2Fwrite_permissions_.28Authentication.3DNo.29"></a>)]]
sudo mkdir /home/public sudo chmod 777 /home/public/ sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup gksudo gedit /etc/samba/smb.conf
- 查找如下行
... ; security = user ...
- 使用下面的行替换
security = share
- 在文件的结束增加下面的行
[public] comment = Public Folder path = /home/public public = yes writable = yes create mask = 0777 directory mask = 0777 force user = nobody force group = nogroup
- 保存编辑好的文件
sudo testparm sudo /etc/init.d/samba restart
[[HTML(<a name="How_to_print_on_remote_Ubuntu_machine_via_samba"></a>)]]
如何 print on remote Ubuntu machine via samba
- Make sure your Ubuntu printers are configured properly.
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf.backup gedit /etc/samba/smb.conf
Find the following lines
... # printing = cups # printcap name = cups ...
and uncomment them.
printing = cups printcap name = cups
Restart cups server
sudo /etc/init.d/cupsys restart
Now printers working on your Ubuntu machine should be acessible via samba.
[[HTML(<a name="SSH_Server"></a>)]]
SSH Server
[[HTML(<a name="How_to_install_SSH_Server_for_remote_administration_service"></a>)]]
如何安装 SSH Server for remote administration service
sudo apt-get install ssh
[[HTML(<a name="How_to_SSH_into_remote_Ubuntu_machine"></a>)]]
如何 SSH into remote Ubuntu machine
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
Remote Ubuntu machine: 192.168.0.1
ssh [email protected]
[[HTML(<a name="How_to_copy_files.2Ffolders_from_remote_Ubuntu_machine_into_local_machine_.28scp.29"></a>)]]
如何 copy files/folders from remote Ubuntu machine into local machine (scp)
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
Remote Ubuntu machine: 192.168.0.1
Remote files/folders location: /home/username/remotefile.txt
Local machine save location: . (current directory)
scp -r [email protected]:/home/username/remotefile.txt .
[[HTML(<a name="How_to_copy_files.2Ffolders_from_local_machine_into_remote_Ubuntu_machine_.28scp.29"></a>)]]
如何 copy files/folders from local machine into remote Ubuntu machine (scp)
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
Local files/folders location: localfile.txt
Remote Ubuntu machine: 192.168.0.1
Remote Ubuntu machine save location: /home/username/
scp -r localfile.txt [email protected]:/home/username/
[[HTML(<a name="How_to_copy_files.2Ffolders_from_remote_Ubuntu_machine_into_local_machine_.28rsync.29"></a>)]]
如何 copy files/folders from remote Ubuntu machine into local machine (rsync)
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
Remote Ubuntu machine: 192.168.0.1
Remote files/folders location: /home/username/remotefile.txt
Local machine save location: . (current directory)
rsync -v -u -a --delete --rsh=ssh --stats [email protected]:/home/username/remotefile.txt .
[[HTML(<a name="How_to_copy_files.2Ffolders_from_local_machine_into_remote_Ubuntu_machine_.28rsync.29"></a>)]]
如何 copy files/folders from local machine into remote Ubuntu machine (rsync)
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
Local files/folders location: localfile.txt
Remote Ubuntu machine: 192.168.0.1
Remote Ubuntu machine save location: /home/username/
rsync -v -u -a --delete --rsh=ssh --stats localfile.txt [email protected]:/home/username/
[[HTML(<a name="How_to_mount_remote_folders_into_local_Ubuntu_machine_.28sshfs.29"></a>)]]
如何 mount remote folders into local Ubuntu machine (sshfs)
e.g. Assumed that remote machine has installed SSH Server service
Read #How to install SSH Server for remote administration service
Remote machine: 192.168.0.1
Remote machine folder location: /media/music
- Install sshfs
sudo apt-get install sshfs
- Load kernel driver for sshfs
sudo modprobe fuse
- For permanent use add 'fuse' at the end of /etc/modules
gksudo gedit /etc/modules
- Join the 'fuse' user group
sudo adduser your_user_name fuse
- Logout and login for this to take effect.
- Create local mountpoint in your home directory
mkdir ~/remote_music
- Mount the remote folder into ~/remote_music
sshfs 192.168.0.1:/media/music ~/remote_music
[[HTML(<a name="How_to_SSH_into_remote_Ubuntu_machine_via_Windows_machine"></a>)]]
如何 SSH into remote Ubuntu machine via Windows machine
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
- Download PuTTY: Here
[[HTML(<a name="How_to_copy_files.2Ffolders_from.2Finto_remote_Ubuntu_machine_via_Windows_machine"></a>)]]
如何 copy files/folders from/into remote Ubuntu machine via Windows machine
e.g. Assumed that remote Ubuntu machine have installed SSH Server service
Read #How to install SSH Server for remote administration service
- Download FileZilla: Here
[[HTML(<a name="How_to_limit_the_user_accounts_that_can_connect_through_ssh_remotely"></a>)]]
如何 limit the user accounts that can connect through ssh remotely
e.g. If you enable the SSH server, then any user with a valid account can connect remotely
This can lead to security risks, as there exist remote password cracking tools that
try common username/password pairs.
- Keep a backup of the ssh server configuration file with
sudo cp /etc/ssh/sshd_config /etc/ssh/sshd_config.ORIGINAL
- Edit the configuration file
gksudo gedit /etc/ssh/sshd_config
- Change the parameter PermitRootLogin from yes to no. The superuser must not be able to connect directly from remote.
- Add the parameter AllowUsers and specify the usernames (space separated) that can connect remotely.
- You can also use DenyUsers for fine-grained selection of users.
- If you enable the openssh server and you have no intention for now to enable remote connections, you may add AllowUsers nosuchuserhere to disable anyone connecting.
[[HTML(<a name="DHCP_Server"></a>)]]
DHCP Server
[[HTML(<a name="How_to_install_DHCP_Server_for_automatic_IP_addresses_assignment"></a>)]]
如何安装 DHCP Server for automatic IP addresses assignment
e.g. Assumed that "eth0" is the interface for network card
IP Address Range: 192.168.0.100 to 192.168.0.200
Subnet Mask: 255.255.255.0
DNS Servers: 202.188.0.133, 202.188.1.5
Domains: tm.net.my
Gateway Address: 192.168.0.1
sudo apt-get install dhcp3-server sudo cp /etc/default/dhcp3-server /etc/default/dhcp3-server_backup gksudo gedit /etc/default/dhcp3-server
- 查找如下行
... INTERFACES=""
- 使用下面的行替换
INTERFACES="eth0"
- 保存编辑好的文件
sudo cp /etc/dhcp3/dhcpd.conf /etc/dhcp3/dhcpd.conf_backup gksudo gedit /etc/dhcp3/dhcpd.conf
- 查找下面的段
... # option definitions common to all supported networks... option domain-name "example.org"; option domain-name-servers ns1.example.org, ns2.example.org;
default-lease-time 600; max-lease-time 7200; ...
- 使用下面的行替换
# option definitions common to all supported networks... #option domain-name "example.org"; #option domain-name-servers ns1.example.org, ns2.example.org;
#default-lease-time 600; #max-lease-time 7200;
- 查找下面的段
... # A slightly different configuration for an internal subnet. #subnet 10.5.5.0 netmask 255.255.255.224 { # range 10.5.5.26 10.5.5.30; # option domain-name-servers ns1.internal.example.org; # option domain-name "internal.example.org"; # option routers 10.5.5.1; # option broadcast-address 10.5.5.31; # default-lease-time 600; # max-lease-time 7200; #} ...
- 使用下面的行替换
# A slightly different configuration for an internal subnet. subnet 192.168.0.0 netmask 255.255.255.0 { range 192.168.0.100 192.168.0.200; option domain-name-servers 202.188.0.133, 202.188.1.5; option domain-name "tm.net.my"; option routers 192.168.0.1; option broadcast-address 192.168.0.255; default-lease-time 600; max-lease-time 7200; }
- 保存编辑好的文件
sudo /etc/init.d/dhcp3-server restart
[[HTML(<a name="Database_Server"></a>)]]
Database Server
[[HTML(<a name="How_to_install_MYSQL_Database_Server"></a>)]]
如何安装 MYSQL Database Server
sudo apt-get install mysql-server
- MySQL initially only allows connections from the localhost (127.0.0.1). We'll need to remove that restriction if you wish to make it accessible to everyone on the internet. Open the file /etc/mysql/my.cnf
gksudo gedit /etc/mysql/my.cnf
- Find the line bind-address = 127.0.0.1 and comment it out
... #bind-address = 127.0.0.1 ...
- MySQL comes with no root password as default. This is a huge security risk. You'll need to set one. So that the local computer gets root access as well, you'll need to set a password for that too. The local-machine-name is the name of the computer you're working on. For more information see here
mysqladmin -u root password your-new-password mysqladmin -h root@local-machine-name -u root password your-new-password sudo /etc/init.d/mysql restart
[[HTML(<a name="How_to_install_MYSQL_Administrator"></a>)]]
如何安装 MYSQL Administrator
sudo apt-get install mysql-admin
- Read #如何刷新 GNOME 面板
- 应用程序 -> 系统工具 -> MySQL Administrator
[[HTML(<a name="How_to_install_Oracle_Database_XE"></a>)]]
如何安装 Oracle Database XE
- Read [30]
- Add the following repository to your /etc/apt/sources.list:
deb http://oss.oracle.com/debian unstable main non-free
- Install the software using apt-get
sudo apt-get update sudo apt-get install oracle-xe
- Add your login to the 'dba' group (where your login name is
username)
sudo usermod -G dba -a ''username''
[[HTML(<a name="Apache_HTTP_Server"></a>)]]
Apache HTTP Server
[[HTML(<a name="How_to_install_Apache_HTTP_Server_for_HTTP_.28Web.29_Server_service"></a>)]]
如何安装 Apache HTTP Server for HTTP (Web) Server service
sudo apt-get install apache2
[[HTML(<a name="How_to_install_PHP_for_Apache_HTTP_Server"></a>)]]
如何安装 PHP for Apache HTTP Server
[[HTML(<a name="How_to_install_PHP4"></a>)]]
如何安装 PHP4
sudo apt-get install php4 sudo apt-get install libapache2-mod-php4 sudo /etc/init.d/apache2 restart
- To test if php4 installed correctly
gksudo gedit /var/www/testphp.php
- Insert the following line into the new file
<?php phpinfo(); ?>
- 保存编辑好的文件
- [32]
- Be sure to remove the file afterwards, as it may pose a security risk
[[HTML(<a name="How_to_install_PHP5"></a>)]]
如何安装 PHP5
sudo apt-get install php5 sudo apt-get install libapache2-mod-php5 sudo /etc/init.d/apache2 restart
- To test if php5 installed correctly
gksudo gedit /var/www/testphp.php
- Insert the following line into the new file
<?php phpinfo(); ?>
- 保存编辑好的文件
- [33]
- Be sure to remove the file afterwards, as it may pose a security risk
[[HTML(<a name="How_to_install_MYSQL_for_Apache_HTTP_Server"></a>)]]
如何安装 MYSQL for Apache HTTP Server
sudo apt-get install libapache2-mod-auth-mysql
- Select either php4-mysql or php5-mysql depending on which
version of PHP you installed
sudo apt-get install php<version-number>-mysql sudo apt-get install phpmyadmin
- To get PHP to work with MySQL, open the file (where <version> is either 4 or 5 depending on which PHP you installed)
gksudo gedit /etc/php<version>/apache2/php.ini
- You'll need to uncomment the ";extension=mysql.so" line so that it looks like this
... extension=mysql.so ...
- Save the file then exit
sudo /etc/init.d/apache2 restart
[[HTML(<a name="How_to_map_URLs_to_folders_outside_.2Fvar.2Fwww.2F"></a>)]]
如何 map URLs to folders outside /var/www/
gksudo gedit /etc/apache2/conf.d/alias
- 插入下面的行到新文件
Alias /URL-path /location_of_folder/
<Directory /location_of_folder/> Options Indexes FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory>
- 保存编辑好的文件
sudo /etc/init.d/apache2 restart
[[HTML(<a name="How_to_change_the_default_port_number_for_Apache_HTTP_Server"></a>)]]
如何 change the default port number for Apache HTTP Server
e.g. Assumed that new port number is 78
sudo cp /etc/apache2/ports.conf /etc/apache2/ports.conf_backup gksudo gedit /etc/apache2/ports.conf
- 查找如下行
Listen 80
- 使用下面的行替换
Listen 78
- 保存编辑好的文件
sudo /etc/init.d/apache2 restart
[[HTML(<a name="How_to_parse_RSS_into_PHP_for_Apache_HTTP_Server"></a>)]]
如何 parse RSS into PHP for Apache HTTP Server
e.g. Assumed that RSS is DistroWatch.com - News
wget -c http://easylinux.info/uploads/magpierss-0.71.1.tar.gz sudo mkdir /var/www/feeds sudo tar zxvf magpierss-0.71.1.tar.gz -C /var/www/feeds/ sudo mv /var/www/feeds/magpierss-0.71.1/* /var/www/feeds/ sudo rm -fr /var/www/feeds/magpierss-0.71.1/ sudo chown -R www-data:root /var/www/feeds/ gksudo gedit /var/www/feeds/index.php
- 插入下面的行到新文件
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <head> <title>DistroWatch.com - News</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/> <style type="text/css"> /*<![CDATA[*/ /* DEFAULT TAG STYLES */ body { background: #ffffff; margin-left: 20px; font-family: bitstream vera sans,sans-serif; font-size: 9pt; } h1 { font-family: luxi sans,sans-serif; font-size: 15pt; } /*]]>*/ </style> </head> <body> <?php require_once 'rss_fetch.inc'; error_reporting(E_ERROR); $url = 'http://distrowatch.com/news/dw.xml'; $rss = fetch_rss($url); if ($rss) { echo "<h1>"; echo "<a href=$url>", $rss->channel[title], "</a><br/>"; echo "</h1>"; foreach ($rss->items as $item ) { $url = $item[link]; $title = $item[title]; $description = $item[description]; echo "<li>"; echo "<b>Topic:</b> <a href=$url><b>$title</b></a><br/><br/>"; echo "$description<br/><br/>"; echo "</li>"; } } else { echo "<a href=$url>", $url, "</a> - Server Down!<br/>"; } ?> </body> </html>
- 保存编辑好的文件
- [37]
[[HTML(<a name="FTP_Server"></a>)]]
FTP Server
[[HTML(<a name="How_to_install_FTP_Server_for_File_Transfer_service"></a>)]]
如何安装 FTP Server for File Transfer service
sudo apt-get install proftpd
[[HTML(<a name="How_to_configure_FTP_user_to_be_.22jailed.22_.28chrooted.29_into_their_home_directory"></a>)]]
如何配置 FTP user to be "jailed" (chrooted) into their home directory
sudo cp /etc/proftpd.conf /etc/proftpd.conf_backup gksudo gedit /etc/proftpd.conf
- 查找下面的段
... DenyFilter \*.*/ ...
- Add the following line below it
DefaultRoot ~
- 保存编辑好的文件
sudo /etc/init.d/proftpd restart
[[HTML(<a name="How_to_configure_FTP_Server_to_allow_anonymous_FTP_user_to_read_only"></a>)]]
如何配置 FTP Server to allow anonymous FTP user to read only
sudo cp /etc/proftpd.conf /etc/proftpd.conf_backup gksudo gedit /etc/proftpd.conf
- 在文件的结束增加下面的行
<Anonymous ~ftp> User ftp Group nogroup UserAlias anonymous ftp DirFakeUser on ftp DirFakeGroup on ftp RequireValidShell off MaxClients 10 DisplayLogin welcome.msg DisplayFirstChdir .message <Directory *> <Limit WRITE> DenyAll </Limit> </Directory> </Anonymous>
- 保存编辑好的文件
sudo /etc/init.d/proftpd restart
[[HTML(<a name="How_to_configure_FTP_Server_to_allow_anonymous_FTP_user_to_read.2Fwrite"></a>)]]
如何配置 FTP Server to allow anonymous FTP user to read/write
sudo cp /etc/proftpd.conf /etc/proftpd.conf_backup gksudo gedit /etc/proftpd.conf
- 在文件的结束增加下面的行
<Anonymous ~ftp> User ftp Group nogroup UserAlias anonymous ftp DirFakeUser on ftp DirFakeGroup on ftp RequireValidShell off MaxClients 10 DisplayLogin welcome.msg DisplayFirstChdir .message </Anonymous>
- 保存编辑好的文件
sudo /etc/init.d/proftpd restart
[[HTML(<a name="How_to_map_anonymous_FTP_user_to_folders_outside_.2Fhome.2Fftp.2F"></a>)]]
如何 map anonymous FTP user to folders outside /home/ftp/
sudo cp /etc/proftpd.conf /etc/proftpd.conf_backup gksudo gedit /etc/proftpd.conf
- 在文件的结束增加下面的行
<Anonymous /location_of_folder/> User ftp Group nogroup UserAlias anonymous ftp DirFakeUser on ftp DirFakeGroup on ftp RequireValidShell off MaxClients 10 DisplayLogin welcome.msg DisplayFirstChdir .message <Directory *> <Limit WRITE> DenyAll </Limit> </Directory> </Anonymous>
- 保存编辑好的文件
sudo /etc/init.d/proftpd restart
[[HTML(<a name="How_to_change_the_default_port_number_for_FTP_Server"></a>)]]
如何 change the default port number for FTP Server
e.g. Assumed that new port number is 77
sudo cp /etc/proftpd.conf /etc/proftpd.conf_backup gksudo gedit /etc/proftpd.conf
- 查找如下行
Port 21
- 使用下面的行替换
Port 77
- 保存编辑好的文件
sudo /etc/init.d/proftpd restart
[[HTML(<a name="How_to_ftp_into_remote_Ubuntu_machine_via_Windows_machine"></a>)]]
如何 ftp into remote Ubuntu machine via Windows machine
e.g. Assumed that remote Ubuntu machine have installed FTP Server service
Read #How to install FTP Server for File Transfer service
- Download FileZilla: Here
[[HTML(<a name="Streaming_Media_Server"></a>)]]
Streaming Media Server
[[HTML(<a name="How_to_install_GNUMP3d_for_Streaming_Media_Server_service"></a>)]]
如何安装 GNUMP3d for Streaming Media Server service
e.g. /var/music/ is the directory containing multimedia files
sudo apt-get install gnump3d
[[HTML(<a name="How_to_change_the_default_directory_containing_multimedia_files_for_GNUMP3d"></a>)]]
如何 change the default directory containing multimedia files for GNUMP3d
- Read [/DapperGuide#How_to_install_GNUMP3d_for_Streaming_Media_Server_service #How to install GNUMP3d for Streaming Media Server service]
e.g. Assumed that new directory containing multimedia files is /home/music/
sudo cp /etc/gnump3d/gnump3d.conf /etc/gnump3d/gnump3d.conf_backup gksudo gedit /etc/gnump3d/gnump3d.conf
- 查找如下行
root = /var/music
- 使用下面的行替换
root = /home/music
- 查找如下行
user = gnump3d
- 使用下面的行替换
user = root
- 保存编辑好的文件
sudo /etc/init.d/gnump3d restart
[[HTML(<a name="How_to_change_the_default_port_number_for_GNUMP3d"></a>)]]
如何 change the default port number for GNUMP3d
e.g. Assumed that new port number is 7878
sudo cp /etc/gnump3d/gnump3d.conf /etc/gnump3d/gnump3d.conf_backup gksudo gedit /etc/gnump3d/gnump3d.conf
- 查找如下行
port = 8888
- 使用下面的行替换
port = 7878
- 保存编辑好的文件
sudo /etc/init.d/gnump3d restart
[[HTML(<a name="Image_Gallery_Server"></a>)]]
Image Gallery Server
- For a comparison between Gallery1 and Gallery2 see here
[[HTML(<a name="Gallery1"></a>)]]
Gallery1
[[HTML(<a name="How_to_install_Gallery1_for_Image_Gallery_Server_service"></a>)]]
如何安装 Gallery1 for Image Gallery Server service
sudo apt-get install gallery (when prompted to restart Apache, choose No or Cancel) sudo apt-get install imagemagick sudo apt-get install jhead sudo apt-get install libjpeg-progs sudo /etc/init.d/apache2 restart sudo sh /usr/share/gallery/configure.sh
- Gallery Configuration
Gallery Configuration Wizard: Step 1 Next Step ->
Gallery Configuration Wizard: Step 2 General settings Tab -> Admin password: Specify the password Locations and URLs Tab -> Album directory: /var/www/albums/ Temporary directory: /tmp/ Gallery URL: http://localhost/gallery Albums URL: http://localhost/albums Next Step -->
Gallery Configuration Wizard: Step 3 Next Step -->
Gallery Configuration Wizard: Step 4 Save Config ->
[[HTML(<a name="How_to_configure_Gallery1_to_be_accessible_via_Internet_.28Hostname_or_fix_IP.29_or_LAN_.28fix_IP.29"></a>)]]
如何配置 Gallery1 to be accessible via Internet (Hostname or fix IP) or LAN (fix IP)
e.g. Assumed that network and internet connections have been configured properly
Internet (Hostname or fix IP) or LAN (fix IP): [43]
sudo cp /etc/gallery/config.php /etc/gallery/config.php_backup gksudo gedit /etc/gallery/config.php
- 查找下面的段
... $gallery->app->photoAlbumURL = "http://localhost/gallery"; $gallery->app->albumDirURL = "http://localhost/albums"; ...
- 使用下面的行替换
$gallery->app->photoAlbumURL = "http://www.url.com/gallery"; $gallery->app->albumDirURL = "http://www.url.com/albums";
- 保存编辑好的文件
- [44]
[[HTML(<a name="How_to_configure_Gallery1_to_be_accessible_via_LAN_.28dynamic_IP.29"></a>)]]
如何配置 Gallery1 to be accessible via LAN (dynamic IP)
e.g. Assumed that network connections have been configured properly
LAN (dynamic IP): 192.168.0.1
sudo cp /etc/gallery/config.php /etc/gallery/config.php_backup gksudo gedit /etc/gallery/config.php
- 查找下面的段
... $gallery->app->photoAlbumURL = "http://localhost/gallery"; $gallery->app->albumDirURL = "http://localhost/albums"; ...
- 使用下面的行替换
$gallery->app->photoAlbumURL = "/gallery"; $gallery->app->albumDirURL = "/albums";
- 保存编辑好的文件
- [45]
[[HTML(<a name="How_to_backup.2Frestore_Gallery1_data"></a>)]]
如何 backup/restore Gallery1 data
- To backup Gallery data
sudo tar zcvf gallery.tgz /var/www/albums/ /etc/gallery/
- To restore Gallery data
sudo tar zxvf gallery.tgz -C /
[[HTML(<a name="Gallery2"></a>)]]
Gallery2
[[HTML(<a name="How_to_install_Gallery2"></a>)]]
如何安装 Gallery2
[[HTML(<a name="How_to_configure_Gallery2"></a>)]]
如何配置 Gallery2
[[HTML(<a name="Troubleshooting"></a>)]]
Troubleshooting
[[HTML(<a name="Configuring_network_interfaces..._.28taking_too_long_to_load.29"></a>)]]
Configuring network interfaces... (taking too long to load)
[[HTML(<a name="Synchronizing_clock_to_ntp.ubuntulinux.org..._.28taking_too_long_to_load.29"></a>)]]
Synchronizing clock to ntp.ubuntulinux.org... (taking too long to load)
service_name = ntpdate
[[HTML(<a name="How_to_disable_system_time.2Fdate_from_being_reset_to_UTC_.28GMT.29"></a>)]]
如何 disable system time/date from being reset to UTC (GMT)
sudo cp /etc/default/rcS /etc/default/rcS_backup gksudo gedit /etc/default/rcS
- 查找如下行
... UTC=yes ...
- 使用下面的行替换
UTC=no
- 保存编辑好的文件
- 系统 -> 系统管理 -> 时间和日期
Set the correct time/date
sudo /etc/init.d/hwclock.sh restart
[[HTML(<a name="How_to_configure_sound_to_work_properly_in_GNOME"></a>)]]
如何配置 sound to work properly in GNOME
sudo killall esd sudo cp /etc/esound/esd.conf /etc/esound/esd.conf_backup gksudo gedit /etc/esound/esd.conf
- 查找下面的段
... auto_spawn=0 spawn_options=-terminate -nobeeps -as 5 ...
- 使用下面的行替换
auto_spawn=1 spawn_options=-terminate -nobeeps -as 2 -d default
- 保存编辑好的文件
sudo apt-get install libesd-alsa0 gksudo gedit /etc/asound.conf
- 插入下面的行到新文件
pcm.card0 { type hw card 0 } pcm.!default { type plug slave.pcm "dmixer" } pcm.dmixer { type dmix ipc_key 1025 slave { pcm "hw:0,0" period_time 0 period_size 2048 buffer_size 32768 rate 48000 } bindings { 0 0 1 1 } }
- 保存编辑好的文件
sudo ln -fs /usr/lib/libesd.so.0 /usr/lib/libesd.so.1
系统 -> Preferences -> Sound Sound preferences
General Tab -> Sounds for events '''(Un-Checked)'''
- Save and close all opened applications, Reboot computer
[[HTML(<a name="How_to_forcefully_empty_Trash_in_GNOME"></a>)]]
如何 forcefully empty Trash in GNOME
sudo rm -fr $HOME/.Trash/
[[HTML(<a name="How_to_remove_duplicate_menu.2Fmenu_items_in_GNOME"></a>)]]
rm -f $HOME/.config/menus/applications.menu
[[HTML(<a name="How_to_refresh_Places_menu_in_GNOME_.28if_mounts_to_.2Fmedia.2F_in_.2Fetc.2Ffstab_does_not_show_up.29"></a>)]]
sudo /etc/init.d/dbus-1 restart
[[HTML(<a name="How_to_consume_static_.28not_dhcp.29_wireless_LAN_.28WLAN.29_connection_.28KDE.29"></a>)]]
如何 consume static (not dhcp) wireless LAN (WLAN) connection (KDE)
- I assume you have successfully consumed WLAN connection in Windows
- To enable the network device please follow the following steps
- Go to K-菜单 -> System Settings -> Network Settings
- Enable Administrator mode
- Select Network Interfaces tab and the wireless interface (usually ath0) to configure
- Click Configure Interface...
- Choose Manual or Automatic. Choose Manual
- Fill the preferred IP address to identify your computer and the netmask. Choose to activate when computer starts
- Click Advanced Settings to for more properties
- Select Routes tab and fill the gateway IP address
- Make sure you choose the correct device in the right dropdown (e.g. ath0)
- Click apply to commit all changes
- To choose wireless connection please follow the following steps
- Go to K-菜单 -> Internet -> Wireless Assistant
- Right click on preferred connection ssid
- Choose and complete fields for Manual connection
- Click Ok
- Create connection configuration
gksudo gedit /etc/wpa_supplicant.conf
- 插入下面的行到新文件
network={ ssid="YOUR_PREFERRED_CONNECTION_SSID" scan_ssid=1 proto=WPA key_mgmt=WPA-PSK psk="STRING_TO_GENERATE_PASSWORD" #psk=123456789 #you have option to use connection key instead of connection password }
- 保存编辑好的文件
- Create script to easily activate connection
gksudo gedit /etc/init.d/wifi_wpa.sh
- 插入下面的行到新文件
#! /bin/sh # wifi: wpa_supplicant init echo " * [Wifi]: Enabling WPA supplicant..." if [ -x /sbin/wpa_supplicant ]; then /sbin/wpa_supplicant -B -i ath0 -c /etc/wpa_supplicant.conf -D madwifi -w fi exit 0
- 保存编辑好的文件
- Make sure both file readable and executable
sudo chmod +r /etc/wpa_supplicant.conf sudo chmod +x /etc/init.d/wifi_wpa.sh
- make wireless connection automaticaly starts when computer starts
sudo ln -s /etc/init.d/wifi_wpa.sh /etc/rcS.d/S40netwifiwpa
- Close all opened applications, Reboot computer
[[HTML(<a name="How_to_get_1400x1050_resolution_working"></a>)]]
如何 get 1400x1050 resolution working
- See [[46]]
[[HTML(<a name="Upgrading_Ubuntu"></a>)]]
Upgrading Ubuntu
[[HTML(<a name="How_to_upgrade_from_Hoary_Hedgehog_-.3E_Breezy_Badger_-.3E_Dapper_Drake"></a>)]]
如何 upgrade from Hoary Hedgehog -> Breezy Badger -> Dapper Drake
- First, make sure you're fully upgraded:
sudo apt-get update sudo apt-get upgrade sudo apt-get dist-upgrade
- If you don't have a CD available make SURE you comment/remove the line pertaining to your CD media
gksudo g /etc/apt/sources.list
/etc/apt/sources.list
for an upgrade to breezy your sources.list should look something similar to this:
## Uncomment the following two lines to fetch updated software from the network deb http://us.archive.ubuntu.com/ubuntu breezy main restricted deb-src http://us.archive.ubuntu.com/ubuntu breezy main restricted deb http://us.archive.ubuntu.com/ubuntu breezy-updates main restricted deb-src http://us.archive.ubuntu.com/ubuntu breezy-updates main restricted deb http://us.archive.ubuntu.com/ubuntu breezy universe deb-src http://us.archive.ubuntu.com/ubuntu breezy universe deb http://security.ubuntu.com/ubuntu breezy-security main restricted deb-src http://security.ubuntu.com/ubuntu breezy-security main restricted deb http://security.ubuntu.com/ubuntu breezy-security universe deb-src http://security.ubuntu.com/ubuntu breezy-security universe</div>
- To upgrade from breezy to dapper, just replace (ctrl+h) all instances of 'breezy' with 'dapper' within the /etc/apt/sources.list
- 保存这个文件.
sudo apt-get update sudo apt-get upgrade sudo apt-get dist-upgrade
- Save your session, reboot, and enjoy.
NOTE:
- I would NOT suggest upgrading directly from hoary to dapper. Upgrade: hoary->breezy->dapper
[[HTML(<a name="How_to_upgrade_from_Dapper_Drake_to_Edgy_Eft_.28experimental.29"></a>)]]
如何 upgrade from Dapper Drake to Edgy Eft (experimental)
- coming soon...
原文出处:http://ubuntuguide.org/wiki/Dapper
翻译人员:
校对人员:
贡献者:
适用版本:
文章状态:等待翻译