27 Jun 2019
Echo Linux Release Version
Sometime, I need to recall the Linux version I'm using inside the Virtual Box. I know it's Xubuntu, but which version is it? Usually the commands to do things keep the same. However, they do change from version to version in rare occacions. Type the command below in any terminal window, you'll ge the answer straigh away.
3 Jul 2013
19 Sept 2012
LinuxMint, Ubuntu, OpenSUSE, Fedora and More
19 Oct 2009
ubuntu update error with NO_PUBKEY
(replace KEY with you get from the error messages.)
gpg --keyserver subkeys.pgp.net --recv KEY gpg --export --armor KEY | sudo apt-key add -
14 Sept 2009
ubuntu下的网络电视
windows下(注意! windows下)破解ppstream的vip影片办法
可以找到vip的地址,用播放url的方法看
不花钱看会员影片,谁让咱比较"差钱"呢!
详细见新帖:
http://52xenos.blogspot.com/2009/11/ppstream-vip-hack.html
=======================================================
linux版本正在研究中...
linux安装pps请继续往下看:
ppstream终于也开窍了,出了linux版本
不过目前尚处于实验阶段,只有命令行版本
至于调用totem还是利用mplayer
看个人喜好了。我比较懒,懒得配置,就totem好了
If you want to install ppstream within Ubuntu,
please follow the instruction below:
方法如下:(最简单的方法,14/09/09更新)
1,编辑源:
1, edit the source.list
sudo gedit /etc/apt/sources.list
打开后加入下面2行,保存退出
add the following rows at the end, save and exit
deb http://ppa.launchpad.net/portis25/ppa/ubuntu karmic main deb-src http://ppa.launchpad.net/portis25/ppa/ubuntu karmic main
2,直接安装
2, install pps directly
sudo apt-get install totem-pps
依赖关系会自动将libpps, libppswrapper, gst-plugins-pps等包装上。
All dependances would be handled automatically, including libpps, libppswrapper and gst-plugins-pps.
使用方法:
Usage:
totem---编辑---插件--ppstream
totem--edit--plugins--ppstream
8.04需在编辑->插件->PPStream 首选项里启用兼容旧的 totem.
For Ubuntu8.04, you need tick the compatible with old totem plugin option.
注意:如果加入源更新时出现没有公钥的错误,解决方法如下:
PS: if you meet the error of "No public key" when update the source list, you can fix it as following:
gpg --keyserver wwwkeys.pgp.net --recv-keys PUBLIC KEY HEREgpg --export -a PUBLIC KEY HERE > /tmp/key
sudo apt-key add /tmp/keypplive解决方案:
去这一页下载deb包直接安装吧(谁让我比较懒呢)
如果你在ubuntu中文论坛已经登录,直接猛击这里下载附件即可.
============================================
13 Sept 2009
ubuntu更新错误
正在读取软件包列表... 有错误! E: Encountered a section with no Package: header E: Problem with MergeList /var/lib/apt/lists/gb.archive.ubuntu.com_ubuntu_dists_karmic_restricted_binary-i386_Packages E: 无法解析或打开软件包的列表或是状态文件。
正准备上报bug,发现有人早已在904的时候碰到这个问题了,解决方法如下:
sudo rm /var/lib/apt/lists/* -vf
然后再次更新就可以了:
sudo apt-get update sudo apt-get upgrade
4 May 2009
Ubuntu Tips - vmware中释放鼠标问题
If you also meet the problem of releasing mouse from vmware, please read this post, which I find from the internet.
从一老外的blog看到解决办法,目前ok.
方法如下:
##CONTINUE##
sudo apt-get install xserver-xorg-input-vmmouse
注销后再登陆ok.
Log-out and log-in, It should be ok now.
30 Apr 2009
Python Tips - python IDLE自动补全
到了ubuntu下就没有了作用,但是ipython这个改进的交互式python解释器则可以.
方法如下:
If you want to use auto complete function in ubuntu, you need to install ipython like:
sudo apt-get install ipython
--------------------------------------
ubuntu904+VMware+python2.6,尚未测试成功下面这个方法.
另外一个方法就是麻烦点,每次开python之后输入:
Another method is a little bit complicated:
(This methods hasn't been tested)
>>>import readline, rlcompleter
>>>readline.parse_and_bind("tab: complete")
保存为~/.pythonstartup.py之后,加入~/.bashrc
Then add it to your ~/.bashrc file:
export PYTHONSTARTUP=~/.pythonstartup.py
29 Apr 2009
Ubuntu Tips:安装vm tools
对vm tools不再支持,安装之后下次重启,依然要求你继续安装,
发现是安装有问题,google得到的解答,需要安装open-vm-tools
我是用的是源码安装方法:
There're some problem to install vm tools for ubuntu9.04, which it always require to be installed although you have done so. The answer from google is to install open-vm-tools. You can download it from sourceforge.
##CONTINUE##
tar -xzf open-vm-tools-*.tar.gz
sudo ./configure --without-x
sudo make
sudo make install
如果编译碰到没有gettext,glib版本过低问题,运行下面的命令应该会搞定:
If you meet any problem whilst compiling open-vm-tools, run the following command in terminal:
sudo apt-get install libproc-dev libdumbnet-dev libicu-dev libglib2.0-dev libglib1.2-dev
如果编译安装完全正确,打包文件拷贝到vm tools安装目录:
If you have done the compiling and installing procedures, tar the following files then put them into vm tools directory as:
cd modules/linux
for i in *; do mv ${i} ${i}-only; tar -cf ${i}.tar ${i}-only; done
cd ../../../
mv -f open-vm-tools-*/modules/linux/*.tar vmware-tools-distrib/lib/modules/source/
最后重新安装vm tools:
Finally, execute the install command as:
sudo ./vmware-install.pl
23 Apr 2009
Ubuntu Tips - 右键添加“打开终端“
非常方便,google了下,方法如下:
Under the kde environment in RedHat, it's easy to open terminal everywhere by rightclick. Here is the method to add this feature to your ubuntu:
##CONTINUE##
sudo apt-get install nautilus-open-terminal
Ubuntu9.04发布
The new Ubuntu9.04 has been released today.
看官网介绍,904的新特性不少,具体请看:
Follow this link to see the new features of ubuntu 9.04:
http://www.ubuntu.com/
下载地址:
Download page:
http://releases.ubuntu.com/releases/9.04/
贴几个图:
Some screenshots of ubuntu 9.04:
##CONTINUE##
登陆界面:
Log in:

桌面:
Desktop:
28 Mar 2009
搞定"谁不拉屎"(CBLAS)+g77安装-立此存照
===
题目有点令人反胃,得写点内容才对,否则真就是对不起观众~
zenwalk默认没有g77,gcc又是4.12,费了老劲找个gcc3.4.6带g77版本,几经波折,终于搞定cblas,第一个编译完成的cblas_example1.c,看着输出的结果,真是高兴.赶明儿整理一下经过.
补档
27 Mar 2009
VMWare虚拟机上网
Google了一下,利用下面的第一种方法搞定了.因为我本来就是NAT地址翻译,又不想共享连接.
详细方法如下:
##CONTINUE##
VMWare虚拟机最重要的问题就是能上网了,呵呵,下面我将介绍两种方法。
一。VMWare虚拟机安装后在服务里面可以找到有四个服务,可能太浪费内存了,你可以设为手动,停掉它,不会影响到第一种上网方式,如果你外面是通过局域网,你可以设置VMWare虚拟机和外面主机的DNS,网关一样,换个IP(最后一位换),就可以直接上网了,里面的IP 跟外面的IP是一样的。
二。第二种上网方式需要启动服务里面VMWare虚拟机的四个服务,VMWare虚拟机里面设置为自动获取,然后找到菜单 VM==>settting==>Ethernet 选择 Nat 方式上网,即可上网,如果不可以重启一下,据说这种上网方式和外面的主机IP是不一样的,可惜本人在使用的时候还是跟主机IP是一样的,如果有人知道请告诉我,在下面留言,谢谢。
可再参考本人找到一篇比较简明的文章:
有以下几种可选方法:
1、Bridged(网桥)方式,如果主机是通过局域网上网的,可让虚拟机使用与主机网段、网关和DNS等的相同的设置,选用一个有效的局域网IP即可。
2、NAT方式,使用VMWare提供的NAT和DHCP服务,虚拟机使用主机中的虚拟网卡VMnet8作为网关,并且TCP/IP设置需遵循程序中关于VMnet8的DHCP和NAT设置,如IP必须在其DHCP设置的StartIP和EndIP之间,网关需使用其NAT设置的Gateway IP。
3、共享主机的Internet连接的方式(如果主机是Win98系统可能不适用):在主机的“本地连接”属性的高级里面共享Internet连接,如果选的是VMnet1虚拟网卡,则在虚拟机的Ethernet设置需选用Host-Only;如果选VMnet8,则Ethernet设置需选用NAT。共享连接后,那个被选中的虚拟网卡的IP会默认被设为192.168.0.1,如果主机也是通过局域网的192.168.0.1网关上网的,则需把这个虚拟网卡设置为不同的网段IP,如192.168.1.1。这时候虚拟机里面就可以通过把这个虚拟网卡作为网关来上网了。
另:
1、第一种方式有一个缺点,主机拔掉网线后,虚拟机无法与主机通过网络的方式进行通讯。但是后面两种没这个问题。
2、使用过程中发现,只有第二种方式需要用到VMWare在系统服务中启动的三个服务。
3、第三种方式占用资源最少:只要使用一个虚拟网卡(可以停掉没有用到的那个虚拟网卡),并且那三个服务可以停掉。
个人还是喜欢NAT方式,免去了设置,最简单.
18 Mar 2009
Fix compile ERROR using Geany
18:53:55: 无法执行“ /home/daniel/code/test”(请确保已生成)Check the option under Build menu, and change the compile parameters as
18:53:55: 执行虚拟终端程序失败
##CONTINUE##
gcc -Wall -o "%e" "%f"Then you can use the buttons in toolbar to compile and execute programmes.
由于geany的默认设置下,工具栏那个编译按钮并没有生成可执行文件,所以需要手动更改,加上-o参数来指定生成文件即可.
1 Nov 2008
Remove all WINE menus from your "Application menu"
到此,关于应用程序的菜单问题就基本解决了,如果,还想做的彻底点,就继续下一步。
##CONTINUE##
删除残余文件
sudo rm -f /usr/share/app-install/desktop/wine.*你也可以到以下目录中去看看,有没有与wine相关的东东。如果有的话,也可删除掉。
~/.local/share/applications/~/.local/share/desktop-directories/
~/.local/share/icon/
Fix the problem that application menu can't be opened-Ubuntu
想试试,战斗过后,我被打败了,暂时的。
打开主菜单准备勾掉pps,奇怪的是,虽然已经从wine里卸载掉pps,
主菜单里仍然显示,就在我准备勾掉的时候,灾难发生了,所有的选项消失了。
想打开应用程序菜单,也死活打不开了。无奈ing...
后来,终于找到解决办法:
##CONTINUE##
用/etc/xdg/menus/applications.menu这个文件
将你坏掉的/home/your_user_name/.config/menus/applications.menu文件替换掉就可以了。
命令操作如下:
cd /home/your_user_name/.config/menus
mv ./applications.menu applications.menu.bak
cp /etc/xdg/menus/applications.menu ./
搞定收工!
30 Oct 2008
ubuntu8.10: wireless, video, audio, w32codecs
鼠标滚轮搞定,声音搞定。
唯一的问题就是nvidia的3d加速卡不能正确安装,显示有version173和version177可用,可是激活都是失败。尝试n次都不行。
最新消息,安装中文语言包之后再次启用version177,下载安装正常。赞一个。
##CONTINUE##
ubuntu8.10的硬件支持没话说了,绝对胜过xp,vista我没有试过。不知如何。
多媒体播放我还是用smplayer,这个简单
sudo apt-get install smplayer
然后安装w32codecs,否则不能看rm跟rmvb文件。
找来找去,很多源由于版权问题已经不再提供更新,只好自己去下了个deb包,安装。搞定。
Deb包: http://debian-multimedia.org/pool/main/w/w32codecs/w32codecs_20071007-0.1_i386.deb
tar.gz包: http://debian-multimedia.org/pool/main/w/w32codecs/w32codecs_20071007.orig.tar.gz
26 Aug 2008
VMware中安装Ubuntu后鼠标滚轮问题
sudo gedit /etc/X11/xorg.conf
将"Input Device" 这个section的
Option "Protocol" "ps/2"
替换为
##CONTINUE##
Option "Protocol" "IMPS/2"
我的xorg.conf原来没有这个语句,就添加了。
Ctrl+alt+backspace 重启X,还是没有效果。
网上在查了下,发现我的配置还少了句:
Option "Emulate3Buttons" "yes“
另外,我的驱动是: Driver "vmmouse"
而一般常见的是: Driver "mouse"
完整的配置段落:
Section "InputDevice"
Identifier "Configured Mouse"
Driver "vmmouse"
Option "Protocol" "ImPS/2"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons" "yes"
EndSection
13 Aug 2008
Ubuntu Tips - 关闭ubuntu下的响铃(beep)
关闭整个系统响铃
sudo modprobe -r pcspkr就行了。
最好的办法是加入到blacklist,方法如下:
在/etc/modprobe.d/blacklist中,加入blacklist pcspkr即可
-----------------------
今天虚拟安装了ubuntu8.04,发现系统的beep吓人
在shell提示符下面操作时会用到大量的Tab来自动补全,
这个时候机器的蜂鸣器就会嘟嘟吡吡不停。
关闭方法:
##CONTINUE##
(以 Gnome 为例)
在 System -> Preference -> Sound -> System Beep 中,
反选 Enable System Beep 这一项即可
23 Jun 2008
Ubuntu的Mac模拟
##CONTINUE##
第一步:下载Cursor , GTK和Icon的主题
在这里下载Cursor , GTK和Icon的主题:
下载
下载完毕后,点击System -> Preferences -> Appearance,然后点击Install,安装刚下载的主题Mytheme.tar.gz
载完毕后,点击System -> Preferences -> Appearance,然后点击Install,安装刚下载的主题Mytheme.tar.gz
安装完毕之后,点击Customize,在Controls标签下选择Mac4Lin_GTK_Aqua_v0.3,Icons标签下选择LeopardX,Pointer标签下选择Shere_Khan_X,Window Border下选择Mac4Lin_GTK_Aqua_v0.3。 、
现在你应该看到一些界面的变化了。
、
第二步:使用Compiz效果并安装Mac4Lin主题 、
打开一个terminal,输入
sudo apt-get install compizconfig-settings-manager
安装完之后,你就可以在System -> Preferences -> Advanced Desktop Effects Settings里面进行设置了。、
在terminal里运行:、
sudo apt-get install emerald
来安装Emerald,安装完之后在这里下载MacOS X Emerald主题:
http://gnome-look.org/content/show.php/Mac4Lin+Leopard+Emerald+Theme?content=68409
完毕后,打开System -> Preferences -> Emerald Theme Manager,点击Import、
加入你刚才下载的主题文件,然后点击refresh刷新、
第三步:安装Mac工具栏Avant Window Navigator
打开terminal,依次运行:
echo "deb http://ppa.launchpad.net/awn-testing/ubuntu hardy main" | sudo tee -a /etc/apt/sources.list
echo "deb-src http://ppa.launchpad.net/awn-testing/ubuntu hardy main" | sudo tee -a /etc/apt/sources.list
sudo apt-get update
sudo apt-get install awn-manager-trunk awn-extras-applets-trunk
如此安装完毕后,你可以到Applications -> Accessories -> Avant Window Navigator来设置你的Dock工具栏
虽然说AWN自带的主题挺好的,这里有一个更漂亮的
http://rapidshare.com/files/71511920/Transparent.tgz.html
在刚才的AWN Manager窗口里,点击theme -> Add,加入最新下载的主题。
第四步:安装桌面Widgets Screenlets(此步不是必需的)
你可以安装一些桌面的小程序Screenlets(Widgets)。
在terminal里运行
sudo apt-get install screenlets
第五步:下载Max OS的桌面壁纸
http://appleology.com/images/space-desktop.png
http://dr-photoshop.com/zfile/tutorials/wallpaper/OS%20X%20Wallpaper.jpg