How to check kde version?
To check the version open the K menu. You should have there the KDE Control Center or About KDE. Start it to check the KDE version. KDE 1.90 means KDE 2.0 Beta 1, KDE 1.91 means KDE 2.0 Beta 2.
9/27/06
Question of today.
9/18/06
Compiled kdevelope3.3.4
There was some errors about Java stuff. Used "make -k " and "make -k install"
9/17/06
ldconfig.
Creating /etc/ld.so.conf
Some softwares need to set the shared library in order to run. Here is part of the INSTALL file from qwt-5.0.2.
To install examples:
cd examples
qmake
make
If you like to run the examples, don't forget to install the
Qwt library/plugins or set the LD_LIBRARY_PATH to the lib directory
of your local build. ( On some systems LIBPATH is used instead, on MacOSX
it is called DYLD_LIBRARY_PATH. )
The above can be done by:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/qwt-5.0.2/lib/
Or by the following way--modify ld.so.conf
Create a new file /etc/ld.so.conf containing:
# Begin /etc/ld.so.conf
/lib
/usr/lib
/usr/X11R6/lib
/usr/local/qwt-5.0.3/lib# End /etc/ld.so.conf
Update the dynamic loader cache by running:
ldconfig
Also check "man ldconfig"
There is a nice article about "shared library"
9/15/06
9/1/06
8/27/06
E: Dynamic MMap ran out of room
> I created an apt.conf file in /etc/apt and added;
> APT::Cache-Limit "141943904";
Install softwares from unstable distribution.
Want to install the following softwares which exist in unstable version of debian.
1. F-spot: personal photoes management.
2. Beagle.
According to the help provided by the following link:
The following are copied from the above link just in case this link disappears.
3.8 How to keep a mixed system
People are sometimes interested in using one of the Debian versions as its main system distribution and one or more packages from another branch.
To set up what is your main version of Debian you should edit the /etc/apt/apt.conf
(it does not usually exist, create it if you don't have one) to contain the following line:
APT::Default-Release "version";
Where version is the version of Debian you want to use as the main distribution. The versions you can use are stable, testing and unstable. To install packages from another version, then, you must use APT in the following way:
# apt-get -t distribution install package
For that to work, though, you need at least one APT source line in your /etc/apt/sources.list
for the distribution you want the package from, and the package must exist on that source.
You can also request a specific version of a package using the following sintax:
# apt-get install package=version
For example, the line below will install version 2.2.4-1 of the nautilus
package.:
# apt-get install nautilus=2.2.4-1
IMPORTANT: the `unstable' version of Debian is the version to which the newest versions of Debian packages are uploaded first. This distribution sees all of the changes that packages go through, both small ones and more drastic ones which affect many packages or the whole system. For this reason, this version of the distribution should not be used by inexperienced users or by those who need proven stability.
The `testing' distribution is not necessarily better than `unstable', because it does not receive security updates quickly. For servers and other production systems stable should always be used.
I did not succeed doing this. There is dependence problems.
8/13/06
lpr and lp.
Today I deleted lpr and related packages, need to check whether printing is still working ok.
Everything works ok. So I don't need lpr, but the lp. Use "lp" to print and "lpstats" to see the jobs and printers.
8/12/06
speedup linux reboot.
1. When reboot, use the following command:
/sbin/shutdown -rf now
This command will skip fsck which takes a lot of time, especially when the hard drive is huge. If you want to force the system to do disk san, then use the following command:
/sbin/shutdown -rF now
2. Use "sysv-rc-conf" to manage the startup services. here is the detail explanation
8/7/06
openoffice crashes under debian sarge.
This problem is due to
libfreetype6
Do the following to fix it.
1. First find any debian mirror http://www.debian.org/mirror/list
goto /pool/main/f/freetype/ and download libfreetype6_2.1.7-2.4_
and libfreetype6-dev_2.1.7-2.4_
2. Eventually download the dev package as well as root use
dpkg -i
to downgrade the packages
3. Finally, I used aptitude to mark the packages as 'hold' to prevent them from
updates until some coming package of either freetype6 or oo will be flawless.
Reference
Search my own blog.
In order to search the blog, need to first log in. If don't login, the search is very bad.
8/5/06
My favourite linux programs.
1. Internet related
- firefox
- gftp
- ktorrent (this one works under kubuntu)/bitTornado (under sarge).
- kget/wget
- Akregator (news reader).
- R
- mathematica (commercial software)
- Matlab (commercial)
- Jabref (bibliograph management)
- Gimp
- xfig
- picasa (from google)
- ksnapshow (used to capture the screen)
5. Personal information management (PIM)
- Kontact/korganizer
- sysv-rc-conf , which can config the startup services.
- kdevelope
- designer (QT)
- code-navigator
- source-navigator
There are differences between boot sector and its backup
Use the following to fix it.
sudo dosfsck -ar /dev/your_fat32
original -> backup
8/3/06
Xlib.h can not find.
When compile sources, sometimes this error appears. First need to install xlibs-dev such development packages. After that, if it is still there, use:
./configure --help
to see the options can be used. Usually there are options such as :
--x-libs with which you can define the path.
7/27/06
Openoffice and MSoffice formula problems.
Here are the links.
http://www.oooforum.org/forum/viewtopic.phtml?t=24498
http://www.oooforum.org/forum/viewtopic.phtml?p=36104#36104
7/8/06
Linux security.
1. Edit /etc/hosts.deny and add:
ALL: ALL
2. Edit /etc/hosts.allow and add:
ALL: LOCAL @xxx.edu
ALL: .xxx.edu
3. Use guarddog to turn off any service (local) except sshd.
7/7/06
Jabref and Endnote.
Briefly.
Jabref To Endnote.
1.Install the Endnote filter which can get from the source file of Jabref (jabref-version/lib/Endnote.zip, it includes a help file).
2. First use Jabref to export the references using "endnote" format.
3. Use Endnote import function to import the file generated in 2, need to select the filter as "EndNote Import from JabRef"
4. Done
Export from Endnote to Jabref.
1. Export from Endnote, using Endnote export fileter.
2. Import from Jabref select "endnote" format.
3. Done.
EndNote Export Filter
Export from JabRef
JabRef can export databases to EndNote-readable files. To use this feature, choose File -> Export -> EndNote, then specify the name of the export file.
Import to EndNote
The default EndNote Import filter does not handle multiple authors or editors properly. There are two options to work around this:
Use the built-in filter and fix the file later. To open up the file in EndNote, create a new database or open an old database in EndNote. Then select File -> Import, click on Choose File, then highlight the exported file and click Choose. Click on Import Options and select EndNote Import. Click Import to start the import. After import, select Edit-> Change Text. Change Any Field to Author. Enter " and " into the search field (without quotes). enter a return character into the change field (option-return on Mac OS X, ctrl-return on Windows XP). Click Change. Repeat with the Secondary Author field.
Install the EndNote Import from JabRef filter in the EndNote Extras. Follow the instructions in Advanced Use below. To open up the file in EndNote, create a new database or open an old database in EndNote. Then select File -> Import, click on Choose File, then highlight the exported file and click Choose. Click on Import Options and select EndNote Import from JabRef (if it does not appear, select Other filters. If it still doesn't appear, it was not correctly installed.) Click Import to start the import.
Notes
The EndNote Export filter maps BibTeX entrytypes to EndNote reference types as follows:
BibTeX entrytype -> Endnote Reference Type
------------------------------------------
misc, other -> Generic
unpublished -> Manuscript
manual -> Computer Program
article -> Journal Article
book -> Book
booklet -> Personal Communication
inbook,incollection -> Book Section
inproceedings -> Conference Proceedings
techreport -> Report
mastersthesis, phdthesis -> Thesis
Corporate Authors
By default, the export filter assumes that entries in the author or editor fields in brackets are corporate authors and replaces the brackets with a trailing comma. However, this means that entries that include LaTeX code in brackets will be assumed to be corporate authors and therefore will be improperly formatted.
Advanced Use: Endnote Extras
Installing the EndNote Import from JabRef filter
The default EndNote Import filter does not properly parse authors. The EndNote Import from JabRef filter does. Additionally, this filter will recognize a field endnotereftype that will override the default mapping. To install the filter, extract the EndNote Extras (File -> Export - > Unpack EndNote filter set) and unpack the Zip file which is created. Then follow the directions in the file Readme.txt.
Modifying EndNote Reference Types
Several fields used by BibTeX are not part of EndNote's default Reference Types. While import from JabRef and export to JabRef will work fine without modifying reference types, the field names will not display correctly in EndNote (e.g. an entry window will call the pdf field Custom 1 instead of pdf. Additionally, these fields cannot be added to new entries in EndNote, since they will not appear in the entry window. To modify the EndNote Reference Types, extract the EndNote Extras and follow the directions in the file readme.txt.
Export to JabRef
EndNote comes with an export style BibTeX. However, this does not support all BibTeX types and fields, and does not support the additional General Fields supported by JabRef (pdf, owner, key, etc.) If you wish to have these fields supported, extract the EndNote Extras and follow the directions in the file readme.txt.
Attacked by hackers.
Security Events
=-=-=-=-=-=-=-=
Jul 7 04:10:55 localhost sshd[10430]: Illegal user admin from ::ffff:203.134.243.24
Jul 7 04:11:03 localhost sshd[10434]: Illegal user admin from ::ffff:203.134.243.24
Jul 7 04:11:06 localhost sshd[10436]: Illegal user admin from ::ffff:203.134.243.24
Jul 7 04:11:09 localhost sshd[10438]: Illegal user admin from ::ffff:203.134.243.24
checked with
"whois 203.134.243.24"
It is from Beijing. Turned on firewall and turned off sshd and httpd (use guarddog).
7/2/06
edit plugger configuration file.
The file exists in /ect/pluggerrc-version_number.
You can modify this file to config plugger.
6/15/06
6/14/06
Check disk under windows XP
Also try running chdsk on your harddisk, assuming you only have a c: drive, do this:
click start, run, type in cmd, that brings up a dos window,
type in: chkdsk c: /i /c [there is a space between chkdsk and c: and between c: and /i and between /i and /c ]
hit enter, see if any errors are reported, you will need to add one thing to that to fix them, like this:
chkdsk c: /f /i /c
the /f will fix errors, but don't do it until you are sure you need to, if you have errors in certain places and they get fixed your system might not run.
6/13/06
Use Chinese input under English enviroment.
First look at this one to set up the locales and scim correctly. In my case most of the time I use English as my default system language. When I want to input Chinese, I use the console to start the program.
In a console do the following:
> export LC_CTYPE=zh_CN;
> export XMODIFIERS=@im=SCIM;
> scim -d
> soffice (I want to start openoffice here)
Then in the openoffice, should be able to activate the Chinese input method.
6/12/06
Change fonts.
Refer to this mini-howto
Also changed the resolution of screen. Now the setting is: 1280x1024 @75Hz.
6/10/06
Setup Chinese Input for debian Sarge.
This will demonstrate my process to setup the Chinese input.
1. Setup the Xwindow system correctly.
2. Generate locale > dpkg-reconfigure locales
(if locales is not installed yet, use: apt-get install locales)
Select the following locales:
en_US.ISO-8859-1
en_US.UTF-8
zh_CN.GB2312
zh_CN.UTF-8
You can check what locales are installed in your computer by: locale -a
3. Install the required fonts.
> apt-get install ttf-arphic-bkai00mp ttf-arphic-gbsn00lp ttf-arphic-bsmi00lp
ttf-arphic-gkai00mp
4. Install scim input method > apt-get install scim scim-tables-zh
5. Make scim startup once xwindows is activate.
When Debian start the X windows, it will execute the shell script in /etc/X11/Xsession.d/. We can set up a script file and save it there. In this script file, we will define the variable "XMODIFIERS" and execute "scim" which is installed in the previous step. We call this script file as "95xinput" (save it in /etc/X11/Xsession.d/), and it contains the following:
case "$LANG" in
zh_TW*)
/usr/bin/scim -d
XMODIFIERS="@im=SCIM"
;;
zh_HK*)
/usr/bin/scim -d
XMODIFIERS="@im=SCIM"
;;
zh_CN*)
/usr/bin/scim -d
XMODIFIERS="@im=SCIM"
;;
esac
export XMODIFIERS
The above script will start "scim" when you login using Chinese as the system language.
6. If you are using GDM, you can choose "Chinese" as the system language. But if you are using xdm or kdm where you have no options to choose system language, you may need to add
" export LANG=zh_CN.UTF-8"
at the beginning of the above file (95input). This will choose the system language for you.
If you start the X window from a console, before you type in "startx" to start the X window system, you may want to "export LANG=zh_CN.UTF-8" first. Or you can put it in your ~/.bash_profile. Now scim should be activated automatically, and should be able to use. Part of this help comes from here
Here are some other good references.
Good poster http://www.linuxquestions.org/questions/showthread.php?t=262442
another one
This is a very sysmatic one.
and this
6/6/06
Installing OpenOffice.org 2.0 for Debian
When you download openoffice, usually you will get bunch of rpm files. Then how to install these files in a debian system? Here is a very nice article which will guide you to go through this process.
Basically use the following command to finish the installation (this is better than the above link expplained).
alien -k *.rpm(this will generate the deb files)
dpkg -i --force-overwrite *.deb (--force-overwrite helps when files belong to different packages).
The above command will install the software. Then go to "desktop-integration" folder to install the start menue.
dpkg -i *.deb
6/4/06
Use different printers to print.
lp -d printername
Use the following command to check the status of the printer "printername"
lpq -P printername
Add network printer.

