Autarchy of the Private Cave

Science, Society, Programming and Hobbies

  • Exits

  • Categories

  • Archives

  • Visitors' track

    Locations of visitors to this page
  • Tags list

  • Earn and spend


  • Exits

  • Ratings

    Science Blogs - Blog Top Sites website monitoring service
  • Archive for the '*nix' Category


    How to print a single page from PDF file using Linux command line interface (CLI)

    30th October 2008

    There are several ways to do that, I’ll describe the one which worked for me. Please note, that printing from CLI has an advantage of being able to print out something at work from the comfort of your home and ssh :) (provided that the printer is on and is loaded with paper).

    To extract a single page (or a range of pages), I used pdftops:
    Read the rest of this entry »

    Share This

    Posted in *nix, Software, how-to | 2 Comments »

    Citation and reference managers for Linux: short overview

    29th October 2008

    For some period of time, I had to switch to my Windows installation when writing articles with references, because I keep my references database there and there is an extremely convenient add-on for MS Office to insert citations and format bibliography on the fly.

    However, it is quite inconvenient to make/run programs/scripts under Linux, and then switch to Windows to describe the obtained results in the article-like form. Thus, I briefly investigated available citation managers for Linux.
    Read the rest of this entry »

    Share This

    Posted in *nix, Links, Science, Software | No Comments »

    Why I love Debian

    4th October 2008


    I love Debian, too.

    Though I prefer ‘testing’ (which is currently codenamed Lenny) over ’stable’ (aka Etch).

    Share This

    Posted in *nix, Links, Misc | 1 Comment »

    Debian, fgl_glxgears: Using GLX_SGIX_pbuffer… Segmentation fault

    1st October 2008

    If you get Segmentation fault when trying to run fgl_glxgears in your Debian desktop environment, most often this would mean that 3D acceleration isn’t enabled.

    For the case of ATI (and ATI Mobility) Radeon series, the easiest procedure would be (doing all as root, or prepending sudo to all commands):

    1. aptitude update, to ensure you’ve got the list of latest packages
    2. aptitude install fglrx-driver fglrx-control fglrx-kernel-src, for the actual driver; I also installed fglrx-atieventsd and fglrx-glx (these are driver-recommended packages)
    3. aptitude install module-assisstant, required for building the kernel module
    4. module-assistant prepare, to verify that you have everything needed for the module build procedure
    5. module-assistant update
    6. module-assistant auto-install fglrx, to build and install the fglrx kernel module
    7. depmod -a
    8. modprobe fglrx, to load the fglrx kernel module
    9. aticonfig ––initial, to configure ATI’s device section in /etc/X11/xorg.conf (for more options, see aticonfig ––help)
    10. reboot

    Read the rest of this entry »

    Share This

    Posted in *nix | No Comments »

    Which Hosting Control Panel to use for a Debian server?

    27th September 2008

    To cut the long story short: for the final evaluation, I had this line of control panels:

    SysCP: looks good to me (they have a working demo), has customer billing module. Unsure as to where it is used, but most probably sponsors are also the users of SysCP. Majority of support forums is in German.

    DTC: has no demo, only some screenshots. Has a set of packages for Debian lenny (which is a huge plus for maintenance and future upgrades). DTC is being developed by GPLHost, and is also used by GPLHost - so this is a live (used) distribution. Seems quite feature-rich.

    Virtualmin claims to be the “world’s most powerful and flexible web server control panel”. Virtualmin offers 4 means to control it: Web, mobile device, command line, and remote API. There are both screenshots and demo. Has both GPL and Professional versions. GPL version has a number of limitations, comparing to Pro version. From what I’ve read about Webmin (all three - Virtualmin, Webmin, Usermin - are just different “layers” of server control), it is a framework with a number of “interface scripts”, which allow to control various services. As such, it is easily extendible, but is not monolithic - in the sense of module inter-dependencies and action triggers.

    RavenCore, if it had a working demo, could be an option. It seems to be quite actively developed, but all the screenshots are outdated, and demo isn’t working. However, based on what I’ve read, at least some people seem to be satisfied with this CP.

    GNUPanel is a year-old control panel, but has a news item on the front page (dated August, 17) promising new, completely rewritten release somewhere in October. By the feature list, looks promising. However, I need the panel right now, and even in October, that will be quite a rough release, not really used/tested anywhere, so not a good option as well. But GNUPanel is a panel to check in half a year for progress.

    As the final choice, I had ISPConfig (which seems to be the best by people’s comments), and which is also quite widely used, and is easy to install onto Debian (at least the Perfect setup: Debian Etch says so), and DTC. I discarded Virtualmin (for the poor functionality of the GPLed version), RavenCore (for the lack of current descriptions and non-functioning demo), GNUPanel (which just isn’t ready yet), and SysCP (because ISPConfig seems better ;) ).

    As DTC has Debian packages (and will be easier to maintain/upgrade), I decided to try it first. I already have it installed (that’s easy, esp. if you first read the DTC Debian Express Setup). Later I might post my impressions from using DTC.

    Share This

    Posted in *nix, Notepad, Software, Web | 2 Comments »

    How to ssh through the unconfigurable NAT/firewall

    20th September 2008

    There’s a how-to on the topic at howtoforge.com.

    Note, that for the suggested solution to work, NAT/firewall should be “transparent” for outgoing ssh connections.

    Share This

    Posted in *nix, Links | No Comments »

    Vista Ultimate has a Linux benefit

    12th September 2008

    One of the benefits, offered exclusively by the Windows Vista Ultimate (not even by the Windows Vista Business), is

    running UNIX applications (via SUA, Subsystem for UNIX Applications) , which provides higher flexibility for Windows workstations.

    Where is the world going? :)

    And how soon will all the Windows users (not only Ultimate Users) benefit from the higher flexibility by running UNIX applications? :)

    Share This

    Posted in *nix, Humour, Misc | No Comments »

    Google Chrome is not for Linux?

    4th September 2008

    I’ve tried it already under Windows, but as my main OS is Debian, I can’t use it :(

    You can sign up for updates on Linux version.

    After reading the Google Chrome book, it is a long time waiting for it to be released for Linux….

    Also, I’m looking forward for the plugins to enhance Chrome. Although it did import my settings/passwords(?!)/bookmarks from Firefox, but it has no Foxmarks, AdBlock and some other goodies I’m now used to on all the computers I regularly use.

    Share This

    Posted in *nix, Links, Misc, Software, Web | No Comments »

    Debian-Med Project

    3rd September 2008

    There’s a Debian-Med project, aiming to

    develop Debian into an operating system that is particularly well fit for the requirements for medical practice and research

    Debian-Med has several web sites/pages: one at Debian.org (descriptive), and the actual project’s website at debian-med.alioth.debian.org. There’s also debian-med wiki (for developers).

    As of nowadays, Debian-Med has released a number of Debian packages, which are grouped into respective Debian Med Tasks. The Biology-dev task, for example, contains MCL and libsbml packages (among many others).

    Check this project out - you might find that the software you need is already available as Debian package.

    This post was stimulated by Steffen’s comment.

    Share This

    Posted in *nix, Links, Science, Software | No Comments »

    Installing libsbml on Debian (to make iBioSim start)

    30th August 2008

    There’s a troubleshooter for Ubuntu, which (expectedly) works quite the same for Debian (lenny in my case).

    I’m installing libsbml to make the iBioSim tool work under Debian GNU/Linux. First thing I had to do was to make Sun’s java interpreter do all the java interpretation work instead of gcj: sudo update-java-alternatives -s java-6-sun (this assumes you do have java-6-sun installed).

    Installing libsbml moved me one step further, now I’m getting another error from iBioSim:

    Exception in thread "main" java.lang.NoClassDefFoundError: biomodelsim/BioSim
    Caused by: java.lang.ClassNotFoundException: biomodelsim.BioSim
            at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
            at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
            at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
    

    This yet has to be fixed somehow.

    If Zhou Xin’s blog becomes for any reason inaccessible (or moves to his own domain), below is the extract of the instructions from his post on how to install libsbml on Debian/Ubuntu Linux:
    Read the rest of this entry »

    Share This

    Posted in *nix, Links, Science, Software, Systems Biology | 3 Comments »

    Gnome, NetworkManager, and FireFox/IceWeasel 3 starting in Offline mode

    19th July 2008

    For some reason, my IW 3 is now starting in Offline mode each time, despite my attempts to remove that checkbox every time.

    Update: as suggested by Donny Kurnia (based on the recent post by Hobgoblin), the simplest and the most correct way to fix the problem is to go to about:config and set toolkit.networkmanager.disable to true.

    Below you will find other (worse and obsolete) solutions.
    Read the rest of this entry »

    Share This

    Posted in *nix, Web | 8 Comments »

    debian.org.ua: universal Ukrainian Debian mirror

    15th July 2008

    http://debian.org.ua/ and ftp://debian.org.ua/

    What is on offer (mirrors):

    • backports.org
    • cygwin
    • deb.opera.com
    • debian - stable, testing, sid
    • debian-archive (starting from 1.1!)
    • debian-multimedia
    • installation media (CDs/DVDs)
    • debian-security
    • even debian-volatile is here!

    All this goodness is only 3 hops away from my DSL modem…. (ISP UkrTelecom)

    Gone editing /etc/apt/sources.list :)

    P.S. For non-ukrainian IPs, access might be slow/bandwidth-limited; for Ukrainian IPs, speed might be up to 100MBit/sec.

    Update: some time after publishing this post, debian.org.ua was down for some reason. When it was up, it was serving me packages with a mere 3 kb/sec :( . I found that ftp2.debian.org.ua mirror is faster at the moment.

    Share This

    Posted in *nix, Links | No Comments »

    Internet Explorer 6 for Linux

    13th July 2008

    IEs4Linux provides a convenient package of Internet Explorer 5.0, 5.5, 6.0, and (partially supported) 7.0 for Linux.

    It installed and runs fine under Debian Etch:

    IE6 under Linux screenshot

    However, as you could notice from the screenshot above, CPU use is almost 100% while IE6Linux is running. It is better illustrated by the next screen:

    IE6 under Linux: high CPU use

    I didn’t yet bother finding out what’s wrong, but that must have some kind of a fix, as running at 100% CPU on a laptop is … hot.

    Share This

    Posted in *nix, Links | No Comments »

    Concise guide to CPU frequency scaling in Linux

    11th July 2008

    Debian HOW-TO: CPU power management / frequency scaling

    Share This

    Posted in *nix, Links | No Comments »

    Enabling special buttons (keys) on laptops under Linux

    8th May 2008

    Note, that under Gnome I only had to use a single system-wide utility to bind volume buttons to volume control. Under KDE things were a tad tougher.

    First, you may want to look for kmilo (if you don’t have it yet). It has several plugins e.g. for ThinkPad and Vaio laptops, as well as “generic” plugin. I didn’t try this solution, though.

    If you need more than kmilo can offer: keyTouch could help. keyTouch should be good also for non-laptop multimedia keyboards. However, this also wasn’t the solution I used.

    If you want to know how to map your special keys to functions yourself - then read on.
    Read the rest of this entry »

    Share This

    Posted in *nix, Links | 4 Comments »

    SystemRescueCD

    15th March 2008

    Earlier, I wrote about Universal boot CD , which is targeted primarily at the hardware testing/diagnosing.

    If not hardware, but “only” software is malfunctioning - try SystemRescueCD, a Linux-based recovery CD/DVD/Flash stick (it all depends on how you burn/install the downloaded file - manuals and how-to’s are available).

    As always, Disclaimer: I am in no way associated with SystemRescueCD, and gain no profit from this post. Any advice I give is provided AS IS, with no guarantees of fitness to your exact case.

    Share This

    Posted in *nix, Links, Notepad | 3 Comments »

    Instructions on installing libmp3lame-enabled ffmpeg on shared linux hosting

    12th March 2008

    Note: this post is based on the comment by Simon, who generously shared his experience.

    Step-by-step:

    • Download the compiled ffmpeg with libmp3lame support (direct download links: older version ffmpeg.with.lame and newer version ffmpeg.2007-10-28.with-libmp3lame-support).
    • Rename the downloaded executable file to "ffmpeg" (no extension), upload it to the directory on your server (in this example /home/myusername/).
    • Download libmp3lame.so.0.
    • Upload libmp3lame.so.0 to the same directory where you placed ffmpeg in.
    • Create a php file with the following code (remember to change the paths to your own, where you actually uploaded binaries in previous steps):
      PHP:
      1. <?php
      2. exec("export LD_LIBRARY_PATH=/home/myusername/");
      3. echo passthru("/home/myusername/ffmpeg -formats");
      4. ?>

    • If you access that PHP file with your browser, you should be able to see a list of formats which are supported by ffmpeg, and if you find "EA libmp3lame" somewhere in the output, then it means you now can Encode Audio in libmp3lame!
    • If that doesn't work for you: LD_LIBRARY_PATH can be a protected variable in PHP (you can check for this by searching for the "safe_mode_protected_env_vars" value in phpinfo() output). The workaround here can be to write your commands to a file from php, then chmod that file with 0775 permissions (rwx-rx-rx), and run the file through exec(). In this way, PHP is not changing the LD_LIBRARY_PATH, but telling the server to run a file, which tells the server to change it. This method worked for the original author of these instructions.

    For passing arguments to the PHP wrapper script - check out PHP's $argv variable (more on this here). If you decided to use shell-script as a wrapper for "export LD_LIBRARY_PATH", then using $1, $2 etc will allow you to pass parameters to the shell script, e.g. in the example below

    CODE:
    1. export LD_LIBRARY_PATH=/home/myusername/
    2. /home/myusername/ffmpeg -i /home/myusername/$1 $2 /home/myusername/$3

    you could pass "input file" as first argument, "parameters" as second and "output file" as third to make such a wrapper script work.

    Share This

    Posted in *nix, PHP, Programming, Software, Web | 9 Comments »

    Using libmp3lame-enabled ffmpeg on shared hosting

    25th October 2007

    Update: there's now a much more recent post on how to install libmp3lame-enabled ffmpeg on shared linux hosting.

    As Gabe pointed out in my post with compiled ffmpeg Linux binaries, there is a relatively simple method of adding libmp3lame.so.0 file to your shared hosting so that ffmpeg executable will see the library:

    You can upload libmp4lame.so as well to the shared hosting site and when you call ffmpeg, call something to set an environment variable right before the call to ffmpeg i.e. in php I’d do exec(”export LD_LIBRARY_PATH=/path/to/lib/with/lame; /path/to/ffmpeg [ffmpegargs]”); That way you can use the uploaded lame. I hope that helps someone as I have been unable to find any info on how to use an uploaded lame. I’ve tried it and it works on godaddy.

    Hope this helps.

    Update: here's libmp3lame.so.0.0.0 (from slackware 2.4.x, lame-3.97). I have no idea if it'll work in your (shared hosting) environment; it is provided AS IS, use at your own risk etc. I can only state that the archived binary file at the moment of upload was indeed libmp3lame.so.0.0.0 from my elderly Slackware with 2.4.x kernel.

    Share This

    Posted in *nix, Software, Web | 9 Comments »

    Fresh install of Debian Etch 4.0r1 hangs/freezes dead after boot: solution

    24th October 2007

    Recently, I installed Debian Etch 4.0r1 onto my laptop. However, after the first boot into plain console, computer was dead-frozen after some console usage. I rebooted using the Power button - this time to gdm; and again, after some keyboard input system was hanging dead.

    I found the reason here. Basically, it's the PC speaker module (pcspr) not functioning correctly. I suspect this problem manifests itself only on some types of laptops. The solution is either to somehow reconfigure the pcspkr module, or just disable it. More on how to disable the module below.
    Read the rest of this entry »

    Share This

    Posted in *nix, Links | No Comments »

    GoDaddy: undocumented 20-second CPU time maximal execution limit? (python, ELF, etc)

    16th October 2007

    Today, setting up a relatively serious (in CPU resources needed) web-system, I ran into a weird problem of python scripts ending prematurely. After some investigation, it looked like any process which uses up more than 20 seconds of CPU time, is automatically killed. To verify this, I wrote an infinite loop in C,

    C:
    1. int main () {
    2.  unsigned int i;
    3.  
    4.  for (i = 0; i <2 ; i++ ) {
    5.   i = 0;
    6.  }
    7.  
    8.  return 0;
    9. }

    compiled it and executed several times on the GoDaddy shared hosting server. I did observe the program running for the maximum of 20 seconds of CPU time, not a second more. Please note, that 20 seconds of CPU time can be much more of "real" time, if the script isn't using 100% of CPU, which often the case for shared hosting. Thus if you have in your php.ini max_execution_time set to, say, 60 seconds, your php script may actually execute as long as one minute; but I'm pretty sure that if your script has lots of CPU-intensive procedures, then as soon as it uses 20 seconds of CPU time, it will be terminated (however, this statement still needs checking - anyone?).

    To verify, I also created a cron job with the same file. It ran for 30 seconds CPU time.

    Strangely, this behaviour is not documented anywhere.

    This limit may also explain a number of other problems, if you have heavy web-applications: they just might be killed before they are finished, causing errors.

    I do understand the reason for this limitation, and am sure similar limitations exist in other shared hosting environments. The only important thing here is that this limit should have been documented and even put upfront somewhere in the hosting plans descriptions.

    I also wonder if the limit is the same for all godaddy shared hosting plans, or if it differs. 20 seconds when executed from PHP, and 30 seconds when executed as a cron job were observed on the Deluxe Linux Hosting plan.

    Extensions, additions and comments are welcome.

    Share This

    Posted in *nix, Misc, Programming, Web | 5 Comments »

     
    Close
    E-mail It