Arch Linux upgrade, downgrade, and rollback
One of the reasons, I recently consider to switch from Arch Linux to Debian which is famous in stability. However, I am very reluctant to do so, because of the greatness of simplicity in package management of Arch Linux, especially creating packages in AUR. Debian, though famous, there is much manual work in packaging such as preparing the “control” file (may be there are some other tools I not yet explored, because I used Ubuntu and Linux Mint before for only a short period). Besides that, Debian does not have the repository like AUR. Installing the packages such as TrueCrypt and XnViewMP in Debian is not as easy as Arch Linux. That is why I am hesitated to migrate.
Arch Linux manual recovery
Though SystemRescueCD is powerful, if it is system specific, then it cannot work. With the recent changes of the Arch Linux filesystem, I made a mistake that I cannot start Arch Linux after a careless reboot.
The instruction from the official site mentions,
- Fix any non-official packages with files in /bin, /sbin or /usr/sbin to put those files in /usr/bin.
The term “fix” does not give me too much solution about the packages. These packages mostly come from AUR. What can I do to “fix” them? There is no much hint for me. Thus, I ignore this part, though I can list those packages.
Extracting files from zip which contains non-UTF8 filename in Linux
Previously, I have made a post about extracting SHIFT_JIS filename encoding in zip file.
However, this method does not work when the filenames contain GBK (simplified Chinese) encoding. As a result, I found a general solution for the non-UTF8 encoding.
The method is almost the same, but more generic way.
Firstly, the problem we face is after extracting the files, the filenames are unreadable. Not only that, we cannot convert the filename even we are using “convmv”, “iconv”, or even “uconv”. This is normally caused by our OS locale setting. To make our OS (Linux) more generic to read almost any languages (East Asia languages, right-to-left langues, etc), our OS is normally has the UTF8 locale. It may be en_US.UTF8, ja_JP.UTF8, zh_CN.UTF8, zh_TW.UTF8, en_GB.UTF8, etc.
IBus (input) 1.5 problems and solutions
I am using Arch Linux. Recently updated an old computer, the IBus from 1.4 to 1.5. As a result, there were two problems.
- Cannot input anymore in any window, except Opera(?)
- IBus Pinyin cannot change to “Full pinyin” mode, but only “Double pinyin” mode.
For the first problem, it doesn’t happen in my other computers. For the second problem, it happened in my other laptops.
To solve the first problem, I tried several ways. Deleting the “/.ibus”, “/.cache/ibus”, “~/.config/ibus”, and “.gconf/desktop/ibus”, none of them can reset IBus to the default setting (initial setting). I wanted to reset the configuration because I know that it should work well, because it does work well in my other computers. However, none of the directories is able to solve the problem, finally I chose to reset the GConf and dconf. (I personally think that dconf is the one storing the latest version’s setting).
Arch Linux and Canon PIXMA iP1600
I tried to escape from the Windows dependency problem. Wishing that all my devices can work without problem with Linux. But one of the greatest problems is that Canon PIXMA iP1600 does not have driver for Linux, except using iP2200 which is compatible.
Previously, I solved this problem with the virtualisation. This work perfectly to do my printing. However, it is still depending on Windows. Without Windows, the virtualisation is almost useless.
Knowledge Tree
This is an interesting thing. I love the tree so much. The Knowledge Tree here I mean is not referring to the Tree of Knowledge of Good and Bad.
Tree is a graph theory. The powerfulness of tree, is that almost any data structure can be represented into the tree. In order to store the data, we can use a single variable, for a single data. In order to store a list of data, we can use array and associative array (or hash, map, dictionary), list, vector, and others. Another powerful data structure which I like is the 2D array, especially used in matrix calculation. The 2D array represents the data in the table form. It is very useful in database. An image can also be treated as 2D array. Comparing the tree to the matrix, the tree is possible to represent the matrix (though it is not preferred).
Database or spreadsheet?
Sometimes we use spreadsheet to store data as table just like database. Especially the features provided like sorting and filtering. This allows us to look at the data easily without the knowledge of SQL (structured query language). Furthermore, we can add in the rows easily, do calculation using formulae, and also copy-paste the data to any cell. Comparing to database, the data needs to be filled row by row, this is the main drawback. This is why spreadsheet is easier to use.
aMule high CPU usage solution
I use aMule. But even with the SVN version from Arch Linux, it produces the same problem as I was using Linux Mint, high CPU usage problem. It works well at the beginning, but will suddenly high CPU usage, causes my laptop battery drain very fast.
So, I try to find the solution. Then, I found one solution, not like using MLDonkey or other alternatives before.
Using the aMule daemon, amuled from command line.
Linux shutdown battery draining problem solved
My HP laptop always has a shutdown problem. This problem affected the hibernation. That is, after I shutdown in Linux, my laptop battery will keep draining, and the battery is still warm after shutting down.
To solve this problem untechnically, there are two ways. Never shutdown, but restart. Because I have dual boot, there is a grub menu when startup the computer. So, during the grub menu, press the power button, this will shutdown the computer without battery draining.
Arch Linux with Canon iP1600 printer (virtualisation)
Finally, I solved the problem doing printing with my Arch Linux with Canon iP1600 printer. It is an old printer. With several tries of those drivers mentioned in forums and other discussions, I never success to use this printer with Arch Linux. That is why, whenever I want to print, I need to reboot into Windows 7, print, then reboot into Arch Linux again. This is really troublesome.
However, recently, I found a possible solution. That is using hardware virtualisation. Actually, it is using the guest OS to detect the printer, then print from the guest OS. So, my guest OS is still Windows. Meaning that, Linux is still not working with Canon iP1600. But, this solution avoid rebooting for different OSes.