5th January 2009
Unix SEX :{ look; gawk; find; sed; talk; grep; touch; finger; find; flex; unzip; head; tail; mount; workbone; fsck; yes; gasp; fsck; more; yes; yes; eject; umount; makeclean; zip; split; done; exit:xargs!!;)} (source: someone’s signature in the Debian mailing lists).
download Unix/Linux command reference by Jacob Peddicord/FOSSwire.com
Posted in *nix, Humour, Notepad | No Comments »
25th December 2008
One of my projects – COTRASIF – has grown complex enough to necessitate the use of version control system (VCS).
The most frequently mentioned is definitely SVN (SubVersion).
However, with a characteristic scrupulosity, I decided to run my own comparison of the available tools. I had a look at Darcs, Mercurial, SVN, and Git. Of these, only SVN is not a distributed VCS (but there is SVN addon which adds distributed features to SVN). Unfortunately, I didn’t take any notes during comparison, so there will be no details on how the choice narrowed down to Mercurial vs Git. These dVCSs are quite similar, with the following major differences: Mercurial is better documented and (much?) easier to use than Git; Git is more feature-rich, and Git currently has more add-on modules. Here the differences almost end. I decided that learning curves never were an obstacle, so Git is currently my first distributed VCS of choice (please note: I’ve never before used any version-control systems).
After choosing Git, I had to install Git central repository on a server. (Yes, Git is distributed, but central repository on the always-on server is a convenience worth the trouble; and again, this adds yet another backup copy.)
This is a collection of resources I found useful when setting up my Git repository:
- Hosting Git repositories, easy and secure way (note: do not create the user manually, installation of gitosis package does that for you automagically).
- Setting up Git repository on Dreamhost.
- gitosis: how to add new repository
Some more resources on how to use Git:
- Git user manual
- Git guide
- Git recipes (branching and merging in examples)
- everyday Git with 20 commands
- version control with git – tutorial
Update: Git is simple enough to get started in minutes. So far I had only used clone/push/pull/commit/gc commands, but I’m familiar with tag/branch/checkout commands. The drawback of insufficient documentation (as mentioned above) isn’t really a problem now. I’m not using any GUIs for git (as sometimes I’m working on a remote server via ssh), but of the three locally tried GUIs I liked gitk the most; both git-gui and qgit feel less convenient than gitk, but are approximately equal. I wish I had some SVN/Mercurial/Darcs experience to be able to recommend Git – but I don’t have that
Posted in *nix, Links, Software | No Comments »
25th December 2008
Source: George from vbulletin team.
Two most common reasons (and fixes) for the MySQL server has gone away (error 2006) are:
- Server timed out and closed the connection. How to fix: check that wait_timeout variable in your mysqld’s my.cnf configuration file is large enough. On Debian: sudo nano /etc/mysql/my.cnf, set wait_timeout = 600 seconds (you can tweak/decrease this value when error 2006 is gone), then sudo /etc/init.d/mysql restart. I didn’t check, but the maximal value for wait_timeout might be around 28800 seconds (8 hours).
- Server dropped an incorrect or too large packet. If mysqld gets a packet that is too large or incorrect, it assumes that something has gone wrong with the client and closes the connection. You can increase the maximal packet size limit by increasing the value of max_allowed_packet in my.cnf file. On Debian: sudo nano /etc/mysql/my.cnf, set max_allowed_packet = 64M (you can tweak/decrease this value when error 2006 is gone), then sudo /etc/init.d/mysql restart.
If you get MySQL server has gone away (error 2006) when using MySQL ODBC driver – give this hint a try.
Posted in *nix, how-to, Software | 54 Comments »
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 »
Posted in *nix, how-to, Software | 2 Comments »
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 »
Posted in *nix, Links, Science, Software | 3 Comments »
4th October 2008
I love Debian, too.
Though I prefer ‘testing’ (which is currently codenamed Lenny) over ‘stable’ (aka Etch).
Posted in *nix, Links, Misc | 1 Comment »
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):
- aptitude update, to ensure you’ve got the list of latest packages
- 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)
- aptitude install module-assistant, required for building the kernel module
- module-assistant prepare, to verify that you have everything needed for the module build procedure
- module-assistant update
- module-assistant auto-install fglrx, to build and install the fglrx kernel module
- depmod -a
- modprobe fglrx, to load the fglrx kernel module
- aticonfig ––initial, to configure ATI’s device section in /etc/X11/xorg.conf (for more options, see aticonfig ––help)
- reboot
Read the rest of this entry »
Posted in *nix | 5 Comments »