WINE and CDemu


Previously I posted about installing software/game with different CD/DVD ISO images in WINE. But this method does not work in some installation ISO images. Because these installation will detect for the CD/DVD. The method above does not solve the problem because the installation does not detect the CD/DVD.

Recently, I found a better solution. It is CDemu. It is similar to DAEMON Tools in Windows. It will emulate the optical disc drive in Linux. As a result, it will produce /dev/sr0, /dev/sr1, and so on. Because it is a virtual CD/DVD, thus we have to load the image. It can be easily loaded by using gcdemu.

Once the image file is loaded, we have to mount the image as root. I mount the image to /mnt/cdrom. Then, in WINE, run the winecfg, then it will automatically appear the CD-ROM in Drives tab. In my case, it is E: drive.

Now, I run the installation from WINE, I can detect the image as CD/DVD.

Advertisements

JDownloader 2 BETA Japanese font


Previously I was reluctant to use JDownloader 2 BETA version. The main reason is that I will see boxes when the files contain Japanese characters. But this problem solved now.

As I am using Arch Linux, the JDownloader 2 is installed at /opt/JDownloader. We have to create two files:

  1. /opt/JDownloader/translations/org/jdownloader/gui/translate/GuiTranslation.en_custom.lng
  2. /opt/JDownloader/translations/org/appwork/swing/synthetica/LanguageFileSetup.en_custom.lng

The GuiTranslation.en_custom.lng is a copy of GuiTranslation.en.lng. So that the interface is still using English language. Then LanguageFileSetup.en_custom.lng is a copy of LanguageFileSetup.ja.lng. So that the font is using Japanese language font instead.

Open the JDownloader, change the User Interface language to “English (CUSTOM)”. Restart. Now, I can read the filenames properly.

Linux VS Windows


Recently my friend mentioned to me that, Windows is good enough for him, as long as he can complete his works. Then I argued with him, saying Linux is better. Then he asked me, in what sense. I suddenly don’t have any concrete answer.

As Linux user for several years, I already forgot why am I using Linux instead of Windows. I only remember that Linux is more developer oriented than Windows. There should have some other reasons that convince me to remain Linux user and some reasons make me keen of it. Thus, I have to compare two OSes so that I can give concrete answers next time.

Linux is free and open source. No need to pay for an OS, no need to p2p download and install a pirated version of OS. It is open source, if you are a geek, you may like to learn the source code of Linux.

Linux follows UNIX file system structure. This is a great characteristic I like. The file system structure with a root /, it is also the same thing I know about URL and internet. For Windows, it is still C: drive. And even my students today, they don’t know why it is C:, yet not A: or B:.

A little comparison for Linux and FreeBSD. Though both are UNIX-like OSes, yet I prefer Linux than FreeBSD. Firstly, Linux is more prevailing, such as various distros, various software target on Linux, and the market of Android. Secondly, Linux can be booted in logical partition, it can also be booted in FAT32 pendrive. Thirdly, Linux has a large community. Yet, Windows is just a Windows with Windows users.

Linux has strong shell, bash. Windows has PowerShell, yet I don’t know how powerful it is because I never use it before. Using bash and other commands I can grep, sed, gawk, and find to manipulate text files or binary files. Write the shell script using procedural paradigm with if-else and looping. Running Cygwin or MinGW/MSYS allows to use bash in Windows. Yet as a long term solution, it seems very weird.

Security is better, as Linux usually claims. Windows, due to the large market, hackers always target on it. One thing I don’t like on Windows is hiding the file extension by default. This makes users less aware about the file type. They can hardly differentiate a true image file or true video file from an executable file with image or video icon. They just execute the files without any awareness. In my opinion, Linux users are more computer proficient. This is one of the reasons that contributes to the security of the OS.

I agree that Windows software are more user friendly than Linux. This is because it is commercial software. That is because user friendliness is a factor to attract the users. However, the desktop environments such as KDE and Gnome are also user friendly to perform common tasks, for instance drag and drop. In my opinion, whatever Windows can do, it can also be done in Linux.

I agree there are some limitations in Linux: hardware compatibility and games. Hardware compatibility problem I always faced is the printer problem. However, this can be solved using VirtualBox, print through USB or network. There are games now available on Linux through Steam. However they are not my favourite. Playing games through VirtualBox or VMware does not solve the 3D problems in games. There is no other solution except using dual boot to play the games in Windows.

For true and stable working environment, I prefer Linux, and I will keep promote Linux to the students. Windows, for me, is just a good game console.

bash less resize terminal overflow problem solved


I always have a problem with terminal emulator when using bash but not zsh. The problem can be produced like this,

  1. Open any terminal emulator (gnome-terminal, xfce4-terminal, etc)
  2. Run any command with less, such as “ls |less”
  3. Resize the window to larger size, such as maximize
  4. Quit less
  5. Type anything in the terminal, then the text will not wrap to new line if the text length beyond the window size before resie. And it will overflow to the same line and overwrite the prompt.

This problem can be solved by adding “shopt -s checkwinsize” in .bashrc.