If you can not find the driver for your printer,
maybe you want to install using aptitude
5/29/06
scim and emacs shortcuts confliction.
Scim usually use C_space to activate input method, and emacs uses C-space to set mark. This confliction can be solved by changing the shortcut for scim to C_shift_space by using the scim control panel.
5/26/06
5/25/06
use cxoffice to run MS word and Endnote.
Need to start Endnote first, then start the MS word. Otherwise the process will die.
5/22/06
Change the default language of gimp.
The system's default language is Chinese. So when I start Gimp from the menue, Gimp automatically use system default language as its default. But I want to change the default language for Gimp to English. This can be done by "Edit Menue". Click the "start" menue(the K menue), then right click to select "edit menue". Then choose gimp to edit. Here is the picture.
In the command item, add
LANG=en_US
and save the config. Now if you start gimp again, it will use english as the default language.
5/21/06
Make the research schedule as detail as possible.
I failed to follow the time schedule. The reason for that is I forgot to put details there. When I did the experiments, I found that I forgot to take the treatment time into account. That means I planned to finish in 2 hours, but actually it need four hours, which included 2 hours for treatment before the real experiments. This should be avoided.
Change eps file to fig file.
Xfig is a very nice software. It can edit the vector graph. For me, sometimes I plot curves to eps files, then I want to do some simple modification. It is easy. I just convert the eps file to fig file, then use Xfig to do the modification. After that, if I want I can export to eps again. Then you can use it in your Latex file.
pstoedit -f fig filename.eps > filename.fig
Linux software upgrade.
I lost some data from my previous wiki page. The following suggestions are very general other than specifically for mediawik.
As with all MediaWiki upgrades, the basic premise is the same:
- Check the requirements
- Read the release notes
- Back up existing files and the database
- Unpack the new files
- Run the update script to check the database
- Test the update
MySQL 5.0 install and management.
Can be installed by apt-get. After that need to change the root's password by following:
mysqladmin -u root password 'password'
Then add users inside mysql.
mysql> GRANT USAGE ON *.*
-> to Dave@localhost identified
-> by "password";
The most common use of mysqldump is probably for making a backup of an entire database:
shell> mysqldump --opt db_name
> backup-file.sql
You can read the dump file back into the server like this:
shell> mysql db_name
< backup-file.sql
5/20/06
5/19/06
Openoffice and MS office problems.
When I highled the background using oowriter and save the file as .doc file, I cannot get rid of the background highlight using MS office.
5/18/06
Mutt can not open the mbox.
When I changed the default language to Chinese, then I have such problem. Saying "segment fault" or “段错误”. Fix this problems by adding at the end of .bashrc the following:
export LANG=en_US.ISO-8859-1
export LC_ALL=en_US.ISO-8859-1
This will change the language for the konsole to English. Now use mutt again, the problem disappeared.